The GL-BE14000 carries a Motorcomm YT9224 switch. Add the yt921x DSA
driver, its tagging protocol and the Motorcomm PHY patches as the series
was merged upstream, so the driver tracks net-next.
The YT922x support in 967-27 is not upstream yet. It is a rework by
Shi Jiayang of the net-next v1 posting by Kyle Switch,
<20260813104137.55550-1-kyle.switch@motor-comm.com>. The rework adds
the switch setup, the eFuse calibration, the SerDes configuration, the
phylink PCS handling and the CPU port recovery that the GL-BE14000
needs, ports them to Linux 6.18, and keeps separate YT921x and YT922x
tag drivers. Its mtk-usxgmii change moves to the mediatek patch 978,
later in this series. On top of the rework, 967-27 keeps the LAG
offload of the YT9215, and 967-36 releases its package lock on the
error paths of yt8824_config_aneg().
The driver is not specific to MediaTek, so the patches go to the generic
patch set. The upstream patches go to backport-6.18. 967-27 and the
quad 2.5G PHY driver in 967-36 go to pending-6.18.
YT921X and YT922X take tag protocol 32 and 33, because MXL862 already
holds 30 and 31 here. The OOB, RALINK, QCA_ETYPE and RTL_OTTO tag
protocols of the ipq40xx, ramips, qualcommax and realtek targets move
from 32 to 35. The YT92xx tags hold 32 and 33 on all targets, and the
YT922x fixes add 34 for the four-byte tag.
Enable CONFIG_NET_DSA_YT92XX, CONFIG_NET_DSA_TAG_YT921X,
CONFIG_NET_DSA_TAG_YT922X and CONFIG_MOTORCOMM_PHY in the filogic
config. Mark the YT92xx symbols as unset in the generic config, so that
the other targets do not stop at a kconfig prompt.
Signed-off-by: Kyle Switch <kyle.switch@motor-comm.com>
Signed-off-by: Shi Jiayang <shi05275@163.com>
Signed-off-by: Nilanka de Silva <nilankadsilva@gmail.com>
Signed-off-by: John Crispin <john@phrozen.org>
config_generate runs from preinit (82_config_generate), which comes before
kmodloader loads /etc/modules.d from /etc/init.d/boot. On targets without a
board-specific network config, such as malta, 99-default_network only adds a
wan interface if eth1 exists at that point:
[ -d /sys/class/net/eth1 ] && ucidef_set_interface_wan 'eth1'
Since pcnet32 was not loaded yet, eth1 never showed up in time, so malta images
never got a wan interface, even with a second NIC attached. QEMU with two pcnet
NICs, as used by openwrt-tests, shows the problem: ubus call
network.interface.wan status returns "Not found".
Add pcnet32 to modules-boot.d, as is already done for r8169 and e1000e, so the
NICs exist when the board config is generated. Its dependency kmod-mii already
loads at boot.
Link: https://github.com/openwrt/openwrt/pull/26374
Signed-off-by: Paul Spooren <mail@aparcar.org>
Package ax88796b_rust, the Rust reference driver for the Asix PHYs used
by the AX88772 USB Ethernet adapters. It is equivalent to the C driver
of kmod-phy-ax88796b and provides that package, so kmod-usb-net-asix
works with either; the C driver stays the default variant.
Upstream builds only one of the two drivers. A hack patch makes
AX88796B_RUST_PHY a module of its own so that both are built. The Rust
PHY abstractions are part of the kernel's Rust crate in vmlinux and
need a built-in PHY library, so the package enables
RUST_PHYLIB_ABSTRACTIONS and PHYLIB=y. Answer the options these make
visible in the generic configuration.
Signed-off-by: Daniel Golle <daniel@makrotopia.org>
All targets use kernel 6.18, so LINUX_6_18 is always set. Make the
conditional dependencies and autoload entries unconditional and drop
the @LINUX_6_18 requirements.
Also drop snd-hda-codec-realtek and snd-hda-codec-cirrus from the HDA
codec autoload lists; these 6.12 modules were split up and no longer
exist on 6.18.
Signed-off-by: Sander van Deijck <sander@vandeijck.com>
Link: https://github.com/openwrt/openwrt/pull/26052
Signed-off-by: Robert Marko <robimarko@gmail.com>
All targets use kernel 6.18, so drop the version filters from the kmod
definitions: remove items only used before 6.18 and strip the @ge6.18
suffix from the others. Also remove the crypto-md5 octeon/powerpc
variants, which only contained 6.12 modules.
The generated package metadata is unchanged.
Signed-off-by: Sander van Deijck <sander@vandeijck.com>
Link: https://github.com/openwrt/openwrt/pull/26052
Signed-off-by: Robert Marko <robimarko@gmail.com>
The symbol was listed as CONFIG_CONFIG_DWMAC_DWC_QOS_ETH, so the
intended override never took effect. Fix the doubled prefix.
No functional change: kmod-stmmac-core is only available on armsr,
loongarch64 and x86_64, where CONFIG_DWMAC_DWC_QOS_ETH is already
disabled in the generic kernel config.
Fixes: 1816e53062 ("armsr: Move kmod-stmmac-core to common place")
Signed-off-by: Sander van Deijck <sander@vandeijck.com>
Link: https://github.com/openwrt/openwrt/pull/25965
Signed-off-by: Robert Marko <robimarko@gmail.com>
Remove KCONFIG symbols that no longer exist in kernel 6.18 from the kmod
definitions. Some were renamed and the new symbol is already listed in
the same package (e.g. CRYPTO_GF128MUL -> CRYPTO_LIB_GF128MUL,
USB_YEALINK -> INPUT_YEALINK, MEDIA_RC_SUPPORT -> RC_CORE). The others
belong to options and drivers that were removed upstream (e.g. CAN_LEDS,
E1000_NAPI, NF_FLOW_TABLE_HW, the Keyspan firmware options).
The generated package metadata is unchanged apart from the
Kernel-Config field of the affected packages.
Signed-off-by: Sander van Deijck <sander@vandeijck.com>
Link: https://github.com/openwrt/openwrt/pull/25965
Signed-off-by: Robert Marko <robimarko@gmail.com>
kmod-lib-crc32c, kmod-phy-rtl8261n and kmod-echo could only be selected
with kernel 6.12. With all targets on kernel 6.18 they are no longer
available, so remove their definitions.
On kernel 6.18, CRC32C is provided by the built-in CRC library, and the
RTL8261N is supported by the upstream Realtek PHY driver
(kmod-phy-realtek). Remove the out-of-tree RTL8261N driver sources and
the hack patch hooking them into the 6.12 kernel build as well.
Signed-off-by: Sander van Deijck <sander@vandeijck.com>
Link: https://github.com/openwrt/openwrt/pull/25965
Signed-off-by: Robert Marko <robimarko@gmail.com>
All targets have been switched to kernel 6.18, so LINUX_6_12 is never
set any more. Clean up the kmod definitions accordingly:
- '@!LINUX_6_12' conditions are always true: drop them
- '+!LINUX_6_12:kmod-foo' dependencies become '+kmod-foo'
- '+LINUX_6_12:kmod-foo' dependencies are never active: drop them
- AutoLoad entries guarded by LINUX_6_12 are never used: drop them
- 'ifeq ($(KERNEL_PATCHVER),6.12)' blocks are never used: drop them
With kernel 6.18 the resulting package metadata is unchanged apart from
the dropped dependency conditions. The kmods that only exist on kernel
6.12 are removed in a follow-up commit.
Signed-off-by: Sander van Deijck <sander@vandeijck.com>
Link: https://github.com/openwrt/openwrt/pull/25965
Signed-off-by: Robert Marko <robimarko@gmail.com>
The internal PHYs of the QCA8327/8334/8337 switches are handled by the
qca83xx PHY driver. Without it they silently fall back to genphy and
lose the chip-specific setup and fixups. Every device using
kmod-dsa-qca8k already pulls it in manually except the MikroTik
RB960PGS, which was missing it.
Add the dependency, like other DSA packages do with their PHY drivers,
and drop the now-redundant device package entries.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Signed-off-by: Rosen Penev <rosenp@gmail.com>
Link: https://github.com/openwrt/openwrt/pull/25767
Signed-off-by: Robert Marko <robimarko@gmail.com>
Enable MACsec (Media Access Control Security) support in the Mellanox
mlx5 driver by setting CONFIG_MLX5_MACSEC=y.
Enabling this configuration allows users to utilize hardware MACsec
offload capabilities on supported Mellanox ConnectX network adapters.
This provides point-to-point Layer 2 encryption at line rate while
significantly reducing CPU overhead.
The kmod-macsec dependency is intentionally omitted to make this an
opt-in feature. The offload support only builds if kmod-macsec is
also selected, preventing driver bloat for standard users.
Signed-off-by: Til Kaiser <mail@tk154.de>
Link: https://github.com/openwrt/openwrt/pull/25400
Signed-off-by: Robert Marko <robimarko@gmail.com>
Add the two external Aeonsemi AS21xxx PHYs used by the LAN and WAN
10GBASE-T ports of the BPI-R4 Pro 8x. Configure their firmware, reset
timing and LEDs, and connect them to the MxL switch and GMAC1.
Replace the fixed SFP GPIO hog configuration with LAN and WAN overlays
selecting either the copper PHY or the corresponding SFP cage. Build all
four overlays, include them in the device image and select the SFP
overlays by default through U-Boot `bootconf_extra`.
Make the AS21xxx firmware package pull in the PHY driver on Linux 6.18,
instead of making the driver depend on the firmware. Update existing
Airoha device package lists accordingly so they continue to install both
components through the firmware package.
Breaking change for users using the router with SFP hogs from PR #21083.
After flashing the new image, configure `bootconf_extra` to select
between SFP or PHY overlays:
fw_setenv bootconf_extra \
mt7988a-bananapi-bpi-r4-pro-8x-lan-phy#mt7988a-bananapi-bpi-r4-pro-8x-wan-phy
If bootconf_extra had additional overlays (CN13 or CN14) keep them appended
Signed-off-by: Pietro Ameruoso <p.ameruoso@live.it>
Signed-off-by: Frank Wunderlich <frank-w@public-files.de>
Add missing dependent package kmod-of-mdio to fix build error:
Package kmod-switch-rtl8366-smi is missing dependencies for the following libraries:
of_mdio.ko
Signed-off-by: Shiji Yang <yangshiji66@outlook.com>
Link: https://github.com/openwrt/openwrt/pull/24727
Signed-off-by: Robert Marko <robimarko@gmail.com>
Add missing dependent package kmod-of-mdio to fix build error:
Package kmod-mdio-gpio is missing dependencies for the following libraries:
of_mdio.ko
Signed-off-by: Shiji Yang <yangshiji66@outlook.com>
Link: https://github.com/openwrt/openwrt/pull/24710
Signed-off-by: Robert Marko <robimarko@gmail.com>
Add missing dependent package kmod-of-mdio to fix build error:
Package kmod-mdio-devres is missing dependencies for the following libraries:
of_mdio.ko
Signed-off-by: Shiji Yang <yangshiji66@outlook.com>
Link: https://github.com/openwrt/openwrt/pull/24710
Signed-off-by: Robert Marko <robimarko@gmail.com>
Now that the upstream RealTek PHY driver is patched to support also
the new 5G and 10G PHYs we can start to phase-out the messy downstream
driver.
Signed-off-by: Daniel Golle <daniel@makrotopia.org>
This improves on openwrt/openwrt@aeb9028aab by adding support for
other Dell EMC Edge620/640/680 devices and mapping
the interfaces to match the markings on the device.
This modifies the netdevices.mk file to set the boot flag for
ixgbe driver to load it in early stage of the boot process to
allow for proper mapping of the network interface PCI paths
inside the 02_network script. This will also allow other devices
using the ixgbe driver to do proper mapping in 02_network script.
The 02_network script is then modified to support all
dell-emc-620/640/680 devices. It now maps the network
interfaces via PCI paths to match the markings on the device.
The interface marked GE6 is still used for WAN with
interfaces GE1-GE5 used for LAN.
The SFP1 and SFP2 interfaces are left to be assigned by
the user.
Signed-off-by: Raylynn Knight <rayknight@me.com>
Link: https://github.com/openwrt/openwrt/pull/23110
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
Going from 6.12 to 6.18 I see breakage with a missing dependency
that drivers/net/ethernet/amazon/ena/ena_netdev.c has on ptp.ko.
Signed-off-by: Philip Prindeville <philipp@redfish-solutions.com>
Link: https://github.com/openwrt/openwrt/pull/23098
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
This is required to build the motorcomm dwmac driver which is widely
used on loongson platforms.
Signed-off-by: Tianling Shen <cnsztl@immortalwrt.org>
Link: https://github.com/openwrt/openwrt/pull/22923
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
Motorcomm YT6801 is a PCIe ethernet controller based on DWMAC4 IP. It
integrates an GbE phy, supporting WOL, VLAN tagging and various types
of offloading. It ships an on-chip eFuse for storing various vendor
configuration, including MAC address.
The PM and plat_data functions were slightly modified to build with
current kernel.
Signed-off-by: Tianling Shen <cnsztl@immortalwrt.org>
Link: https://github.com/openwrt/openwrt/pull/22923
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
Replace conditional "LINUX_6_12:mod" / "!LINUX_6_12:mod" AUTOLOAD entries
with version-filtered module names using @lt6.18 / @ge6.18. This makes
version_filter emit plain module names into /etc/modules.d(e.g. "crc32c_generic"),
allowing kmodloader to find and load the correct module for the running kernel.
Fixes crc32c (and related crypto modules) not being autoloaded on 6.12 kernels.
Signed-off-by: Mieczyslaw Nalewaj <namiltd@yahoo.com>
Link: https://github.com/openwrt/openwrt/pull/22798
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
Add missing dependency kmod-ptp to fix the build error. We also
add symbol CONFIG_PTP_1588_CLOCK_OPTIONAL explicitly for kmod-ptp
because it is selected by CONFIG_PTP_1588_CLOCK. Fix:
Package kmod-iavf is missing dependencies for the following libraries:
ptp.ko
Signed-off-by: Shiji Yang <yangshiji66@outlook.com>
Link: https://github.com/openwrt/openwrt/pull/22730
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
Backport upstream driver and apply pending downstream patches to
support using the MaxLinear MxL86252 and MxL86282 switches.
The driver supports a native proprietary 8-byte DSA special tag format
(mxl862xx) as well as using an 802.1Q-based DSA tag (mxl862xx-8021q).
All basic bridge, VLAN and LAG operations are supported. A single port
can be used as mirror port. Hardware counters are made available as
ethtool stats or directly serve as interface counters (bytes,
packets).
The switch runs a complex ZephyrOS-based firmware on an integrated
ARC microcontroller, the driver uses the firmware management API over
MDIO to interact with the switch hardware.
Note that the firmware needs to be rather recent (WSP 1.0.78 or later)
to work well with this driver. It can be updated at runtime using devlink.
Signed-off-by: Daniel Golle <daniel@makrotopia.org>
This adds kernel packages for the Microchip KSZ9477 switch family.
The core package has a target specific dependency as the ksz9477
driver enables DCB which grows the kernel size and can negatively
impact other targets.
Signed-off-by: Tim Harvey <tharvey@gateworks.com>
Link: https://github.com/openwrt/openwrt/pull/22257
Signed-off-by: Robert Marko <robimarko@gmail.com>
This reverts commit c053b22573.
KSZ DSA driver is the only thing in the kernel selecting DCB support
instead of depending on it if required.
So, it will enable DCB support without asking and we do not want the
kernel size increase, as well as current Layerscape ARMv8 build failure.
So, revert this until its fixed upstream or worked around.
Signed-off-by: Robert Marko <robimarko@gmail.com>
This adds kernel packages for the Microchip KSZ9477 switch family.
Signed-off-by: Tim Harvey <tharvey@gateworks.com>
Link: https://github.com/openwrt/openwrt/pull/22120
Signed-off-by: Robert Marko <robimarko@gmail.com>
Switchdev driver used by microchipsw supports DCB and has not storage
constraints, so enable kernel and driver DCB support by default.
Signed-off-by: Robert Marko <robert.marko@sartura.hr>
The Motorcomm YT8821 2.5G PHY is being used in some devices as an
alternative to devices like the RTL8221B. Package it as a kmod
so it can be used as a device package rather than requiring changes
to the target kernel config.
Signed-off-by: Andrew MacIntyre <andymac@pcug.org.au>
Link: https://github.com/openwrt/openwrt/pull/21399
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
Switch r8169 and related kmods to use the new virtual kmod provides
semantic and mark r8169 as the default variant.
Signed-off-by: George Sapkin <george@sapk.in>
Link: https://github.com/openwrt/openwrt/pull/21288
Signed-off-by: Robert Marko <robimarko@gmail.com>
Once kernel 6.6 support ends, its dependencies will become redundant.
Remove them and keep only those for kernel 6.12.
Signed-off-by: Mieczyslaw Nalewaj <namiltd@yahoo.com>
Link: https://github.com/openwrt/openwrt/pull/20943
Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
Previously, devices would have to select `CONFIG_RTL8261N_PHY=Y` in the
whole target's kernel config. Now that this driver is becoming usable
for devices other than Realtek switches, allow packaging this driver
separately.
Signed-off-by: Kenneth Kasilag <kenneth@kasilag.me>
Link: https://github.com/openwrt/openwrt/pull/20429
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
Currently, the interfaces of the Mellanox Spectrum Switch QSFP ports
are all labeled eth*. Their order doesn't match the faceplate and is
different for each model.
They could be named during boot, but this isn't sufficient because they
support port splitting. After such ports are split, their port naming
begins again with eth*, and the same is true after they are unsplit again.
A hotplug script is used here that reads from the sysfs file
phys_port_name, which contains p1, p2, p3, ... for unsplit ports
and p1s0, p1s1, p1s2 for split ports.
Signed-off-by: Til Kaiser <mail@tk154.de>
Link: https://github.com/openwrt/openwrt/pull/17251
Signed-off-by: Robert Marko <robimarko@gmail.com>
Set the pre-init boot flag for the e1000e network device
driver so that it is loaded during the early pre-init
stage of the boot process instead of later.
Then, it is possible to rename its network ports via the
ucidef_set_network_device_path function from the
02_network script while booting.
Signed-off-by: Til Kaiser <mail@tk154.de>
Link: https://github.com/openwrt/openwrt/pull/17251
Signed-off-by: Robert Marko <robimarko@gmail.com>
Fix a typo on defining the PHY package kmod description that reference
phy-aeonsemi-as21x1x package instead of phy-aeonsemi-as21xxx.
Fixes: 08a616b216 ("generic: backport support for Aeonsemi AS21xxx PHY")
Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
This adds kernel packages for the Vitesse VSC73XX switches.
I have split the switch into explicit SPI and platform integrated
variants as it's quite a bit of code.
Link: https://github.com/openwrt/openwrt/pull/20057
Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
Converts the KS8995 "phy" driver to a proper DSA switch.
Currently the upstream only supports the "none" tag
but this is a good improvement already.
Make the old module depend on kernel 6.6 and the new
one depend on !6.6.
The Realtek RTL8261n patch needs to be refreshed
because of textual dependencies.
Realtek RTL838x DSA and phy patches also have textual
dependencies and need to be refreshed.
The Mediatek in-flight DSA patch and related patches
also need to be rebased and refreshed.
Link: https://github.com/openwrt/openwrt/pull/19970
Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
Backport support for Aeonsemi AS121xxx PHY. The PHY require dedicated
firmware to be loaded to correctly work and support a big family of
Aeonsemi PHY that provide from 1G to 10G speed.
Automatically refresh all affected patch and file (rtl PHY).
Link: https://github.com/openwrt/openwrt/pull/19816
Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
kmod-sfc should add support for Solarflare SFC9000 series based cards.
However after kernel 5.19, support for the 'Siena' subclass of
SFN5000/6000 devices has been separated out since they went EOL as they
are no longer being actively developed. As kmod-sfc no longer provides
driver support for these cards and hasn't since kernel 5.2, a new kernel
module is needed to support these 10Gb Ethernet cards. More info here:
https://cateee.net/lkddb/web-lkddb/SFC_SIENA.html and here:
https://www.phoronix.com/news/Solarflare-SFC-Siena-Linux-5.19
The module can be compiled in separately and works if kernel is custom
compiled;
OpenWRT has made these changes already with the SFC 'falcon' subclass of
drivers already. See 3c5d70a and e5ba6e9
This is building on excellent work by @ynezz and @nasbdh9
Signed-off-by: Steve Wavler <trenchcoatjedi@gmail.com>
Link: https://github.com/openwrt/openwrt/pull/19647
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
The CONFIG_B53 kernel config option will select this driver. Add
the driver to the kernel config menu and make kmod-dsa-b53 depend on
it.
Link: https://github.com/openwrt/openwrt/pull/19480
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
The CONFIG_BCMGENET kernel config option will select this driver. Add
the driver to the kernel config menu and make kmod-bcmgenet depend on
it.
Link: https://github.com/openwrt/openwrt/pull/19480
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
The kernel driver configuration depends on ath79 or compile test and not
on PCI. Allow this package in OpenWrt only for the ath79 target.
Link: https://github.com/openwrt/openwrt/pull/19480
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
This will allow more flexibility in using PHY drivers as kmods.
Signed-off-by: Mantas Pucka <mantas@8devices.com>
Link: https://github.com/openwrt/openwrt/pull/18435
Signed-off-by: Robert Marko <robimarko@gmail.com>
Add support for Maxlinear GPHY module. Also add support for
kmod-polynomial, which is a dependency for this module.
Signed-off-by: Alexandru Gagniuc <mr.nuke.me@gmail.com>
Link: https://github.com/openwrt/openwrt/pull/18435
Signed-off-by: Robert Marko <robimarko@gmail.com>