package: qca-nss: Added support for qca-nss-drv-l2tpv2

This commit is contained in:
Lucas Asvio
2025-03-19 08:00:58 +01:00
parent 47d9212ec5
commit 6222161586
3 changed files with 40 additions and 24 deletions

View File

@@ -38,21 +38,21 @@ define KernelPackage/qca-nss-drv-tun6rd/description
Kernel modules for NSS connection manager - Support for 6rd tunnel
endef
#define KernelPackage/qca-nss-drv-l2tpv2
# SECTION:=kernel
# CATEGORY:=Kernel modules
# SUBMENU:=Network Devices
# TITLE:=Kernel driver for NSS (connection manager) - l2tp
# DEPENDS:=+@NSS_DRV_L2TP_ENABLE +kmod-ppp +kmod-l2tp \
# +PACKAGE_kmod-qca-nss-drv:kmod-qca-nss-drv
# FILES:=$(PKG_BUILD_DIR)/l2tp/l2tpv2/qca-nss-l2tpv2.ko
# KCONFIG:=CONFIG_L2TP=y
# AUTOLOAD:=$(call AutoLoad,51,qca-nss-l2tpv2)
#endef
define KernelPackage/qca-nss-drv-l2tpv2
SECTION:=kernel
CATEGORY:=Kernel modules
SUBMENU:=Network Devices
TITLE:=Kernel driver for NSS (connection manager) - l2tp
DEPENDS:=+@NSS_DRV_L2TP_ENABLE +kmod-ppp +kmod-l2tp \
+PACKAGE_kmod-qca-nss-drv:kmod-qca-nss-drv
FILES:=$(PKG_BUILD_DIR)/l2tp/l2tpv2/qca-nss-l2tpv2.ko
KCONFIG:=CONFIG_L2TP=y
AUTOLOAD:=$(call AutoLoad,51,qca-nss-l2tpv2)
endef
#define KernelPackage/qca-nss-drv-l2tp/description
#Kernel modules for NSS connection manager - Support for l2tp tunnel
#endef
define KernelPackage/qca-nss-drv-l2tp/description
Kernel modules for NSS connection manager - Support for l2tp tunnel
endef
define KernelPackage/qca-nss-drv-pptp
SECTION:=kernel
@@ -387,10 +387,10 @@ ifneq ($(CONFIG_PACKAGE_kmod-qca-nss-drv-tun6rd),)
MAKE_OPTS+=tun6rd=m
endif
#ifneq ($(CONFIG_PACKAGE_kmod-qca-nss-drv-l2tpv2),)
#MAKE_OPTS+=l2tpv2=y
#EXTRA_CFLAGS += -DNSS_L2TPV2_ENABLED
#endif
ifneq ($(CONFIG_PACKAGE_kmod-qca-nss-drv-l2tpv2),)
MAKE_OPTS+=l2tpv2=y
EXTRA_CFLAGS += -DNSS_L2TPV2_ENABLED
endif
ifneq ($(CONFIG_PACKAGE_kmod-qca-nss-drv-pptp),)
MAKE_OPTS+=pptp=y
@@ -476,7 +476,7 @@ endef
$(eval $(call KernelPackage,qca-nss-drv-profile))
$(eval $(call KernelPackage,qca-nss-drv-tun6rd))
#$(eval $(call KernelPackage,qca-nss-drv-l2tpv2))
$(eval $(call KernelPackage,qca-nss-drv-l2tpv2))
$(eval $(call KernelPackage,qca-nss-drv-pptp))
$(eval $(call KernelPackage,qca-nss-drv-pppoe))
$(eval $(call KernelPackage,qca-nss-drv-tunipip6))

View File

@@ -20,7 +20,23 @@
#endif
--- a/l2tp/l2tpv2/nss_connmgr_l2tpv2.c
+++ b/l2tp/l2tpv2/nss_connmgr_l2tpv2.c
@@ -954,7 +954,11 @@ int __init nss_connmgr_l2tpv2_init_modul
@@ -912,6 +912,7 @@ static struct ctl_table nss_connmgr_l2tp
/*
* nss_connmgr_l2tpv2_dir
*/
+#if (LINUX_VERSION_CODE < KERNEL_VERSION(6, 6, 0))
static struct ctl_table nss_connmgr_l2tpv2_dir[] = {
{
.procname = "l2tpv2",
@@ -933,6 +934,7 @@ static struct ctl_table nss_connmgr_l2tp
{ }
};
+#endif
/*
* Linux Net device Notifier
*/
@@ -954,7 +956,11 @@ int __init nss_connmgr_l2tpv2_init_modul
return 0;
}
#endif

View File

@@ -65,10 +65,10 @@ config NSS_DRV_IPV6_REASM_ENABLE
bool
default n
prompt "Enable IPV6_REASM"
#config NSS_DRV_L2TP_ENABLE
# bool
# default n
# prompt "Enable L2TP"
config NSS_DRV_L2TP_ENABLE
bool
default n
prompt "Enable L2TP"
#config NSS_DRV_LAG_ENABLE
# bool
# default n