34994 Commits

Author SHA1 Message Date
Markus Stockhausen
a0c7d5ecff realtek: mdio: rename read/write functions
Harmonize the read/write functions for better readability. This
aligns with the naming convention of the upstream rtl9300 mdio
driver.

read_phy	-> read_c22
read_phy_mmd	-> read_c45
write_phy	-> write_c22
write_phy_mmd	-> write_c45

Swap order of c22/c45 functions to keep structures sorted
alphabetically.

Signed-off-by: Markus Stockhausen <markus.stockhausen@gmx.de>
Link: https://github.com/openwrt/openwrt/pull/23197
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
2026-05-03 01:43:48 +02:00
Manuel Stocker
79a6d2aab2 realtek: support configurable LED interface mode on RTL930x
Add support for changing the LED mode via the device tree.
Currently it always defaults to SERIAL mode. With this change,
one can also use the SINGLE_COLOR_SCAN and BI_COLOR_SCAN modes.

Signed-off-by: Manuel Stocker <mensi@mensi.ch>
Link: https://github.com/openwrt/openwrt/pull/23160
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
2026-05-03 01:32:52 +02:00
INAGAKI Hiroshi
a40a1e5d02 mediatek: add support for ELECOM WRC-X6000GSD
ELECOM WRC-X6000GSD is a 4804Mbps 4xMIMO 2.4/5 GHz 11ax (Wi-Fi 6) router
with 2.5Gbps WAN (stock: 1Gbps max.), based on MT7986B

Specification:

- SoC             : MediaTek MT7986BLA
- RAM             : DDR3 512 MiB (SoC)
- Flash           : Winbond 128MiB SPI NAND (W25N01GVZEIG)
- WLAN            : 2.4/5 GHz 4T4R (MediaTek MT7986)
- Ethernet        : 5x 10/100/1000(/2500) Mbps
  - wan           : Maxlinear Ethernet GPY211C (max. 2500M)
  - lan           : MediaTek MT7531 (max. 1000M)
- LEDs/Keys (GPIO): 11x/4x
- UART            : through-hole on PCB (J1)
  - assignment    : 3.3V, TX, RX, NC, GND from tri-angle marking
  - settings      : 115200n8
- Power           : 12 VDC, 2 A

Flash layout:
dev:  offset     size        name
mtd0: 0x00000000 0x00100000 "BL2"
mtd1: 0x00100000 0x00080000 "Ubootenv"
mtd2: 0x00180000 0x00200000 "Factory"
mtd3: 0x00380000 0x00200000 "FIP"
mtd4: 0x00580000 0x00020000 "Fwheader"
mtd5: 0x005a0000 0x03200000 "ubi"
mtd6: 0x037a0000 0x00380000 "Config"
mtd7: 0x03b20000 0x00020000 "Fwheader_2"
mtd8: 0x03b40000 0x03200000 "ubi_2"
mtd9: 0x06d40000 0x00380000 "Config_2"
mtd10: 0x070c0000 0x00100000 "persist"
mtd11: 0x071c0000 0x00040000 "Mrd"
mtd12: 0x07200000 0x00380000 "Backup"

Flash instruction using factory.bin image:

1. Boot WRC-X6000GSD in router mode normally
2. Access to the WebUI ("http://192.168.2.1/") on the device
   -> その他設定 (Other settings)
   -> フォームウェア更新 (Update firmware)
   -> ローカルファイル指定 (Specify local file)
3. Select the OpenWrt factory.bin image and click apply ("適用") button
4. Wait ~120 seconds to complete flashing

Switching to the stock firmware:

1. Load the elecom.sh script
   . /lib/upgrade/elecom.sh

2. Check the current index of firmware partition
   mstc_rw_bootnum

3. Set the bootnum to opposite value between 1 and 2
   mstc_rw_bootnum value

   example:
   - step2 returned "1": mstc_rw_bootnum 2
   - step2 returned "2": mstc_rw_bootnum 1

4. Reboot, to stock FW

5. Flash the stock FW to fuly revert back to original.

Notes:

- With the stock firmware, it will flash to another partition and
  toggle boot to that partition when any firmware is flashed.
  For example when booting on ubi, the new firmware will be flashed
  to ubi_2 and the router will boot from ubi_2 afterwards.
  The 5th byte of the Persist partition is the boot value (0x01 or 0x02).

- bootmenu_delay=0 is set from factory so uboot menu is hidden by
  default.

- The hardware of WRC-X6000GSD is almost identical to WRC-X6000QS, but
  WAN (labeled as "INTERNET") port is limited to 1000 Mbps on stock FW.
  On OpenWrt FW, 2500 Mbps connection is available on that port.

MAC Addresses:

