[openwrt/openwrt] lantiq: xrx200: convert switch driver to package

LEDE Commits lede-commits at lists.infradead.org
Sat Mar 15 05:53:46 PDT 2025


hauke pushed a commit to openwrt/openwrt.git, branch main:
https://git.openwrt.org/62bf0287326dcfab4596d5f4cad77cd9e7f8f03b

commit 62bf0287326dcfab4596d5f4cad77cd9e7f8f03b
Author: Aleksander Jan Bajkowski <olek2 at wp.pl>
AuthorDate: Fri Jul 10 23:18:45 2020 +0200

    lantiq: xrx200: convert switch driver to package
    
    The next commit converts the firmware used by this driver
    to a package. Due to the fact that the driver is shipped
    as a package the firmware is already available.
    
    Signed-off-by: Aleksander Jan Bajkowski <olek2 at wp.pl>
    Link: https://github.com/openwrt/openwrt/pull/17669
    Signed-off-by: Hauke Mehrtens <hauke at hauke-m.de>
---
 target/linux/lantiq/modules.mk               | 18 ++++++++++++++++++
 target/linux/lantiq/xrx200/config-6.6        |  3 +--
 target/linux/lantiq/xrx200/target.mk         |  1 +
 target/linux/lantiq/xrx200_legacy/config-6.6 |  2 --
 target/linux/lantiq/xrx200_legacy/target.mk  |  1 +
 5 files changed, 21 insertions(+), 4 deletions(-)

diff --git a/target/linux/lantiq/modules.mk b/target/linux/lantiq/modules.mk
index 14140b1095..e1aea4b039 100644
--- a/target/linux/lantiq/modules.mk
+++ b/target/linux/lantiq/modules.mk
@@ -17,3 +17,21 @@ endef
 
 $(eval $(call KernelPackage,i2c-lantiq))
 
+define KernelPackage/dsa-gswip
+  SUBMENU:=$(NETWORK_DEVICES_MENU)
+  TITLE:=Lantiq xRx200/xRx300/xRx330 switch support
+  DEPENDS:=@TARGET_lantiq_xrx200||TARGET_lantiq_xrx200_legacy
+  KCONFIG:= \
+  	CONFIG_NET_DSA_LANTIQ_GSWIP \
+  	CONFIG_NET_DSA_TAG_GSWIP
+  FILES:= \
+	$(LINUX_DIR)/drivers/net/dsa/lantiq_gswip.ko \
+  	$(LINUX_DIR)/net/dsa/tag_gswip.ko
+  AUTOLOAD:=$(call AutoLoad,41,lantiq_gswip)
+endef
+
+define KernelPackage/dsa-gswip/description
+ Lantiq xRx200/xRx300/xRx330 switch support
+endef
+
+$(eval $(call KernelPackage,dsa-gswip))
diff --git a/target/linux/lantiq/xrx200/config-6.6 b/target/linux/lantiq/xrx200/config-6.6
index 4819c962c8..a3829135b9 100644
--- a/target/linux/lantiq/xrx200/config-6.6
+++ b/target/linux/lantiq/xrx200/config-6.6
@@ -50,13 +50,12 @@ CONFIG_MTD_UBI_WL_THRESHOLD=4096
 CONFIG_NEED_SRCU_NMI_SAFE=y
 CONFIG_NET_DEVLINK=y
 CONFIG_NET_DSA=y
-CONFIG_NET_DSA_LANTIQ_GSWIP=y
-CONFIG_NET_DSA_TAG_GSWIP=y
 CONFIG_NET_FLOW_LIMIT=y
 CONFIG_NET_SWITCHDEV=y
 CONFIG_NLS=y
 CONFIG_NR_CPUS=2
 CONFIG_PADATA=y
+CONFIG_PAHOLE_HAS_LANG_EXCLUDE=y
 CONFIG_PCI=y
 CONFIG_PCIEPORTBUS=y
 CONFIG_PCIE_LANTIQ=y
diff --git a/target/linux/lantiq/xrx200/target.mk b/target/linux/lantiq/xrx200/target.mk
index 0f119edd6f..01ac3d7fd6 100644
--- a/target/linux/lantiq/xrx200/target.mk
+++ b/target/linux/lantiq/xrx200/target.mk
@@ -12,6 +12,7 @@ DEFAULT_PACKAGES+=kmod-leds-gpio \
 	kmod-ltq-atm-vr9 \
 	kmod-ltq-deu-vr9 \
 	kmod-ltq-ptm-vr9 \
+	kmod-dsa-gswip \
 	ltq-vdsl-vr9-app \
 	dsl-vrx200-firmware-xdsl-a \
 	dsl-vrx200-firmware-xdsl-b-patch \
diff --git a/target/linux/lantiq/xrx200_legacy/config-6.6 b/target/linux/lantiq/xrx200_legacy/config-6.6
index 9bb65cff07..1bf5f70ff3 100644
--- a/target/linux/lantiq/xrx200_legacy/config-6.6
+++ b/target/linux/lantiq/xrx200_legacy/config-6.6
@@ -37,8 +37,6 @@ CONFIG_MIPS_VPE_LOADER_TOM=y
 CONFIG_NEED_SRCU_NMI_SAFE=y
 CONFIG_NET_DEVLINK=y
 CONFIG_NET_DSA=y
-CONFIG_NET_DSA_LANTIQ_GSWIP=y
-CONFIG_NET_DSA_TAG_GSWIP=y
 CONFIG_NET_FLOW_LIMIT=y
 CONFIG_NET_SWITCHDEV=y
 CONFIG_NLS=y
diff --git a/target/linux/lantiq/xrx200_legacy/target.mk b/target/linux/lantiq/xrx200_legacy/target.mk
index d9a6fff651..6ca039e0ec 100644
--- a/target/linux/lantiq/xrx200_legacy/target.mk
+++ b/target/linux/lantiq/xrx200_legacy/target.mk
@@ -13,6 +13,7 @@ DEFAULT_PACKAGES+=kmod-leds-gpio \
 	kmod-ltq-deu-vr9 \
 	kmod-ltq-ptm-vr9 \
 	ltq-vdsl-vr9-app \
+	kmod-dsa-gswip \
 	dsl-vrx200-firmware-xdsl-a \
 	dsl-vrx200-firmware-xdsl-b-patch \
 	ppp-mod-pppoa




More information about the lede-commits mailing list