From b8ca72b4109bbf7108d76d886a53ef7ed0b94ea3 Mon Sep 17 00:00:00 2001 From: "Ycarus (Yannick Chabanois)" Date: Thu, 19 Oct 2023 12:05:34 +0200 Subject: [PATCH 1/2] Changes needed for kernel 6.6 support --- ndpi-netfilter2/Makefile | 3 ++- openmptcprouter/files/etc/uci-defaults/1980-omr-firewall | 3 +++ r8152/Makefile | 2 +- 3 files changed, 6 insertions(+), 2 deletions(-) diff --git a/ndpi-netfilter2/Makefile b/ndpi-netfilter2/Makefile index 81a815641..406f647ac 100644 --- a/ndpi-netfilter2/Makefile +++ b/ndpi-netfilter2/Makefile @@ -77,7 +77,8 @@ define KernelPackage/ipt-ndpi TITLE:= nDPI net netfilter module # DEPENDS:=+kmod-nf-conntrack +kmod-nf-conntrack-netlink +kmod-ipt-compat-xtables +libpcap @(LINUX_5_4||LINUX_5_15||TARGET_x86_64) # DEPENDS:=+kmod-nf-conntrack +kmod-nf-conntrack-netlink +kmod-ipt-compat-xtables +libpcap @(LINUX_5_4||LINUX_5_15) @!TARGET_ramips - DEPENDS:=+kmod-nf-conntrack +kmod-nf-conntrack-netlink +kmod-ipt-compat-xtables +libpcap @!TARGET_ramips + DEPENDS:=+kmod-nf-conntrack +kmod-nf-conntrack-netlink +(LINUX_5_4||LINUX_6_1):kmod-ipt-compat-xtables +libpcap @!TARGET_ramips +# DEPENDS:=+kmod-nf-conntrack +kmod-nf-conntrack-netlink +kmod-ipt-compat-xtables +libpcap KCONFIG:=CONFIG_NF_CONNTRACK_LABELS=y \ CONFIG_NETFILTER_XT_MATCH_CONNLABEL=y FILES:= $(PKG_BUILD_DIR)/ndpi-netfilter/src/xt_ndpi.ko diff --git a/openmptcprouter/files/etc/uci-defaults/1980-omr-firewall b/openmptcprouter/files/etc/uci-defaults/1980-omr-firewall index 0dd4b0a57..486951646 100755 --- a/openmptcprouter/files/etc/uci-defaults/1980-omr-firewall +++ b/openmptcprouter/files/etc/uci-defaults/1980-omr-firewall @@ -262,6 +262,9 @@ if [ "$(uci -q get openmptcprouter.settings.sipalg)" = "0" ]; then [ -n "$(lsmod | grep nf_conntrack_sip)" ] && rmmod nf_conntrack_sip 2>&1 >/dev/null fi +# Remove mtu_fix check, doesn't work on kernel 6.6 +sed -i 's/if (zone\.mtu_fix && this\.kernel < 0x040a0000) {/if (zone.mtu_fix \&\& this.kernel < 0x040a0000 \&\& false) {/' /usr/share/ucode/fw4.uc + rm -f /tmp/luci-indexcache exit 0 diff --git a/r8152/Makefile b/r8152/Makefile index 5921bdcc7..f07c14969 100644 --- a/r8152/Makefile +++ b/r8152/Makefile @@ -26,7 +26,7 @@ define KernelPackage/usb-net-rtl8152-vendor VERSION:=$(LINUX_VERSION)+$(PKG_VERSION)-$(BOARD)-$(PKG_RELEASE) TITLE:=Kernel module for USB-to-Ethernet Realtek convertors SUBMENU:=USB Support - DEPENDS:=+kmod-usb-net + DEPENDS:=+kmod-usb-net @(LINUX_5_4||LINUX_6_1) FILES:=$(PKG_BUILD_DIR)/r8152.ko AUTOLOAD:=$(call AutoProbe,r8152) CONFLICTS:=kmod-usb-net-rtl8152 From 666b8fbbdddd278ddb5732227c81ee0468936f27 Mon Sep 17 00:00:00 2001 From: "Ycarus (Yannick Chabanois)" Date: Sat, 21 Oct 2023 07:27:46 +0200 Subject: [PATCH 2/2] Fix https://github.com/Ysurac/openmptcprouter/issues/3005 --- openmptcprouter/files/etc/hotplug.d/iface/00-nego | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/openmptcprouter/files/etc/hotplug.d/iface/00-nego b/openmptcprouter/files/etc/hotplug.d/iface/00-nego index 9ad0cb927..24ef81106 100644 --- a/openmptcprouter/files/etc/hotplug.d/iface/00-nego +++ b/openmptcprouter/files/etc/hotplug.d/iface/00-nego @@ -1,3 +1,3 @@ #!/bin/sh # Needed for some device, like rtl8156 2.5G USB adapter -[ "$ACTION" = "ifup" ] && [ -n "$DEVICE" ] && ([ -n "$(lsusb | grep 8156)" ] || [ -n "$(ethtool $DEVICE | grep 2500)" ]) && ethtool -s $DEVICE autoneg on \ No newline at end of file +[ "$ACTION" = "ifup" ] && [ -n "$DEVICE" ] && [ -n "$(lsusb | grep 8156)" ] && [ -n "$(ethtool $DEVICE | grep 2500)" ] && ethtool -s $DEVICE autoneg on \ No newline at end of file