summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorLinus Walleij <linus.walleij@linaro.org>2023-07-01 16:00:50 +0200
committerLinus Walleij <linus.walleij@linaro.org>2024-04-24 23:15:58 +0200
commit9c8f2d7c2daef6f20fcb6217d7f35a1649ac5fda (patch)
tree2df88bedf25d159973319c7a8c2d459c2afdaa7b
parentf475a44c03a303851959930030ab9e6acebb81a7 (diff)
downloadopenwrt-9c8f2d7c2daef6f20fcb6217d7f35a1649ac5fda.tar.gz
openwrt-9c8f2d7c2daef6f20fcb6217d7f35a1649ac5fda.tar.bz2
openwrt-9c8f2d7c2daef6f20fcb6217d7f35a1649ac5fda.zip
modules: Add kernel module for MV88E6xxx DSA switch
This adds a kernel module package for the Marvell MV88E6XXX DSA switch and a separate module package for the DSA tagger since it can in theory be used by multiple DSA switches. Enable both DSA and EDSA tags in the tagger. We can't just compile this in because just a few devices has this DSA, and it depends on e.g. the I2C and SFP to be loaded as modules first. We have no examples of DSA switches being packaged as modules before, all seem to be compiled in, but it actually works just fine to do this. Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
-rw-r--r--package/kernel/linux/modules/netdevices.mk34
1 files changed, 34 insertions, 0 deletions
diff --git a/package/kernel/linux/modules/netdevices.mk b/package/kernel/linux/modules/netdevices.mk
index 906f866a6b..e0110764c2 100644
--- a/package/kernel/linux/modules/netdevices.mk
+++ b/package/kernel/linux/modules/netdevices.mk
@@ -407,6 +407,40 @@ endef
$(eval $(call KernelPackage,phy-aquantia))
+define KernelPackage/dsa-tag-dsa
+ SUBMENU:=$(NETWORK_DEVICES_MENU)
+ TITLE:=Marvell DSA type DSA and EDSA taggers
+ KCONFIG:= CONFIG_NET_DSA_TAG_DSA_COMMON \
+ CONFIG_NET_DSA_TAG_DSA \
+ CONFIG_NET_DSA_TAG_EDSA \
+ CONFIG_NET_DSA=y
+ FILES:=$(LINUX_DIR)/net/dsa/tag_dsa.ko
+ AUTOLOAD:=$(call AutoLoad,40,tag_dsa,1)
+endef
+
+define KernelPackage/dsa-tag-dsa/description
+ Kernel modules for Marvell DSA and EDSA tagging
+endef
+
+$(eval $(call KernelPackage,dsa-tag-dsa))
+
+define KernelPackage/dsa-mv88e6xxx
+ SUBMENU:=$(NETWORK_DEVICES_MENU)
+ TITLE:=Marvell MV88E6XXX DSA Switch
+ DEPENDS:=+kmod-ptp +kmod-phy-marvell +kmod-dsa-tag-dsa
+ KCONFIG:=CONFIG_NET_DSA_MV88E6XXX \
+ CONFIG_NET_DSA_MV88E6XXX_PTP=y \
+ CONFIG_NET_DSA=y
+ FILES:=$(LINUX_DIR)/drivers/net/dsa/mv88e6xxx/mv88e6xxx.ko
+ AUTOLOAD:=$(call AutoLoad,41,mv88e6xxx,1)
+endef
+
+define KernelPackage/dsa-mv88e6xxx/description
+ Kernel modules for MV88E6XXX DSA switches
+endef
+
+$(eval $(call KernelPackage,dsa-mv88e6xxx))
+
define KernelPackage/swconfig
SUBMENU:=$(NETWORK_DEVICES_MENU)