LAN   : 38:97:A4:xx:xx:58 (Factory, 0x2A(hex)/Ubootenv, "ethaddr"(text))
WAN   : 38:97:A4:xx:xx:5B (Factory, 0x24(hex))
2.4GHz: 38:97:A4:xx:xx:59 (Factory, 0x4(hex))
5GHz  : 38:97:A4:xx:xx:5A (Factory, 0xA(hex)

Signed-off-by: INAGAKI Hiroshi <musashino.open@gmail.com>
Link: https://github.com/openwrt/openwrt/pull/22926
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
2026-05-03 01:14:11 +02:00
INAGAKI Hiroshi
16d159c778 mediatek: add support for ELECOM WRC-X6000QS
ELECOM WRC-X6000QS is a 4804Mbps 4xMIMO 2.4/5 GHz 11ax (Wi-Fi 6) router
with 2.5Gbps WAN, based on MT7986b

Specification:

- SoC             : MediaTek MT7986B
- RAM             : DDR3 512 MiB
- Flash           : Winbond 128MiB SPI NAND
- WLAN            : 2.4/5 GHz 4T4R (MediaTek MT7986)
- Ethernet        : 5x 10/100/1000 Mbps
  - wan           : Maxlinear Ethernet GPY211C
  - lan           : MediaTek MT7531
- LEDs/Keys (GPIO): 11x/4x
- UART            : through-hole on PCB (J1)
  - assignment    : 3.3V, TX, RX, NC, GND from tri-angle marking
  - settings      : 115200n8
- Power           : 12 VDC, 2 A

Flash layout:
dev:  offset     size        name
mtd0: 0x00000000 0x00100000 "BL2"
mtd1: 0x00100000 0x00080000 "Ubootenv"
mtd2: 0x00180000 0x00200000 "Factory"
mtd3: 0x00380000 0x00200000 "FIP"
mtd4: 0x00580000 0x00020000 "Fwheader"
mtd5: 0x005a0000 0x03200000 "ubi"
mtd6: 0x037a0000 0x00380000 "Config"
mtd7: 0x03b20000 0x00020000 "Fwheader_2"
mtd8: 0x03b40000 0x03200000 "ubi_2"
mtd9: 0x06d40000 0x00380000 "Config_2"
mtd10: 0x070c0000 0x00100000 "persist"
mtd11: 0x071c0000 0x00040000 "Mrd"
mtd12: 0x07200000 0x00380000 "Backup"

UBI layout:
name:       size:
kernel      0x00364000  dynamic
rootfs      0x00FFC000  dynamic
rootfs_data 0x01A47000  dynamic

Flash instruction using factory.bin image:

1. Boot WRC-X6000QS in router mode normally
2. Access to the WebUI ("http://192.168.2.1/") on the device
   -> その他設定 (Other settings)
   -> フォームウェア更新 (Update firmware)
   -> ローカルファイル指定 (Specify local file)
3. Select the OpenWrt factory.bin image and click apply ("適用") button
4. Wait ~120 seconds to complete flashing

Switching to the stock firmware:

1. Load the elecom.sh script
   . /lib/upgrade/elecom.sh

2. Check the current index of firmware partition
   mstc_rw_bootnum

3. Set the bootnum to opposite value between 1 and 2
   mstc_rw_bootnum value

   example:
   - step2 returned "1": mstc_rw_bootnum 2
   - step2 returned "2": mstc_rw_bootnum 1

4. Reboot, to stock FW

5. Flash the stock FW to fuly revert back to original.

Note 1: With the stock firmware, it will flash to another partition and
  toggle boot to that partition when any firmware is flashed.
  For example when booting on ubi, the new firmware will be flashed
  to ubi_2 and the router will boot from ubi_2 afterwards.
  The 5th byte of the Persist partition is the boot value (0x01 or 0x02).

  During my tests, it never switched to another boot partition if the
  firmware failed boot. So if openwrt doesn't boot,
  UART might be required to recover.

Note 2: bootmenu_delay=0 is set from factory so uboot menu is hidden.

[original work]
Signed-off-by: Yuhei Amemiya <minihui@me.com>
[fixes, improvements]
Signed-off-by: INAGAKI Hiroshi <musashino.open@gmail.com>
Link: https://github.com/openwrt/openwrt/pull/22926
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
2026-05-03 01:14:11 +02:00
John Audia
e4b3d5c799 kernel: bump 6.12 to 6.12.85
Changelog: https://cdn.kernel.org/pub/linux/kernel/v6.x/ChangeLog-6.12.85

Checksum update only/no patches touched by update_kernel.sh

Fixes: CVE‑2026‑31431 ("Copy Fail")

Signed-off-by: John Audia <therealgraysky@proton.me>
Link: https://github.com/openwrt/openwrt/pull/23178
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
2026-05-02 01:24:44 +02:00
John Audia
1850619ba0 kernel: bump 6.18 to 6.18.26
Changelog: https://cdn.kernel.org/pub/linux/kernel/v6.x/ChangeLog-6.18.26

Checksum update only/no patches touched by update_kernel.sh

Build system: x86/64
Build-tested: x86/64-glibc
Run-tested: x86/64-glibc

Signed-off-by: John Audia <therealgraysky@proton.me>
Link: https://github.com/openwrt/openwrt/pull/23177
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
2026-05-02 01:10:58 +02:00
Jonas Jelonek
84233220d3 realtek: dts: rtl93xx: use macro for PHY port definitions
Use SWITCH_PORT_LED instead of full verbose port definitions to
simplify and clean up the DTS.

Signed-off-by: Jonas Jelonek <jelonek.jonas@gmail.com>
Link: https://github.com/openwrt/openwrt/pull/23118
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
2026-05-01 12:41:49 +02:00
Jonas Jelonek
322f8e6771 realtek: dts: rtl93xx: use PHY_* macros for Zyxel XGS1X10/1250
Replace the verbose ethernet-phy node definitions with the PHY_C45 and
PHY_C45_PAIR_ORDER macros to drop boilerplate.

Signed-off-by: Jonas Jelonek <jelonek.jonas@gmail.com>
Link: https://github.com/openwrt/openwrt/pull/23118
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
2026-05-01 12:41:49 +02:00
Jonas Jelonek
0136c48bd5 realtek: dts: rtl93xx: replace LED magic values with macros
Replace the raw bitmask values for led_set entries with the
RTL93XX_LED_SET_* macros from macros.dtsi to make the LED configuration
self-explanatory.

Signed-off-by: Jonas Jelonek <jelonek.jonas@gmail.com>
Link: https://github.com/openwrt/openwrt/pull/23118
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
2026-05-01 12:41:49 +02:00
Jonas Jelonek
858dfdd832 realtek: dts: rtl93xx: use SWITCH_PORT_SFP for ports
Make use of the SWITCH_PORT_SFP macro to simplify and make the DTS of
several devices cleaner.

Signed-off-by: Jonas Jelonek <jelonek.jonas@gmail.com>
Link: https://github.com/openwrt/openwrt/pull/23118
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
2026-05-01 12:41:49 +02:00
Markus Stockhausen
d12e654a34 realtek: mdio: convert to generic regmap_bulk_write()
Each architecture has its own SMI address and SMI data size. Make the
current device specific coding generic by

- adding SMI start address and SMI data size to configuration structure
- moving regmap_bulk_write() over to the generic rtmdio_run_cmd()
- deleting all device specific rtmdio_xxxx_run_cmd() versions

Signed-off-by: Markus Stockhausen <markus.stockhausen@gmx.de>
Link: https://github.com/openwrt/openwrt/pull/23092
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
2026-05-01 12:14:50 +02:00
Markus Stockhausen
c87e07e906 realtek: mdio: generic read handling
Each target has a specific SMI register where the result of read
commands is stored. As the read logic is always the same convert
the current logic to a generic one. Instead of a target specific
coding move eveything into the configuration structure and let
rtmdio_run_cmd() do the work.

Signed-off-by: Markus Stockhausen <markus.stockhausen@gmx.de>
Link: https://github.com/openwrt/openwrt/pull/23092
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
2026-05-01 12:14:50 +02:00
Markus Stockhausen
2283548d7e realtek: mdio: move command data into config structure
Until now the device specific I/O helpers are instrumented by individual
call parameters. Move this information over to the configuration structure.
This simplifies the code at the calling locations.

Signed-off-by: Markus Stockhausen <markus.stockhausen@gmx.de>
Link: https://github.com/openwrt/openwrt/pull/23092
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
2026-05-01 12:14:50 +02:00
Markus Stockhausen
70dcb8c291 realtek: mdio: use regmap_bulk_write() in RTL931x path
Convert the RTL931x I/O path to the new bulk write pattern. For this

- Enhance the rtmdio_931x_run_cmd() helper to take care of all register
  access and error handling.
- Convert the c22/c45/read/write functions so that they only prepare
  the I/O data without any register access.

Signed-off-by: Markus Stockhausen <markus.stockhausen@gmx.de>
Link: https://github.com/openwrt/openwrt/pull/23092
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
2026-05-01 12:14:50 +02:00
Markus Stockhausen
280808d8dd realtek: mdio: use regmap_bulk_write() in RTL930x path
Convert the RTL930x I/O path to the new bulk write pattern. For this

- Enhance the rtmdio_930x_run_cmd() helper to take care of all register
  access and error handling.
- Convert the c22/c45/read/write functions so that they only prepare
  the I/O data without any register access.

Signed-off-by: Markus Stockhausen <markus.stockhausen@gmx.de>
Link: https://github.com/openwrt/openwrt/pull/23092
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
2026-05-01 12:14:50 +02:00
Markus Stockhausen
5915fa8b74 realtek: mdio: use regmap_bulk_write() in RTL839x path
Convert the RTL839x I/O path to the new bulk write pattern. For this

- Enhance the rtmdio_839x_run_cmd() helper to take care of all register
  access and error handling.
- Convert the c22/c45/read/write functions so that they only prepare
  the I/O data without any register access.

Signed-off-by: Markus Stockhausen <markus.stockhausen@gmx.de>
Link: https://github.com/openwrt/openwrt/pull/23092
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
2026-05-01 12:14:50 +02:00
Markus Stockhausen
2d2f0fbc70 realtek: mdio: use regmap_bulk_write() in RTL838x path
The regmap conversion only replaced the old sw() macros with their
regmap counterparts. Neither access optimization nor error handling
took place. Redesign the mdio access as follows:

- The c22/c45/read/write functions only prepare a data structure
  that describes the to-be-executed command.
- rtmdio_xxxx_run_cmd() is enhanced to bulk write the data into the
  SoC, issue all the I/O and do proper error handling. Additionally
  the signature is changed to allow read & write operations.

The bulk commands introduce some subtle changes.

- Before this patch only the needed registers were written. After
  the conversion all phy control registers are set up.
- The register write order changes

This is no issue as the hardware starts operation when issuing the
run_cmd() and only accesses the needed registers per operation.

For now adapt only the RTL838x path. Where needed rename "err" to
"ret" for consistency with kernel conventions.

Signed-off-by: Markus Stockhausen <markus.stockhausen@gmx.de>
Link: https://github.com/openwrt/openwrt/pull/23092
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
2026-05-01 12:14:50 +02:00
Hauke Mehrtens
5309d460b0 realtek: refresh patches
Make the patches apply cleanly again.

Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
2026-05-01 10:46:39 +02:00
Hauke Mehrtens
a73e378bea kernel: Refresh patches
Refresh the patches.

Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
2026-05-01 00:56:52 +02:00
Jörg Seitz
b84184a526 mediatek: filogic: add support for zbt-z8103ax-d
Device support for zbt-z8103ax-d

Model D DTS is identical to Model C zbt-z8103ax-c.
Both models share same motherboard.

Difference between models is

 - Model C is a cylinder shape enclosure
   containing internal antennas.
 - Model D is a sandwich shape enclosure
   with 6 external antennas.

Specifications:

SoC: MediaTek MT7981B
RAM: 256MiB
Flash: Winbond SPI-NAND 128 MiB
Switch: 1 WAN, 3 LAN (Gigabit) MediaTek MT7531
Buttons: Reset, Mesh
Power: DC 12V 1A
WiFi: MT7981B 2.4Ghz & 5.8Ghz

Led Layout from left to right:

    Power
    Mesh (RGB Led, user controllable, default set to OpenWrt Status)
    WLAN 2.4G (user controllable)
    WAN (user controllable)
    LAN3
    LAN2
    LAN1
    WLAN 5G (user controllable)

Installation:

A. Through U-Boot menu:

    - Prepare your connecting computer to use static IP
        (legacy notation) 192.168.1.10 netmask 255.255.255.0
        (CIDR notation)   192.168.1.10/24
    - Power down the router and hold in the Reset button.
    - While holding in the button power up the router again.
    - Hold the button in for 10 seconds and then release.
    - Use your browser to go to 192.168.1.1
    - If you see a GUI allowing for flashing firmware you are at the right spot.
    - Upload the **Factory** image file.

Note: U-Boot GUI it can be used to recover from an incorrect firmware flash.

B. Through OpenWrt Dashboard:

    If your router comes with OpenWrt preinstalled (modified by the seller),
    you can easily upgrade by going to the dashboard (192.168.1.1)
    and then navigate to
    System -> Backup/Flash firmware, then flash the firmware

MAC Addresses:

MAC Addresses were found in Factory partition:

offset 0x4  F8:5E:3C:xx:xx:aa --> Router Label -2
offset 0xa  F8:5E:3C:xx:xx:bb --> Router Label -1
offset 0x24 F8:5E:3C:xx:xx:cc --> Router Label +1
offset 0x2a F8:5E:3C:xx:xx:yy --> printed on Router Label

Signed-off-by: Jörg Seitz <github.joeterminal@xoxy.net>
Link: https://github.com/openwrt/openwrt/pull/21626
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
2026-04-30 23:57:13 +02:00
Jörg Seitz
8dba7a692c mediatek: update device tree of zbt-z8103ax for nmbm
Nand has a valid mediatek nand badblock management (NMBM) signature.
Gets used for non-UBI partions BL2, u-boot-env, Factory and FIT.

Signed-off-by: Jörg Seitz <github.joeterminal@xoxy.net>
Link: https://github.com/openwrt/openwrt/pull/21626
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
2026-04-30 23:57:13 +02:00
Shiji Yang
5a9cfbbc18 ramips: mt7621: disable CONFIG_PAGE_POOL_STATS
Commit 15887235c1e3 ("generic: mtk_eth_soc: reduce driver memory usage")
allows building mediatek ethernet driver without CONFIG_PAGE_POOL_STATS.
This can slightly improve throughput on legacy MIPS based MT7621 SoC.

Signed-off-by: Shiji Yang <yangshiji66@outlook.com>
Link: https://github.com/openwrt/openwrt/pull/23142
Signed-off-by: Robert Marko <robimarko@gmail.com>
2026-04-30 10:42:06 +02:00
John Audia
25190c6631 kernel: bump 6.12 to 6.12.84
Changelog: https://cdn.kernel.org/pub/linux/kernel/v6.x/ChangeLog-6.12.84

All patches automatically rebased via update_kernel.sh

Signed-off-by: John Audia <therealgraysky@proton.me>
Link: https://github.com/openwrt/openwrt/pull/22913
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
2026-04-30 01:31:44 +02:00
John Audia
39964c9909 kernel: bump 6.12 to 6.12.83
Changelog: https://cdn.kernel.org/pub/linux/kernel/v6.x/ChangeLog-6.12.83

All patches automatically rebased via update_kernel.sh

Signed-off-by: John Audia <therealgraysky@proton.me>
Link: https://github.com/openwrt/openwrt/pull/22913
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
2026-04-30 01:31:44 +02:00
John Audia
9944b3454c kernel: bump 6.12 to 6.12.82
Changelog: https://cdn.kernel.org/pub/linux/kernel/v6.x/ChangeLog-6.12.82

Removed upstreamed:
 generic/pending-6.12/360-Revert-MIPS-mm-kmalloc-tlb_vpn-array-to-avoid-stack-.patch[1,2]
 generic/pending-6.12/361-Revert-MIPS-mm-Prevent-a-TLB-shutdown-on-initial-uni.patch[3]

All other patches automatically rebased via update_kernel.sh

Upstream fixed booting the RealTek MIPS 4KEc SoCs. The reverts are not
needed any more.

1. https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git/commit/?h=v6.12.82&id=16a49e3fda339aa552cde7f2cdbb25b91426cb8a
2. https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git/commit/?h=v6.12.82&id=497f7f97894684b62a86201953ca028a3836e48e
3. https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git/commit/?h=v6.12.82&id=d937204d13f9a25b559b7fb94faf178640fb6af5

Signed-off-by: John Audia <therealgraysky@proton.me>
Link: https://github.com/openwrt/openwrt/pull/22913
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
2026-04-30 01:31:44 +02:00
John Audia
8d827ccc93 kernel: bump 6.12 to 6.12.81
Changelog: https://cdn.kernel.org/pub/linux/kernel/v6.x/ChangeLog-6.12.81

Removed upstreamed:
  ramips/patches-6.12/100-mips-ralink-update-CPU-clock-index.patch[1]
  airoha/patches-6.12/135-v7.1-net-airoha-Add-missing-cleanup-bits-in-airoha_qdma_c.patch[2]

Manually rebased:
  airoha/patches-6.12/048-01-v6.15-net-airoha-Move-airoha_eth-driver-in-a-dedicated-fol.patch

All other patches automatically rebased.

1. https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git/commit/?h=v6.12.81&id=e8fd60338545f4bc9c23d3d4686c88324aa76fb8
2. https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git/commit/?h=v6.12.81&id=cce5027f9dc3a333ccbcd59a2c3ab2906bd08d30

Signed-off-by: John Audia <therealgraysky@proton.me>
Link: https://github.com/openwrt/openwrt/pull/22913
[Modify airoha move patch]
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
2026-04-30 01:31:44 +02:00
John Audia
ed4b6ad372 kernel: bump 6.18 to 6.18.25
Changelog: https://cdn.kernel.org/pub/linux/kernel/v6.x/ChangeLog-6.18.25

Manually rebased:
  generic/pending-6.18/795-09-net-ethernet-mtk_ppe-offload-flows-to-MxL862xx-switc.patch

All other patches automatically rebased via update_kernel.sh

Build system: x86/64
Build-tested: x86/64-glibc
Run-tested: x86/64-glibc

Signed-off-by: John Audia <therealgraysky@proton.me>
Link: https://github.com/openwrt/openwrt/pull/22890
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
2026-04-30 01:15:19 +02:00
John Audia
8ce1a59bb3 kernel: bump 6.18 to 6.18.24
Changelog: https://cdn.kernel.org/pub/linux/kernel/v6.x/ChangeLog-6.18.24

Removed upstreamed:
  backport-6.18/710-02-v7.1-net-sfp-add-quirks-for-Hisense-and-HSGQ-GPON-ONT-SFP.patch[1]

All patches automatically rebased via update_kernel.sh

https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git/commit/?h=v6.18.24&id=0a59c12ce50a768e84982b65cce9c33459ef72d0

Build system: x86/64
Build-tested: x86/64-glibc
Run-tested: x86/64-glibc

Signed-off-by: John Audia <therealgraysky@proton.me>
Link: https://github.com/openwrt/openwrt/pull/22890
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
2026-04-30 01:15:19 +02:00
John Audia
35bbca2465 kernel: bump 6.18 to 6.18.23
Changelog: https://cdn.kernel.org/pub/linux/kernel/v6.x/ChangeLog-6.18.23

Removed upstreamed:
  generic/pending-6.18/360-Revert-MIPS-mm-kmalloc-tlb_vpn-array-to-avoid-stack-.patch[1,2]
  generic/pending-6.18/361-Revert-MIPS-mm-Prevent-a-TLB-shutdown-on-initial-uni.patch[3]

All other patches automatically rebased via update_kernel.sh

Upstream fixed booting the RealTek MIPS 4KEc SoCs. The reverts are not
needed any more.

1. https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git/commit/?h=v6.18.23&id=ccc6a2241a49f68d8656ab1e10df377acfe2c5b4
2. https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git/commit/?h=v6.18.23&id=6c600fc0e99180c7a1b91c93e359009be8b4cfc2
3. https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git/commit/?h=v6.18.23&id=d8b281165a86041bb40e055eb79f735826d0df1b

Build system: x86/64
Build-tested: x86/64-glibc
Run-tested: x86/64-glibc

Signed-off-by: John Audia <therealgraysky@proton.me>
Link: https://github.com/openwrt/openwrt/pull/22890
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
2026-04-30 01:14:23 +02:00
John Audia
c252e6d3b1 kernel: bump 6.18 to 6.18.22
Changelog: https://cdn.kernel.org/pub/linux/kernel/v6.x/ChangeLog-6.18.22

Removed upstreamed:
  ramips/patches-6.18/100-mips-ralink-update-CPU-clock-index.patch[1]

Manually rebased:
  pending-6.18/361-Revert-MIPS-mm-Prevent-a-TLB-shutdown-on-initial-uni.patch

All patches automatically rebased.

1. https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git/commit/?h=v6.18.22&id=a99f94e4f28a3c289bd397d521de1187b6320158

Build system: x86/64
Build-tested: x86/64-glibc
Run-tested: x86/64-glibc

Signed-off-by: John Audia <therealgraysky@proton.me>
Link: https://github.com/openwrt/openwrt/pull/22890
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
2026-04-30 01:14:12 +02:00
Fil Dunsky
95fb8e4353 mediatek: nmbm fix for Huasifei WH3000 Pro NAND
This commit adds missing nmbm parameters to device dts.

Before:
```
[   13.065277] ubi0 warning: ubi_eba_init: cannot reserve enough PEBs for bad PEB handling, reserved 36, need 40
[   13.184624] ubi0: attached mtd4 (name "ubi", size 226 MiB)
[   13.250170] ubi0: PEB size: 131072 bytes (128 KiB), LEB size: 126976 bytes
[   13.332343] ubi0: min./max. I/O unit sizes: 2048/2048, sub-page size 2048
[   13.413459] ubi0: VID header offset: 2048 (aligned 2048), data offset: 4096
[   13.496659] ubi0: good PEBs: 1812, bad PEBs: 0, corrupted PEBs: 0
[   13.569460] ubi0: user volume: 3, internal volumes: 1, max. volumes count: 128
[   13.655780] ubi0: max/mean erase counter: 2/1, WL threshold: 4096, image sequence number: 1717500926
[   13.764971] ubi0: available PEBs: 0, total reserved PEBs: 1812, PEBs reserved for bad PEB handling: 36
```

After:
```
[    0.939053] spi-nand spi0.0: Winbond SPI NAND was found.
[    0.944422] spi-nand spi0.0: 256 MiB, block size: 128 KiB, page size: 2048, OOB size: 128
[    0.953256] Signature found at block 2047 [0x0ffe0000]
[    0.958389] NMBM management region starts at block 1920 [0x0f000000]
[    0.966032] First info table with writecount 0 found in block 1920
[    0.975792] Second info table with writecount 0 found in block 1923
[    0.982076] NMBM has been successfully attached
[    0.986815] 5 fixed-partitions partitions found on MTD device spi0.0
[    0.993245] Creating 5 MTD partitions on "spi0.0":
[    0.998028] 0x000000000000-0x000000100000 : "BL2"
[    1.003825] 0x000000100000-0x000000180000 : "u-boot-env"
[    1.009867] 0x000000180000-0x000000380000 : "Factory"
[    1.016776] 0x000000380000-0x000000580000 : "FIP"
[    1.023109] 0x000000580000-0x00000e780000 : "ubi"
[    1.724925] ubi0: default fastmap pool size: 90
[    1.729444] ubi0: default fastmap WL pool size: 45
[    1.734256] ubi0: attaching mtd4
[    2.441513] ubi0: scanning is finished
[    2.451382] ubi0: attached mtd4 (name "ubi", size 226 MiB)
[    2.456876] ubi0: PEB size: 131072 bytes (128 KiB), LEB size: 126976 bytes
[    2.463753] ubi0: min./max. I/O unit sizes: 2048/2048, sub-page size 2048
[    2.470528] ubi0: VID header offset: 2048 (aligned 2048), data offset: 4096
[    2.477481] ubi0: good PEBs: 1808, bad PEBs: 0, corrupted PEBs: 0
[    2.483567] ubi0: user volume: 3, internal volumes: 1, max. volumes count: 128
[    2.490775] ubi0: max/mean erase counter: 2/1, WL threshold: 4096, image sequence number: 0
[    2.499114] ubi0: available PEBs: 0, total reserved PEBs: 1808, PEBs reserved for bad PEB handling: 38
```

Signed-off-by: Fil Dunsky <filipp.dunsky@gmail.com>
Link: https://github.com/openwrt/openwrt/pull/23153
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
2026-04-30 00:20:39 +02:00
Markus Stockhausen
a30c6aa556 realtek: dsa: drop array from stp_get signature
Now that the stp_set() helpers have been refactored the stp_get()
helpers can be simplified. Drop the last array parameter. It is
no longer needed/evaluated by its callers.

Signed-off-by: Markus Stockhausen <markus.stockhausen@gmx.de>
Link: https://github.com/openwrt/openwrt/pull/23080
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
2026-04-29 23:23:11 +02:00
Markus Stockhausen
4b8af19582 realtek: dsa: remove family_id check from xstp_state_set()
The rtldsa_port_xstp_state_set() function offers a generic interface
to its callers to set the bridge state of one port. While it calls
device specific helpers in the background it runs the data mapping
for each architecture with a family_id check on its own. So the
hardware abstraction is done in two places

- rtldsa_port_xstp_state_set() translates one half
- its helper translate the other half

Convert the signature of the device specific helpers so that this
function does not need to know any hardware details. Instead move
the table/offset/bit calculations into the helpers. This way the
code path uses a consistent hardware abstraction.

- rtldsa_port_xstp_state_set() calls the helpers
- helpers do the hardware translation

Signed-off-by: Markus Stockhausen <markus.stockhausen@gmx.de>
Link: https://github.com/openwrt/openwrt/pull/23080
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
2026-04-29 23:23:11 +02:00
Hannu Nyman
9a6c754d7d sdk: add support to sign each .apk package by sdk
Add support to signing each package's .apk file into SDK.
This adds into SDK the feature added by f20794a to the normal builds.

Currently SDK does not sign the compiled packages, causing untrusted
package errors at package installation. The reason is the logic of
defaulting to 'n' in BUILDBOT and 'y' elsewhere. As downloadable SDKs
are compiled by the buildbot, the option gets 'n' set as the default.
And the option is not among the few build options exposed in the SDK
menuconfig, so the user can't easily change it.

Enable the feature by default:

* Exclude the SIGN_EACH_PACKAGE option from sdk/convert-config.pl
* Default to 'y' and expose the option in the SDK config menu.

(Avoiding untrusted errors naturally requires the user to copy the
public key into the router, quite similar as with full builds.)

Signed-off-by: Hannu Nyman <hannu.nyman@iki.fi>
Link: https://github.com/openwrt/openwrt/pull/23104
Signed-off-by: Robert Marko <robert.marko@sartura.hr>
2026-04-29 12:43:54 +02:00
Robert Marko
30c4c4301e microchipsw: fix LAN8814 QSGMII soft reset
Currently, moving from a port on one LAN8814 PHY package to another results
in a no traffic flowing on that new port.

It was tracked down to upstream change that fixed the issue that QSGMII
was soft reset on .config_init of each of 4 PHY-s in the package resulting
in a temporary traffic loss until QSGMII resynced.

However, it seems that the QSGMII soft reset timing is crucial and doing
the reset during probe only cause the QSGMII link to become partially
unsynced (Like 2 or 3 lanes are not synced).

So, add an upstream pending patch[1] to fix this, patch was modified as we
dont have the inband caps currently.

[1] https://patchwork.kernel.org/project/netdevbpf/patch/20260428134138.1741253-1-robert.marko@sartura.hr/

Signed-off-by: Robert Marko <robert.marko@sartura.hr>
2026-04-29 11:40:10 +02:00
Christoph Krapp
9c2e0ba8d8 ipq50xx: add label-mac-device to Linksys MX5500
Add the label-mac-device alias to the device dts.

Signed-off-by: Christoph Krapp <achterin@gmail.com>
Link: https://github.com/openwrt/openwrt/pull/23134
Signed-off-by: Robert Marko <robimarko@gmail.com>
2026-04-29 10:07:09 +02:00
Rosen Penev
4e49582fca bcm53xx: add ramdisk to FEATURES
Cisco/Meraki mx64/mx65 targets require initramfs
( ramdisk) for install.
Add it to default target build.

Signed-off-by: Evan Jobling <evan.jobling at mslsc.com.au>
Signed-off-by: Rosen Penev <rosenp@gmail.com>
Link: https://github.com/openwrt/openwrt/pull/22835
Signed-off-by: Robert Marko <robimarko@gmail.com>
2026-04-29 09:56:37 +02:00
Shiji Yang
11ca5f3957
generic: overlay: disable OVERLAY_FS_REDIRECT_ALWAYS_FOLLOW
The Kconfig symbol help text prompts:
  Disable this to get a possibly more secure configuration, but that
  might not be backward compatible with previous kernels.
  If backward compatibility is not an issue, then it is safe and
  recommended to say N here.

For OpenWrt, when updating firmware, we always update the kernel and
recreate the overlay partition. Therefore, compatibility is not a
problem.

Signed-off-by: Shiji Yang <yangshiji66@outlook.com>
Link: https://github.com/openwrt/openwrt/pull/23126
Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
2026-04-29 09:34:31 +02:00
Christian Marangi
1b9922d5e8
airoha: backport fixes merged in net upstream tree
Airoha reported some bug in the TX/RX descriptor handling and PPE. Backport
the fix for such bug merged in net staging tree.

It's expected that these patch will be dropped in future minor kernel
version when submitted to stable staging tree.

All affected patch automatically refreshed.

Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
2026-04-28 20:09:03 +02:00
Zoltan HERPAI
4ca22b16e8 sunxi: drop support for 6.12
Drop support for 6.12 by removing config and patches.

Signed-off-by: Zoltan HERPAI <wigyori@uid0.hu>
2026-04-28 11:27:46 +02:00
Zoltan HERPAI
3cff8f06bd sunxi: switch to 6.18
Make 6.18 the default kernel.

Signed-off-by: Zoltan HERPAI <wigyori@uid0.hu>
2026-04-28 11:27:45 +02:00
Sven Eckelmann
fcb2ff6ec6 realtek: rtl930x: mcx3: specify RTL8224 reset GPIO
The nRESET pins of the RTL8224 PHY on the MCX3 are wired to GPIO6 of the
SoC, but this was never described in the devicetree.

Commit c99a30668d5f ("realtek: add RTL8224 initialization to Realtek
driver") introduced support for reinitializing RTL8224 PHYs, and commit
084da38a2e74 ("realtek: mdio: activate multiple busses") allowed the MDIO
bus provider load the devicetree properties to the bus, including reset
descriptors. With both in place, a bus level PHY reset via the hardware pin
is now correctly triggered before reinitialization.

Add the missing reset-gpios property so the PHY can be reset via the
hardware pin.

Signed-off-by: Sven Eckelmann <sven@narfation.org>
Link: https://github.com/openwrt/openwrt/pull/22966
Signed-off-by: Robert Marko <robimarko@gmail.com>
2026-04-28 11:24:28 +02:00
Mieczyslaw Nalewaj
54cb211d50 ramips: remove hack and use safexcel-eip93ies
Remove legacy hack patch, switch mt7621 crypto node to the intended
Safexcel insecure EIP93 compatible string and simplify crypto module
packaging to use the inside-secure eip93 driver.

Signed-off-by: Mieczyslaw Nalewaj <namiltd@yahoo.com>
Link: https://github.com/openwrt/openwrt/pull/22871
Signed-off-by: Nick Hainke <vincent@systemli.org>
2026-04-28 09:44:04 +02:00
Mieczyslaw Nalewaj
47430172e7 ramips: drop 6.12 support
Drop patches and configs for Linux 6.12.

Signed-off-by: Mieczyslaw Nalewaj <namiltd@yahoo.com>
Link: https://github.com/openwrt/openwrt/pull/22871
Signed-off-by: Nick Hainke <vincent@systemli.org>
2026-04-28 09:44:04 +02:00
Mieczyslaw Nalewaj
1bc1b98de9 ramips: use kernel 6.18 by default
Switch to Linux kernel version 6.18.

Signed-off-by: Mieczyslaw Nalewaj <namiltd@yahoo.com>
Link: https://github.com/openwrt/openwrt/pull/22871
Signed-off-by: Nick Hainke <vincent@systemli.org>
2026-04-28 09:44:03 +02:00
Aleksander Jan Bajkowski
b6f2b5ea13 kernel: backport crypto selftests
FIPS 140-3 recommends that all crypto implementations should be tested
before first use. Testmanager performs initial tests based on existing
test vectors. Not all algorithms have defined test vectors, so to improve
this situation, this commit backports recently added test vectors for
some cipher suites.

These vectors were calculated using a software implementation and then
double-checked on Mediatek MT7981 (safexcel) and NXP P2020 (talitos).
Both platforms passed self-tests.

Signed-off-by: Aleksander Jan Bajkowski <olek2@wp.pl>
Link: https://github.com/openwrt/openwrt/pull/23012
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
2026-04-28 00:52:07 +02:00
Markus Stockhausen
0ba4e2c971 realtek: mdio: convert to regmap_assign_bits()
Use regmap_assign_bits() where it improves readability. With this
there is no need to calculate masks and values in separate lines.

Splitting the single update_bits() in rtmdio_931x_setup_polling()
into two separate assign_bits() is uncritical.

Signed-off-by: Markus Stockhausen <markus.stockhausen@gmx.de>
Link: https://github.com/openwrt/openwrt/pull/23099
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
2026-04-28 00:41:18 +02:00
Rustam Adilov
596ce2845d realtek: arch: rtl-otto: add rtl9607 model info support
Add the registers, family id and cpu port defines to the mach header.
Since RTL96xx SoCs has additional "subtype" info, add the respective
property to soc_info struct to be used in prom file.

The same way as rtl838x, the chip_info register requires 0xa to be
written. Similarly, 0xb must be written to get the subtype info.
There doesn't seem any check for testchip in RTL96xx so, we ignore it.

Add subtype information to set_system_type function if it is present
using the added subtype variable.

There are some RTL9607 chips out there with 512MB so add the check
for RTL9607 in the prepare_highmem. The registers are the same as
in RTL9300 so nothing else need to be changed.

Signed-off-by: Rustam Adilov <adilov@tutamail.com>
Link: https://github.com/openwrt/openwrt/pull/23023
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
2026-04-28 00:29:57 +02:00
Jonas Jelonek
0509464a93 realtek: refresh 'add-pcs-rtl-otto' patch
Refresh the patch to account for recent changes in the generic kernel
patches. Makes the CI kernel patch check happy again.

Fixes: c271123724fc ("generic: 6.18: fix MediaTek USXGMII driver")
Signed-off-by: Jonas Jelonek <jelonek.jonas@gmail.com>
Link: https://github.com/openwrt/openwrt/pull/23127
Signed-off-by: Robert Marko <robimarko@gmail.com>
2026-04-27 15:23:43 +02:00
Daniel Golle
dbd8eab75d generic: 6.18: mtk_eth_soc: improve non-MTK tag_8021q DSA
Add patches to improve support for using 3rd-party DSA switches
like MaxLinear MxL862xx with MediaTek's mtk_eth_soc being the
conduit. This involves reorganizing hardware queues to avoid
overlap (currently dp->index is used -- if there is more than one
DSA switch this is problematic), and correctly programming flows
of the non-MTK DSA users ports in the PPE offloading engine.

Signed-off-by: Daniel Golle <daniel@makrotopia.org>
2026-04-27 13:12:03 +01:00