]> git.ipfire.org Git - thirdparty/openwrt.git/log
thirdparty/openwrt.git
25 hours agoutil-linux: update to 2.41.3 21276/head
Wei-Ting Yang [Wed, 24 Dec 2025 15:20:12 +0000 (23:20 +0800)] 
util-linux: update to 2.41.3

Release notes:
https://www.kernel.org/pub/linux/utils/util-linux/v2.41/v2.41.3-ReleaseNotes

Also update URL to use HTTPS.

Signed-off-by: Wei-Ting Yang <williamatcg@gmail.com>
Link: https://github.com/openwrt/openwrt/pull/21276
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
25 hours agotools: util-linux: update to 2.41.3
Wei-Ting Yang [Wed, 24 Dec 2025 15:16:00 +0000 (23:16 +0800)] 
tools: util-linux: update to 2.41.3

Release notes:
https://www.kernel.org/pub/linux/utils/util-linux/v2.41/v2.41.3-ReleaseNotes

Remove upstreamed:
110-meson-fix-a-bug-in-posixipc_libs-configuration.patch

Signed-off-by: Wei-Ting Yang <williamatcg@gmail.com>
Link: https://github.com/openwrt/openwrt/pull/21276
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
34 hours agolibiwinfo: update to Git HEAD (2025-11-29) 18227/head 21347/head
Hauke Mehrtens [Wed, 31 Dec 2025 20:33:08 +0000 (21:33 +0100)] 
libiwinfo: update to Git HEAD (2025-11-29)

2ebef3da84e8 iwinfo: Query hostapd for 'ssid2'

Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
Link: https://github.com/openwrt/openwrt/pull/21347
Signed-off-by: Robert Marko <robimarko@gmail.com>
2 days agorealtek: setup cpu port in soc_info structure 21327/head
Markus Stockhausen [Tue, 30 Dec 2025 13:07:32 +0000 (14:07 +0100)] 
realtek: setup cpu port in soc_info structure

A lot of soc_info usage has been reorganized. Nevertheless there
are some consumers left. A very critical one is the dsa/qos coding.
It makes use of the cpu_port in this shared structure. This is
totally broken as that info is never properly initialized. Fill
the cpu_port according to the identified hardware.

Remark: Looking at the prom.c history soc_info.cpu_port was never
setup since the beginning of time. So no "fixes" tag here.

Signed-off-by: Markus Stockhausen <markus.stockhausen@gmx.de>
Link: https://github.com/openwrt/openwrt/pull/21327
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
2 days agorealtek: RTL930x: setup highmem registers during init
Markus Stockhausen [Tue, 30 Dec 2025 10:02:04 +0000 (11:02 +0100)] 
realtek: RTL930x: setup highmem registers during init

For some reason the highmem configuration of RTL930x
devices was totally missed until now. Take over the
setup from the SDK. This will avoid boot stalls on
switches with more than 256 MB RAM when switching
over to kernel 6.18.

Signed-off-by: Markus Stockhausen <markus.stockhausen@gmx.de>
Link: https://github.com/openwrt/openwrt/pull/21327
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
2 days agorealtek: determine memory size during initialization
Markus Stockhausen [Tue, 30 Dec 2025 09:33:32 +0000 (10:33 +0100)] 
realtek: determine memory size during initialization

For proper highmem initialization on RTL930x the size of the
installed memory is needed during early bootup. Enhance the
soc_info structure and fill the data from the registers.

While we are here remove the obsolete compatible variable from
the soc_info structure.

Adapt boot message to show the memory size.

old: SoC Type: Realtek RTL9301 rev B (6487)
new: Realtek RTL9301 rev B (6487) SoC with 512 MB

Signed-off-by: Markus Stockhausen <markus.stockhausen@gmx.de>
Link: https://github.com/openwrt/openwrt/pull/21327
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
2 days agorealtek: harmonize variables in prom.c
Markus Stockhausen [Tue, 30 Dec 2025 08:59:26 +0000 (09:59 +0100)] 
realtek: harmonize variables in prom.c

There is mix of variable naming in prom.c. Use a fixed
prefix of "rtl_" for all static variables. Additionally
remove the prefix from rtl83xx_set_system_type as it is
a generic function for all SoC types.

Signed-off-by: Markus Stockhausen <markus.stockhausen@gmx.de>
Link: https://github.com/openwrt/openwrt/pull/21327
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
2 days agokernel/rtl8812au-ct: provide a virtual kmod 21288/head
George Sapkin [Sun, 28 Dec 2025 15:37:08 +0000 (17:37 +0200)] 
kernel/rtl8812au-ct: provide a virtual kmod

Switch rtl8812au-ct to use the new virtual kmod provides semantic.

Signed-off-by: George Sapkin <george@sapk.in>
Link: https://github.com/openwrt/openwrt/pull/21288
Signed-off-by: Robert Marko <robimarko@gmail.com>
2 days agokernel/ath10k: provide a virtual kmod
George Sapkin [Sun, 28 Dec 2025 15:34:48 +0000 (17:34 +0200)] 
kernel/ath10k: provide a virtual kmod

Switch ath10k and related kmods to use the new virtual kmod provides
semantic and mark ath10k 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>
2 days agokernel/r8169: provide a virtual kmod
George Sapkin [Sun, 28 Dec 2025 15:30:12 +0000 (17:30 +0200)] 
kernel/r8169: provide a virtual kmod

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>
2 days agoca-certificates: provide a virtual package
George Sapkin [Thu, 25 Dec 2025 15:16:18 +0000 (17:16 +0200)] 
ca-certificates: provide a virtual package

Switch ca-certs provides to use the new virtual provides semantic that
enables ca-bundle and ca-certificates to be installed side-by-side.

Provide the new format virtual ca-certificates-any in ca-bundle.

Fixes: https://github.com/openwrt/openwrt/issues/21257
Signed-off-by: George Sapkin <george@sapk.in>
Link: https://github.com/openwrt/openwrt/pull/21288
Signed-off-by: Robert Marko <robimarko@gmail.com>
2 days agobuild: provide virtual self in kmods
George Sapkin [Sun, 28 Dec 2025 15:22:41 +0000 (17:22 +0200)] 
build: provide virtual self in kmods

Add an implicit self-provide to kmods. apk can't handle self provides,
be it versioned or virtual, so opt for a prefix and a suffix instead.
Package name without a prefix/suffix is too generic and might conflict
with other packages, e.g. wireguard. This allows several variants to
provide the same virtual package without adding extra provides to the
default one, e.g. r8169 implicitly provides kmod-r8169-any and is marked
as default, so r8125 can explicitly provide @kmod-r8169-any as well.

Signed-off-by: George Sapkin <george@sapk.in>
Link: https://github.com/openwrt/openwrt/pull/21288
Signed-off-by: Robert Marko <robimarko@gmail.com>
2 days agobuild: add support for virtual provides
George Sapkin [Thu, 25 Dec 2025 13:32:29 +0000 (15:32 +0200)] 
build: add support for virtual provides

Allow defining virtual provides using the PROVIDES field by prefixing
them with @, e.g.:

PROVIDES:=@ca-certs

Virtual provides don't own the provided name and multiple packages with
the same virtual provides can be installed side-by-side. Packages must
still take care not to override each other's files.

Add an implicit self-provide to packages. apk can't handle self
provides, be it versioned or virtual, so opt for a suffix instead. This
allows several variants to provide the same virtual package without
adding extra provides to the default one, e.g. wget implicitly provides
wget-any and is marked as default, so wget-ssl can explicitly provide
@wget-any as well.

Filter out virtual provides when generating metadata.

Filter out virtual provides prefix and self provide where appropriate.

Signed-off-by: George Sapkin <george@sapk.in>
Link: https://github.com/openwrt/openwrt/pull/21288
Signed-off-by: Robert Marko <robimarko@gmail.com>
2 days agobuild: refactor provides logic
George Sapkin [Thu, 25 Dec 2025 12:09:53 +0000 (14:09 +0200)] 
build: refactor provides logic

Refactor provides logic into a helper define and use it for both apk and
control. Document the behavior.

Store preformatted provides in Package/$(1)/PROVIDES similar to defines.

Remove unnecessary logging.

Signed-off-by: George Sapkin <george@sapk.in>
Link: https://github.com/openwrt/openwrt/pull/21288
Signed-off-by: Robert Marko <robimarko@gmail.com>
2 days agokernel: bump 6.12 to 6.12.63 21329/head
John Audia [Thu, 18 Dec 2025 15:10:55 +0000 (10:10 -0500)] 
kernel: bump 6.12 to 6.12.63

Changelog: https://cdn.kernel.org/pub/linux/kernel/v6.x/ChangeLog-6.12.63

Manually rebased:
  qualcommax/patches-6.12/0113-remoteproc-qcom-Add-secure-PIL-support.patch
  qualcommax/patches-6.12/0116-remoteproc-qcom-Update-regmap-offsets-for-halt-regis.patch

Removed upstreamed:
  airoha/patches-6.12/029-14-spi-airoha-snfi-en7523-workaround-flash-damaging.patch[1]

All other patches automatically rebased.

1. https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git/commit/?h=v6.12.63&id=7be679104357439ff6eab076975f5f74368acd69

Build system: x86/64
Build-tested: flogic/glinet_gl-mt6000, ramips/tplink_archer-a6-v3, x86/64-glibc
Run-tested: flogic/glinet_gl-mt6000, ramips/tplink_archer-a6-v3, x86/64-glibc

Co-authored-by: Goetz Goerisch <ggoerisch@gmail.com>
Signed-off-by: John Audia <therealgraysky@proton.me>
Link: https://github.com/openwrt/openwrt/pull/21329
Signed-off-by: Robert Marko <robimarko@gmail.com>
2 days agogeneric: add missing symbol
John Audia [Fri, 19 Dec 2025 21:37:38 +0000 (16:37 -0500)] 
generic: add missing symbol

Set SND_SOC_NAU8325 to no

Signed-off-by: John Audia <therealgraysky@proton.me>
Link: https://github.com/openwrt/openwrt/pull/21329
Signed-off-by: Robert Marko <robimarko@gmail.com>
2 days agokernel: r8168: fix CFLAGS with linux 6.15+ 21330/head
Álvaro Fernández Rojas [Tue, 30 Dec 2025 13:45:15 +0000 (14:45 +0100)] 
kernel: r8168: fix CFLAGS with linux 6.15+

Fix r8168 module CFLAGS with kernels >= v6.15.

Signed-off-by: Álvaro Fernández Rojas <noltari@gmail.com>
2 days agokernel: r8101: fix CFLAGS with linux 6.15+
Álvaro Fernández Rojas [Tue, 30 Dec 2025 13:44:10 +0000 (14:44 +0100)] 
kernel: r8101: fix CFLAGS with linux 6.15+

Fix r8101 module CFLAGS with kernels >= v6.15.

Signed-off-by: Álvaro Fernández Rojas <noltari@gmail.com>
3 days agomediatek: filogic: fix supported_devices list for gl-mt2500 20632/head
Eric Fahlgren [Mon, 3 Nov 2025 20:34:37 +0000 (12:34 -0800)] 
mediatek: filogic: fix supported_devices list for gl-mt2500

The SUPPORTED_DEVICES sets for both Maxlinear (v1) and Airoha (v2)
devices were identical, so sysupgrade was unable to detect when an
incorrect image was being installed.  This caused "soft bricking" of
devices when a v1 image was installed on a v2 device, and vice versa.

Fix this by making the supported_devices distinct for each device
version, by renaming the devices with a version-specific name.
This is reflected in the file name and the image metadata.

Fixes: https://github.com/openwrt/openwrt/issues/20566
Fixes: https://github.com/openwrt/asu/issues/1525
Signed-off-by: Eric Fahlgren <ericfahlgren@gmail.com>
Link: https://github.com/openwrt/openwrt/pull/20632
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
3 days agouboot-mediatek: comfast,cf-wr632ax: fix missing escape sequence 21283/head
Andrii Kuiukoff [Wed, 24 Dec 2025 17:50:40 +0000 (19:50 +0200)] 
uboot-mediatek: comfast,cf-wr632ax: fix missing escape sequence

Add missing escape sequence to restore terminal coloring in the OpenWrt U-Boot boot menu.

Signed-off-by: Andrii Kuiukoff <andros.ua@gmail.com>
Link: https://github.com/openwrt/openwrt/pull/21283
[Fix _bootmenu_update_title too]
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
3 days agomediatek: add ubootmod layout for Cudy WBR3000UAX v1 21225/head
Fil Dunsky [Fri, 12 Dec 2025 15:51:39 +0000 (18:51 +0300)] 
mediatek: add ubootmod layout for Cudy WBR3000UAX v1

This allows us to use the full size of nand,
which extends ubi size from 64Mb to 122.25Mb.

If you are at factory firmware, please refer
to [PR](https://github.com/openwrt/openwrt/pull/21141)
to boot into OpenWrt first.

1. Log in to the device and backup all the partitions,
especially unique `Factory` and `bdata` partitions
from System -> Backup / Flash Firmware -> Save mtdblock contents.
2. Install kmod-mtd-rw to unlock mtd partitions for writing:
```bash
apk update && apk add kmod-mtd-rw && insmod mtd-rw i_want_a_brick=1
```
3. Write new OpenWrt (U-Boot Layout) `BL2` and `FIP`:
```bash
mtd write openwrt-mediatek-filogic-cudy_wbr3000uax-v1-ubootmod-preloader.bin BL2
mtd write openwrt-mediatek-filogic-cudy_wbr3000uax-v1-ubootmod-bl31-uboot.fip FIP
```
4. Set static IP on your PC: `192.168.1.254`, gateway `192.168.1.1`
5. Serve openwrt-mediatek-filogic-cudy_wbr3000uax-v1-ubootmod-initramfs-recovery.itb
using TFTP server.
6. Connect Router LAN with PC LAN.
7. Cut off the power and re-engage, wait for TFTP recovery to complete.
8. After OpenWrt initramfs recovery has booted,
clean `/dev/mtd5` ubi partition to utilize maximum of free space & create ubootenvs:
```bash
ubidetach -p /dev/mtd5; ubiformat /dev/mtd5 -y; ubiattach -p /dev/mtd5
ubimkvol /dev/ubi0 -n 0 -N ubootenv -s 128KiB
ubimkvol /dev/ubi0 -n 1 -N ubootenv2 -s 128KiB
```
4. Perform sysupgrade.

Tested-by: 4pda users
Signed-off-by: Fil Dunsky <filipp.dunsky@gmail.com>
Link: https://github.com/openwrt/openwrt/pull/21225
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
3 days agomediatek: add support for Cudy WBR3000UAX v1
Fil Dunsky [Fri, 12 Dec 2025 13:16:50 +0000 (16:16 +0300)] 
mediatek: add support for Cudy WBR3000UAX v1

Another OEM variation of a Cudy WR3000 series device made for Russian market.

Hardware:
 - SoC: MediaTek MT7981B
 - CPU: 2x 1.3 GHz Cortex-A53
 - Flash: 128 MiB GigaDevice SPI NAND. Flash Model: F50L1G41LB, ID: C801
 - RAM: DDR3, 512 MiB
 - WLAN: 2.4 GHz, 5 GHz (MediaTek MT7976CN, 802.11ax)
 - 1x WAN MT7531 (JXD 2531Z) 10/100/1000 Mbps
 - 4x LAN 2x MT7530 (JXD 2529S) 10/100/1000 Mbps
 - USB 3.0 port
 - Buttons: Reset, WPS
 - 8x LEDs: 2x Red, 6x Blue
 - Serial console: no need to solder, just open the case and unskrew the radiator, TX-RX, RX-TX, GND-GND, VCC do not connect, 115200 8n1
 - Power: 12 VDC, 1.5 A

+---------+-------------------+-----------+
|         | MAC               | Algorithm |
+---------+-------------------+-----------+
| WAN     | 80:AF:CA:xx:xx:x1 | label+1   |
| LAN     | 80:AF:CA:xx:xx:x0 | label     |
| WLAN 2g | 80:AF:CA:xx:xx:x0 | label     |
| WLAN 5g | 82:AF:CA:xx:xx:x1 | label+1   |
+---------+-------------------+-----------+

Based on a factory layout with only 64mb partition for easier transition from factory to OpenWrt for users if the "intermediate" RSA signed firmware will be provided by Cudy.

**Installation**
The installation must be done via UART & TFTP by disassembling the router. On other occasions Cudy has distributed intermediate firmware and dts to make installation easier, but since this router is OEM special WB order for local RU market there is a possibility they will not provide it.

**Install using UART & TFTP**
1. Connect to UART.
2. Since the factory BL is locked and the boot process can not be stopped, you have to use mtkuartboot, hold reset, engage the power, boot into your payloaded bl2 & fip.
3. Connect to LAN and set your IP to 192.168.1.254.
4. Configure a TFTP server to serve openwrt-mediatek-filogic-cudy_wbr3000uax-v1-initramfs-kernel.bin file.
5. Run these steps in u-boot using the name of your file:

```
setenv bootfile openwrt-mediatek-filogic-cudy_wbr3000uax-v1-initramfs-kernel.bin
setenv ipaddr 192.168.1.1
setenv serverip 192.168.1.254
tftpboot
bootm
```

6. Router will boot into OpenWrt initramfs recovery, just open your browser `192.168.1.1` and sysupgrade with the `Keep settings` option turned off.

Tested-by: many 4pda users
Signed-off-by: Fil Dunsky <filipp.dunsky@gmail.com>
Link: https://github.com/openwrt/openwrt/pull/21225
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
3 days agoarm-trusted-firmware-mediatek: add Cudy DDR3 target
Fil Dunsky [Fri, 19 Dec 2025 21:28:16 +0000 (00:28 +0300)] 
arm-trusted-firmware-mediatek: add Cudy DDR3 target

Since there are many similar devices from Cudy (TR3000 / WR3000E / WR3000P / WR3000S / WBR3000UAX) this will allow to create OpenWrt U-Boot layout for all of them using same DDR3 target.

Tested-by: 4pda users
Signed-off-by: Fil Dunsky <filipp.dunsky@gmail.com>
Link: https://github.com/openwrt/openwrt/pull/21225
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
3 days agowifi-scripts: use OWE + country for 6GHz 21313/head
Hauke Mehrtens [Sun, 28 Dec 2025 22:03:32 +0000 (23:03 +0100)] 
wifi-scripts: use OWE + country for 6GHz

Wifi on the 6GHz band does not support open networks, configure owe by
default. 6GHz wifi also needs a country code, configure a broken country
code '00' by default to hint the user to change it.

Link: https://github.com/openwrt/openwrt/pull/21313
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
3 days agopackage: gpio-nct5104d: adapt to kernel 6.18 21218/head
John Audia [Thu, 18 Dec 2025 17:51:33 +0000 (12:51 -0500)] 
package: gpio-nct5104d: adapt to kernel 6.18

- Changing return type from void to int
- Returning error code instead of void on superio_enter() failure
- Returning 0 on success

Signed-off-by: John Audia <therealgraysky@proton.me>
Link: https://github.com/openwrt/openwrt/pull/21218
Signed-off-by: Robert Marko <robimarko@gmail.com>
3 days agowifi-scripts: don't set wpa_pairwise for wpa=0 21215/head
Leon M. Busch-George [Thu, 18 Dec 2025 21:24:51 +0000 (22:24 +0100)] 
wifi-scripts: don't set wpa_pairwise for wpa=0

Without this patch, the

    if (!config.wpa)
   config.wpa_pairwise = null;

is overwritten immediately.

Signed-off-by: Leon M. Busch-George <leon@georgemail.eu>
Link: https://github.com/openwrt/openwrt/pull/21215
Signed-off-by: Robert Marko <robimarko@gmail.com>
3 days agoodhcp6c: update to Git HEAD (2025-12-29) 21320/head
Álvaro Fernández Rojas [Mon, 29 Dec 2025 17:14:39 +0000 (18:14 +0100)] 
odhcp6c: update to Git HEAD (2025-12-29)

8abb45065f5e dhcpv6: omit IA_NA on Request
988d5fb306b3 dhcpv6: dhcpv6_send: convert whitespaces to tabs
5e1ab3bc1be8 ra: convert if block to switch
2e6682bfcaff odhcp6c: do cleanup at exit
610e4bddb8d7 config: fix potential memory leaks in error paths
bfd7597cada1 all: add log helpers
0bb93c26d14b dhcpv6: clarifying comments
65f9ee25e5eb dhcpv6: offload FQDN construction to init_dhcpv6
48dbd38122e4 dhcpv6: migrate dhcpv6_response_is_valid to switch case

https://github.com/openwrt/odhcp6c/compare/9a4d6fe802d2...8abb45065f5e

Signed-off-by: Álvaro Fernández Rojas <noltari@gmail.com>
4 days agoipq40xx: add support for Cisco Meraki MR20 20646/head
Hal Martin [Sun, 28 Dec 2025 13:43:17 +0000 (14:43 +0100)] 
ipq40xx: add support for Cisco Meraki MR20

This commit adds support for the Cisco Meraki MR20/Go GR10.

The Meraki MR20 is a Cisco 802.11ac/WiFi 5 AP with 1 Ethernet port.
It can be powered by a 12V DC barrel jack (5.5x2.5mm, center positive)
or via 802.3af POE.

The Meraki Go GR10 (codename: Maggot) is identical to the MR20
(codename: Grub), so this document will refer to both devices as the MR20.

MR20 hardware info:
* CPU: Qualcomm IPQ4029
* RAM: 256MB DDR3
* Storage: 128 MB (MX30LF1G18AC)
* Networking: 1 Gigabit Ethernet
* WiFi: QCA4019 802.11b/g/n/ac
* Serial: Internal header (J10, 2.54mm, unpopulated)

This device ships with secure boot, and cannot be flashed without
external programmers (TSOP48 NAND and I2C EEEPROM)!

Disassembly:

Remove the four rubber feet on the rear of the AP and the four
Torx T8 screws under the feet.

Using a guitar pick or similar plastic tool, insert it on the side
along the seam around the edge. Push in gently while gently lifting
the front of the housing to release the plastic retention clips.

There are 15 clips in total.

Once you have removed the plastic front (shown above already removed
so you know where the clips are), remove the 4 Philips screws holding
down the two metal WiFi antennas.

Lift the PCB gently while pushing the Ethernet port into the housing
to release it. The PCB should come free from the metal heat spreader.

The TSOP48 NAND flash (U9, Macronix/MXIC MX30LF1G18AC) is located on
the opposite side of the PCB.

To flash, you need to desolder the TSOP48 or use a 360 clip.

You also need to reprogram the I2C EEPROM (U20, Atmel 24c64).

Installation:

The dumps to flash can be found in this repository:
https://github.com/halmartin/meraki-openwrt-docs/tree/main/mr20_gr10

The device has the following flash layout (offsets with OOB data):
```
0x000000000000-0x000000100000 : "sbl1"
0x000000100000-0x000000200000 : "mibib"
0x000000200000-0x000000300000 : "bootconfig"
0x000000300000-0x000000400000 : "qsee"
0x000000400000-0x000000500000 : "qsee_alt"
0x000000500000-0x000000580000 : "cdt"
0x000000580000-0x000000600000 : "cdt_alt"
0x000000600000-0x000000680000 : "ddrparams"
0x000000700000-0x000000900000 : "u-boot"
0x000000900000-0x000000b00000 : "u-boot-backup"
0x000000b00000-0x000000b80000 : "ART"
0x000000c00000-0x000007c00000 : "ubi"
```

* Dump your original NAND (if using nanddump, include OOB data).

* Decompress `u-boot.bin.gz` dump from the GitHub repository above (dump
contains OOB data) and overwrite the `u-boot` portion of NAND from
`0x738000`-`0x948000` (length `0x210000`). Offsets here include OOB data.

* Decompress `ubi.bin.gz` dump from the GitHub repository above (dump
contains OOB data) and overwrite the `ubi` portion of NAND from
`0xc60000`-`0x8400000` (length `0x77a0000`). Offsets here include OOB data.

* Dump your original EEPROM. Change the byte at offset `0x49` to `0x1e`
(originally `0x2c` or `0x25`). Remember to re-write the EEPROM with the
modified data.
    * This can be done on Linux via the following command:
    `printf "\x1e" | dd of=/tmp/eeprom.bin bs=1 seek=$((0x49)) conv=notrunc`

**Note**: the device will not boot if you modify the board major number and
have not yet overwritten the `ubi` and `u-boot` regions of NAND.

* Resolder the NAND after overwriting the `u-boot` and `ubi` regions.

OpenWrt Installation:

* After flashing NAND and EEPROM with external programmers. Plug in an
Ethernet cable and power up the device.

* The new U-Boot build uses the space character `" "` (without quotes) to
interrupt boot.

* Interrupt U-Boot and `tftpboot` the OpenWrt initramfs image from your
tftp server
```
dhcp
setenv serverip <your_tftp>
tftpboot openwrt-ipq40xx-generic-meraki_mr20-initramfs-uImage.itb
```

* Once booted into the OpenWrt initramfs, created the `ART` ubivol with
the WiFi radio calibration from the mtd partition:
```
cat /dev/mtd10 > /tmp/ART.bin
ubiupdatevol /dev/ubi0_1 /tmp/ART.bin
```

* `scp` the `sysupgrade` image to
the device and run the normal `sysupgrade` procedure:
```
scp -O openwrt-ipq40xx-generic-meraki_mr20-squashfs-sysupgrade.bin root@192.168.1.1:/tmp/
ssh root@192.168.1.1 "sysupgrade -n /tmp/openwrt-ipq40xx-generic-meraki_mr20-squashfs-sysupgrade.bin"
```

* OpenWrt should now be installed on the device.

Signed-off-by: Hal Martin <hal.martin@gmail.com>
Link: https://github.com/openwrt/openwrt/pull/20646
Signed-off-by: Robert Marko <robimarko@gmail.com>
4 days agoipq40xx/meraki: refactor common device tree
Hal Martin [Mon, 22 Dec 2025 09:48:46 +0000 (10:48 +0100)] 
ipq40xx/meraki: refactor common device tree

qcom-ipq4029-insect-common.dtsi was common to the MR33 and MR74, but was no
longer common with the other supported Meraki devices. I have refactored
insect-common and wired-qca-common into qcom-ipq4029-meraki-common.dtsi
which contains the actual common components (e.g. NAND partitions, ART nvmem).

Individual devices reference qcom-ipq4029-meraki-insect.dtsi
plus their own individual configuration.

Signed-off-by: Hal Martin <hal.martin@gmail.com>
Link: https://github.com/openwrt/openwrt/pull/20646
Signed-off-by: Robert Marko <robimarko@gmail.com>
4 days agorealtek: pcs: rtl931x: fix SerDes mode application 20736/head
Jonas Jelonek [Sat, 20 Dec 2025 23:53:20 +0000 (23:53 +0000)] 
realtek: pcs: rtl931x: fix SerDes mode application

The SerDes mode setting at the end of rtpcs_931x_setup_serdes is
currently broken although it is mostly similar to what the SDK does [1].
It prevents several modes from being set, especially fiber modes. This
seems to be one (if not the only) issue for currently missing SFP
support.

Add a small helper function which takes cares of setting the mode, to
keep the still valid different procedure when using XSGMII mode. Only
this helper is called in rtpcs_931x_setup_serdes to keep it clean there.

As a functional change, call mode application in every case, not just
for SGMII, QSGMII and USXGMII. We can assume the SDK is misleading in
this case, either accidentially or on purpose. This makes SFP modules
work in theory. In practice, there still seem to be device-specific
issues which need to be fixed later. These issues may include no link
detection or link flapping.

[1] https://github.com/plappermaul/realtek-doc/blob/f7f85ffc14c6e575ad94f2b427106de533b888fe/sources/rtk-dms1250/src/dal/mango/dal_mango_construct.c#L2266

Signed-off-by: Jonas Jelonek <jelonek.jonas@gmail.com>
Link: https://github.com/openwrt/openwrt/pull/20736
Signed-off-by: Robert Marko <robimarko@gmail.com>
4 days agorealtek: pcs: rtl931x: streamline hardware mode setting
Jonas Jelonek [Sat, 20 Dec 2025 23:34:10 +0000 (23:34 +0000)] 
realtek: pcs: rtl931x: streamline hardware mode setting

The SDK and our code for finally applying the hardware mode are quite
confusing. There are two different "places" where a mode can be set,
in a SerDes register and in a global SerDes mode register. Neither the
SDK nor any of the datasheet/documentation serve any explanation for
that. The functions are just named "fiber_mode_set" and "mii_mode_set"
which is basically as useless as it can be to understand it.

Try to get rid off this confusion by naming the functions
'sds_set_mac_mode' and 'sds_set_ip_mode' to make clear where the mode
is set. While at it, also clarify the naming of 'config_mode' by
renaming it to 'config_hw_mode'.

The naming is based on the following assumption:

> Realtek uses an SerDes IP core design (probably from another vendor)
> in their switch. This supports a variety of modes and must be
> configured properly for each mode. Usually, changing the mode in the
> MAC's registers triggers a proper configuration of the SerDes IP block
> in the background.

> However, for some modes this seems to be incomplete, at least missing
> important parts so it doesn't work on its own in the end. In this
> case, the SerDes IP block needs to be configured manually with the
> missing bits to make it work.

There are several places in the SDK that support this assumption, both
for RTL931X and RTL930X (as they are somewhat similar), e.g. [1].

[1] https://github.com/plappermaul/realtek-doc/blob/f7f85ffc14c6e575ad94f2b427106de533b888fe/sources/rtk-dms1250/src/dal/longan/dal_longan_sds.c#L1746

Signed-off-by: Jonas Jelonek <jelonek.jonas@gmail.com>
Link: https://github.com/openwrt/openwrt/pull/20736
Signed-off-by: Robert Marko <robimarko@gmail.com>
4 days agorealtek: pcs: rtl931x: improve mode setting functions
Jonas Jelonek [Sat, 20 Dec 2025 22:18:23 +0000 (22:18 +0000)] 
realtek: pcs: rtl931x: improve mode setting functions

Improve the current mode setting functions to address a few issues:
- add missing mode from SDK reference (instead of using the
  corresponding value as a default value)
- use and return error values
- give internal variable a more meaningful name
- consistently use lowercase letters in hex values

Signed-off-by: Jonas Jelonek <jelonek.jonas@gmail.com>
Link: https://github.com/openwrt/openwrt/pull/20736
Signed-off-by: Robert Marko <robimarko@gmail.com>
4 days agorealtek: pcs: rtl931x: merge and drop unused helper
Jonas Jelonek [Sat, 20 Dec 2025 21:09:52 +0000 (21:09 +0000)] 
realtek: pcs: rtl931x: merge and drop unused helper

Merge the unused helper 'rtpcs_931x_sds_fiber_disable' into Fiber mode
setting, and drop the helper itself. As with the MII helper in a
previous commit, functionality is basically the same just with a value
for OFF mode. If functionality is required later, Fiber mode setting can
be used with the OFF mode instead of carrying the unused helper until
it's used.

Signed-off-by: Jonas Jelonek <jelonek.jonas@gmail.com>
Link: https://github.com/openwrt/openwrt/pull/20736
Signed-off-by: Robert Marko <robimarko@gmail.com>
4 days agorealtek: pcs: rtl931x: use hardware mode for mode setting
Jonas Jelonek [Sat, 20 Dec 2025 21:01:20 +0000 (21:01 +0000)] 
realtek: pcs: rtl931x: use hardware mode for mode setting

Use the hardware mode instead of PHY_INTERFACE_MODE_* mode for mode
setting. Adjust all affected functions and switch cases accordingly.

In MII mode setting, drop the case for 2500Base-X as this is a mistake.
In the SDK reference code, this doesn't exist [1].

[1] https://github.com/plappermaul/realtek-doc/blob/69d2890a2e2d7a03df6e40e2cd2c32ff5b074dcf/sources/rtk-dms1250/src/hal/phy/phy_rtl9310.c#L817

Signed-off-by: Jonas Jelonek <jelonek.jonas@gmail.com>
Link: https://github.com/openwrt/openwrt/pull/20736
Signed-off-by: Robert Marko <robimarko@gmail.com>
4 days agorealtek: pcs: rtl931x: merge helper into mode setting
Jonas Jelonek [Sat, 20 Dec 2025 20:40:12 +0000 (20:40 +0000)] 
realtek: pcs: rtl931x: merge helper into mode setting

Merge the 'rtpcs_931x_sds_disable' helper into the MII mode setting and
use that instead. The helper was essentially doing same just with a
value for OFF state.

Moreover, the name of the helper was confusing. It implied it disables
the whole SerDes. However, this is used in Fiber mode setting and thus,
cannot completely disable the SerDes.

Signed-off-by: Jonas Jelonek <jelonek.jonas@gmail.com>
Link: https://github.com/openwrt/openwrt/pull/20736
Signed-off-by: Robert Marko <robimarko@gmail.com>
4 days agorealtek: pcs: rtl931x: fix MII mode setting
Jonas Jelonek [Sat, 20 Dec 2025 21:42:34 +0000 (21:42 +0000)] 
realtek: pcs: rtl931x: fix MII mode setting

The function 'rtpcs_931x_sds_mii_mode_set' does not correctly write the
register. It just write a plain value at the determined register
address. While this works for SerDes with (id mod 4 == 0), it doesn't
for the other SerDes.

Fix that by using a corresponding shift and writing only some bits
instead of the whole register.

While at it, drop an unneeded blank line, add comment to explain a bit
that is set and use the BIT(..) helper for that instead of manual shift.

Signed-off-by: Jonas Jelonek <jelonek.jonas@gmail.com>
Link: https://github.com/openwrt/openwrt/pull/20736
Signed-off-by: Robert Marko <robimarko@gmail.com>
4 days agorealtek: pcs: rtl931x: reorder functions
Jonas Jelonek [Sat, 20 Dec 2025 18:57:35 +0000 (18:57 +0000)] 
realtek: pcs: rtl931x: reorder functions

Bring the RTL931X functions into a proper order for two purposes:
- be able to reuse code
- have blocks of logically connected functions

This just moves code, no functional changes.

Signed-off-by: Jonas Jelonek <jelonek.jonas@gmail.com>
Link: https://github.com/openwrt/openwrt/pull/20736
Signed-off-by: Robert Marko <robimarko@gmail.com>
4 days agorealtek: pcs: rtl931x: fix clearing symbol errors
Jonas Jelonek [Sat, 20 Dec 2025 18:36:56 +0000 (18:36 +0000)] 
realtek: pcs: rtl931x: fix clearing symbol errors

Fix the implementation to clear symbol errors. Up to now, it was barely
functional because important modes weren't handled. Add another function
(which is needed in the future anyway) and pick to missing bits from
that function into the symbol clearing function to handle the modes
1000Base-X and 10GBaseR too. All that is based on [1].

While at it, rename the function to adhere to a common naming scheme and
fix some minor style issues.

[1] https://github.com/plappermaul/realtek-doc/blob/69d2890a2e2d7a03df6e40e2cd2c32ff5b074dcf/sources/rtk-dms1250/src/hal/phy/phy_rtl9310.c#L703

Signed-off-by: Jonas Jelonek <jelonek.jonas@gmail.com>
Link: https://github.com/openwrt/openwrt/pull/20736
Signed-off-by: Robert Marko <robimarko@gmail.com>
4 days agorealtek: mdio: drop family leftovers 21274/head
Markus Stockhausen [Wed, 24 Dec 2025 12:05:01 +0000 (13:05 +0100)] 
realtek: mdio: drop family leftovers

Now that the bus is completely configured by the dts
compatible, drop the hard coded family detection.

Signed-off-by: Markus Stockhausen <markus.stockhausen@gmx.de>
Link: https://github.com/openwrt/openwrt/pull/21274
Signed-off-by: Robert Marko <robimarko@gmail.com>
4 days agorealtek: mdio: relocate reset function
Markus Stockhausen [Wed, 24 Dec 2025 11:57:11 +0000 (12:57 +0100)] 
realtek: mdio: relocate reset function

Place the reset function into the config structure.

Signed-off-by: Markus Stockhausen <markus.stockhausen@gmx.de>
Link: https://github.com/openwrt/openwrt/pull/21274
Signed-off-by: Robert Marko <robimarko@gmail.com>
4 days agorealtek: mdio: give bus a family independent name
Markus Stockhausen [Wed, 24 Dec 2025 11:47:06 +0000 (12:47 +0100)] 
realtek: mdio: give bus a family independent name

There is no need to give the mdio bus a family dependent name.
Name the bus similar to the SerDes mdio bus.

Signed-off-by: Markus Stockhausen <markus.stockhausen@gmx.de>
Link: https://github.com/openwrt/openwrt/pull/21274
Signed-off-by: Robert Marko <robimarko@gmail.com>
4 days agorealtek: mdio: move read/write functions to config structure
Markus Stockhausen [Wed, 24 Dec 2025 11:32:34 +0000 (12:32 +0100)] 
realtek: mdio: move read/write functions to config structure

Move the read/write functions to where they belong.

Signed-off-by: Markus Stockhausen <markus.stockhausen@gmx.de>
Link: https://github.com/openwrt/openwrt/pull/21274
Signed-off-by: Robert Marko <robimarko@gmail.com>
4 days agorealtek: mdio: configure bus read/write only once.
Markus Stockhausen [Wed, 24 Dec 2025 11:19:02 +0000 (12:19 +0100)] 
realtek: mdio: configure bus read/write only once.

For all families the driver uses the same read/write functions.
Drop the duplicate per-family initialization.

Signed-off-by: Markus Stockhausen <markus.stockhausen@gmx.de>
Link: https://github.com/openwrt/openwrt/pull/21274
Signed-off-by: Robert Marko <robimarko@gmail.com>
4 days agorealtek: mdio: move cpu_port to configuration structure
Markus Stockhausen [Wed, 24 Dec 2025 10:54:33 +0000 (11:54 +0100)] 
realtek: mdio: move cpu_port to configuration structure

Relocate the cpu port definition over to the new configuration
structure. There are several family specific places where the
driver checks port ranges. These are a wild mix of arbitrary
values (64) or constant defines. Remove them as the the central
read/write functions already have a proper check with -ENODEV
bail out in place.

With the cleanup drop the port defines as there is only one
consumer (config structure) left.

Signed-off-by: Markus Stockhausen <markus.stockhausen@gmx.de>
Link: https://github.com/openwrt/openwrt/pull/21274
Signed-off-by: Robert Marko <robimarko@gmail.com>
4 days agorealtek: mdio: add per family configuration structure
Markus Stockhausen [Wed, 24 Dec 2025 10:34:43 +0000 (11:34 +0100)] 
realtek: mdio: add per family configuration structure

The mdio driver already has a family specific compatible that
is used in the dts to denote the device type. Nevertheless it
is not evaluated. The driver determines the family on its own
in rtmdio_get_family().

Break up this dependency by providing a configuration structure
that can be automatically assigned by device_get_match_data().
For now only move the rawpage variable over there.

Signed-off-by: Markus Stockhausen <markus.stockhausen@gmx.de>
Link: https://github.com/openwrt/openwrt/pull/21274
Signed-off-by: Robert Marko <robimarko@gmail.com>
4 days agorealtek: ethernet/dsa: Reduce mach include dependency 21263/head
Markus Stockhausen [Tue, 23 Dec 2025 21:35:49 +0000 (22:35 +0100)] 
realtek: ethernet/dsa: Reduce mach include dependency

The ethernet and dsa drivers still rely on several defines from
the central mach include. Move important defines over to the
driver specific includes as a first decoupling step.

Signed-off-by: Markus Stockhausen <markus.stockhausen@gmx.de>
Link: https://github.com/openwrt/openwrt/pull/21263
Signed-off-by: Robert Marko <robimarko@gmail.com>
5 days agoairoha: spi: update airoha-snfi patches and en7523 dts 21299/head
Mikhail Kshevetskiy [Sat, 27 Dec 2025 05:28:09 +0000 (08:28 +0300)] 
airoha: spi: update airoha-snfi patches and en7523 dts

Changes:
* use upstream patches for airoha-snfi driver
* update in kernel en7523 dts to add spinand support

Signed-off-by: Mikhail Kshevetskiy <mikhail.kshevetskiy@iopsys.eu>
Link: https://github.com/openwrt/openwrt/pull/21299
Signed-off-by: Robert Marko <robimarko@gmail.com>
5 days agoqualcommax: ipq60xx: enable dual-boot for 360v6 21154/head
Zhenyu Qi [Sat, 13 Dec 2025 21:04:51 +0000 (14:04 -0700)] 
qualcommax: ipq60xx: enable dual-boot for 360v6

Add dual-partition upgrade support for Qihoo 360v6 using the generic
bootconfig.sh library. This enables safe system upgrades with automatic
failover capability.

The device uses Qualcomm's bootconfig structure to control A/B partition
switching. The bootloader dynamically maps physical NAND partitions to
logical MTD devices based on the bootconfig, ensuring firmware always
writes to the inactive partition.

Implementation details:
- Use bootconfig.sh library (copied from ipq50xx) for bootconfig operations
- Operate on 'rootfs' partition by name instead of hardcoded offset
- Add magic header validation for safety
- Remove OEM UBI volumes (wifi_fw and ubi_rootfs) before sysupgrade
- Toggle bootconfig before removing OEM volumes

Hardware details:
- SoC: Qualcomm IPQ6000
- Flash: NAND with dual rootfs partitions (mtd16/mtd17)
- Bootconfig: controls slot selection via partition name lookup

Installation:
Standard sysupgrade process. After upgrade, the system will boot
from the new partition while preserving the old system as backup.

The OEM volume cleanup is necessary because these volumes are created
by the stock firmware and are not automatically cleaned by the standard
nand_upgrade_prepare_ubi() function, which only removes volumes named
'kernel', 'rootfs', and 'rootfs_data'. Without this cleanup, the remaining
OEM volumes consume available space, causing the creation of rootfs_data
to fail during sysupgrade.

Tested on Qihoo 360v6 running stock firmware and OpenWrt.

Signed-off-by: Zhenyu Qi <qzydustin@hotmail.com>
Link: https://github.com/openwrt/openwrt/pull/21154
Signed-off-by: Robert Marko <robimarko@gmail.com>
6 days agokernel: r8101: fix build with linux v6.16+ 21302/head
Álvaro Fernández Rojas [Sat, 27 Dec 2025 11:12:30 +0000 (12:12 +0100)] 
kernel: r8101: fix build with linux v6.16+

Fix r8101 module build with kernels >= v6.16.

Signed-off-by: Álvaro Fernández Rojas <noltari@gmail.com>
6 days agoath79: cf-ew71-v2: set label-mac-device to eth1
Florian Maurer [Tue, 16 Dec 2025 15:12:08 +0000 (16:12 +0100)] 
ath79: cf-ew71-v2: set label-mac-device to eth1

The EW71v2 has the WAN port configured at eth1.
The printed label-mac is configured on this iface in openwrt.

Signed-off-by: Florian Maurer <f.maurer@outlook.de>
6 days agowifi-scripts: fix race in wireless interface creation 21303/head
Nick Hainke [Sat, 27 Dec 2025 12:43:47 +0000 (13:43 +0100)] 
wifi-scripts: fix race in wireless interface creation

When wdev interfaces and hostapd interfaces are mixed, race conditions
can occur. Sometimes all interfaces are started correctly, sometimes only
the wdev interface and some of the hostapd interfaces, and sometimes only
the wdev interface.

Fix this by creating the wdev interfaces first, before processing
wpa_supplicant or hostapd interfaces.

Link: https://github.com/openwrt/openwrt/pull/21303
Signed-off-by: Nick Hainke <vincent@systemli.org>
6 days agorealtek: fix Linksys LGS328C dts memory definition 21262/head
Markus Stockhausen [Tue, 23 Dec 2025 20:29:46 +0000 (21:29 +0100)] 
realtek: fix Linksys LGS328C dts memory definition

RTL930x devices have highmem starting address at 0x20000000.
The Linksys LGS328C highmem definition is wrongly shared with
the larger LGS352C RTL931x model and starts at 0x90000000.
Fix it by splitting the definition.

Fixes: 853d73f ("realtek: add support for Linksys LGS328C")
Signed-off-by: Markus Stockhausen <markus.stockhausen@gmx.de>
Link: https://github.com/openwrt/openwrt/pull/21262
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
6 days agoRevert "qualcommax: ipq50xx: remove ipq5018 and qcn6122 wifi m3 fw"
Robert Marko [Sat, 27 Dec 2025 11:16:15 +0000 (12:16 +0100)] 
Revert "qualcommax: ipq50xx: remove ipq5018 and qcn6122 wifi m3 fw"

This reverts commit 423cda97f9e5152c6e9ad210d7a6b089d3664f28.

It appears that this broke remoteproc on some devices, so revert for now.

Signed-off-by: Robert Marko <robimarko@gmail.com>
6 days agowifi-scripts: fix mcast_rate type (number, not array) 21291/head
Nick Hainke [Fri, 26 Dec 2025 17:35:01 +0000 (18:35 +0100)] 
wifi-scripts: fix mcast_rate type (number, not array)

The multicast rate (mcast_rate) is defined as a single numeric value,
not an array. The ucode scripts already expect a single number, and
the OpenWrt documentation specifies this option as an integer [0].

Adjust the wireless schema accordingly. This also fixes the wdev.uc
call path for the iw fallback mesh setup.

[0] - https://openwrt.org/docs/guide-user/network/wifi/basic

Link: https://github.com/openwrt/openwrt/pull/21291
Signed-off-by: Nick Hainke <vincent@systemli.org>
6 days agowifi-scripts: fix wdev fallback for mesh interfaces
Nick Hainke [Thu, 25 Dec 2025 17:41:10 +0000 (18:41 +0100)] 
wifi-scripts: fix wdev fallback for mesh interfaces

The previous wdev.uc invocation failed for mesh interfaces.
Rewrite it as a loop so the mesh interface is created correctly
when no wpa_supplicant mesh support is installed.

Link: https://github.com/openwrt/openwrt/pull/21291
Signed-off-by: Nick Hainke <vincent@systemli.org>
7 days agomediatek: add support for Elecom WRC-G01 21238/head
Yuhei Amemiya [Sun, 21 Dec 2025 07:03:20 +0000 (15:03 +0800)] 
mediatek: add support for Elecom WRC-G01

Hardware is identical to WRC-X3200GST3.
- SoC: MediaTek MT7622
- RAM: 512MB
- Flash: 128MB SPI-NAND

The -W suffix in the retail name (WRC-G01-W) denotes the casing color
and is omitted from the model name in the OpenWrt configuration to
maintain consistency with other Elecom devices.

Signed-off-by: Yuhei Amemiya <minihui@me.com>
Link: https://github.com/openwrt/openwrt/pull/21238
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
7 days agobase-files: fix default_postinst clearing luci cache 21280/head
Liangbin Lian [Thu, 25 Dec 2025 05:50:14 +0000 (13:50 +0800)] 
base-files: fix default_postinst clearing luci cache

The path to the LuCI index cache file has changed to
/tmp/luci-indexcache.*.json since OpenWrt 22.03.

Update functions.sh to align with luci.mk.

Signed-off-by: Liangbin Lian <jjm2473@gmail.com>
Link: https://github.com/openwrt/openwrt/pull/21280
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
7 days agomediatek: add kmod-usb3 to default package set of WR3000P 21281/head 21296/head
Dmitry Mostovoy [Thu, 25 Dec 2025 08:18:57 +0000 (11:18 +0300)] 
mediatek: add kmod-usb3 to default package set of WR3000P

Include XHCI USB drivers on the Cudy WR3000P v1 router, the drivers are
required to be able to use the USB port for USD devices.

Closes: https://github.com/openwrt/openwrt/issues/21231
Fixes: 04e9d154f209 ("mediatek: filogic: add support for Cudy WR3000P v1")
Signed-off-by: Dmitry Mostovoy <dmitry.mostovoy@ceifx.com>
Link: https://github.com/openwrt/openwrt/pull/21281
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
7 days agoath79: Fix syntax error in 10_fix_wifi_mac 21287/head
Nick French [Thu, 25 Dec 2025 15:53:37 +0000 (09:53 -0600)] 
ath79: Fix syntax error in 10_fix_wifi_mac

This typo makes the script fail with:
-ash: /etc/hotplug.d/ieee80211/10_fix_wifi_mac: line 66: syntax error: unexpected word (expecting ")")

which ultimately prevents the mac address for certain devices wireless cards being set correctly

Signed-off-by: Nick French <nickfrench@gmail.com>
Link: https://github.com/openwrt/openwrt/pull/21287
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
7 days agoqualcommax: ipq50xx: remove cpufreq scaling 21185/head
Robert Senderek [Tue, 16 Dec 2025 13:49:40 +0000 (14:49 +0100)] 
qualcommax: ipq50xx: remove cpufreq scaling

ipq5018 do not support freq scaling and therefore stuck on 800Mhz
This patch allows CPU to run with 1.008 Ghz as designed

Signed-off-by: Robert Senderek <robert.senderek@10g.pl>
Link: https://github.com/openwrt/openwrt/pull/21185
Signed-off-by: Robert Marko <robimarko@gmail.com>
8 days agowifi-scripts: ucode: fix wpa_supplicant mesh 21293/head
Nick Hainke [Thu, 25 Dec 2025 19:32:28 +0000 (20:32 +0100)] 
wifi-scripts: ucode: fix wpa_supplicant mesh

Mesh interfaces may not define an encryption setting. This results in
a ucode runtime error when parse_encryption() is called:
  Reference error: left-hand side expression is null
  In parse_encryption(), file /usr/share/ucode/wifi/iface.uc, line 20, byte 32:
    called from function setup_sta (/usr/share/ucode/wifi/supplicant.uc:59:31)
    called from function generate (/usr/share/ucode/wifi/supplicant.uc:243:41)
    called from function setup (./mac80211.sh:254:61)
    called from anonymous function (./mac80211.sh:342:14)
   `    config.auth_type = encryption[0] ?? 'none';`
    Near here ------------------------^

Link: https://github.com/openwrt/openwrt/pull/21293
Signed-off-by: Nick Hainke <vincent@systemli.org>
8 days agowifi-scripts: add missing 802.11be type in hwmodelist 21267/head
Elwin Huang [Wed, 24 Dec 2025 06:01:32 +0000 (14:01 +0800)] 
wifi-scripts: add missing 802.11be type in hwmodelist

Add EHT* check so that the hwmode will display 802.11be capability correctly.

Signed-off-by: Elwin Huang <s09289728096@gmail.com>
Link: https://github.com/openwrt/openwrt/pull/21267
Signed-off-by: Nick Hainke <vincent@systemli.org>
8 days agowifi-scripts: fix macaddr check in mac80211.uc
Harin Lee [Wed, 24 Dec 2025 19:15:25 +0000 (04:15 +0900)] 
wifi-scripts: fix macaddr check in mac80211.uc

This fixes a simple logic error in the macaddr existence check in mac80211.uc.

Signed-off-by: Harin Lee <me@harin.net>
Link: https://github.com/openwrt/openwrt/pull/21277
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
8 days agoipq-wifi: update to Git HEAD (2025-12-25)
Robert Marko [Thu, 25 Dec 2025 11:43:16 +0000 (12:43 +0100)] 
ipq-wifi: update to Git HEAD (2025-12-25)

ed56ad0 qcn6122: Add BDF for Linksys MX6200
1f83ec8 ipq5018: Add BDF for Linksys MX6200

Signed-off-by: Robert Marko <robimarko@gmail.com>
9 days agoqualcommax: ipq50xx: fix reo2host-status interrupt vector 21271/head
George Moussalem [Fri, 19 Dec 2025 07:18:04 +0000 (11:18 +0400)] 
qualcommax: ipq50xx: fix reo2host-status interrupt vector

Interrupt vector for reo2host-status is wrongly assigned.
Status interrupts weren't received and a workaround was applied to
mac80211 to periodically poll the reo status ring. Therefore, the
workaround can be removed with the proper hardware interrupt line
assigned.

Signed-off-by: George Moussalem <george.moussalem@outlook.com>
Link: https://github.com/openwrt/openwrt/pull/21271
Signed-off-by: Robert Marko <robimarko@gmail.com>
9 days agomicrochipsw: sync with DTS sent upstream
Robert Marko [Tue, 23 Dec 2025 13:08:26 +0000 (14:08 +0100)] 
microchipsw: sync with DTS sent upstream

Sync the DTS with the version sent upstream, clock bindings also.

Signed-off-by: Robert Marko <robert.marko@sartura.hr>
9 days agoqualcommax: ipq50xx: add support for Linksys MX6200 21038/head
George Moussalem [Mon, 2 Jun 2025 11:21:36 +0000 (15:21 +0400)] 
qualcommax: ipq50xx: add support for Linksys MX6200

Linksys MX6200 is a triband Wi-Fi 6E wireless router.

Speficiations:
* SoC: Qualcomm IPQ5018 (64-bit dual-core ARM Cortex-A53 @ 1.0Ghz)
* Memory: Nanya NT5CC256M16ER-EK (512 MiB DDR3-933)
* Serial Port: 3v3 TTL 115200n8
* Wi-Fi: IPQ5018 (2x2 2.4 Ghz 802.11b/g/n/ax)
 QCN6102 (2x2:2 5 Ghz 802.11an/ac/ax)
 QCN6122 (2x2:2 6 Ghz 802.11an/ac/ax)
* Ethernet: IPQ5018 integrated virtual switch connected to:
    - LAN Port: Internal IPQ5018 GE PHY
    - WAN Port: Maxlinear Ethernet GPY115C PHY
* Flash: Macronix MX35UF2GE4AD (256 MiB)
* LEDs: 1x multi-color PWM LED
* Buttons: 1x WPS (GPIO 27 Active Low)
           1x Reset (GPIO 28 Acive Low)
* FCC ID: 2AYRA-08436

Flash instructions:
************************************************************************
NOTE: serial access is required! Although the web UI allows you to
install the Openwrt image, secure boot is enabled which will prevent
booting an unsigned image. The boot sequence must be adjusted in U-boot
to allow booting unsigned images.
************************************************************************

1. On OEM firmware, login to the web UI (typically @ http://192.168.1.1)
and click 'CA' in the bottom right corner.
Then click -> Connectivity -> Manual Upgrade.
Alternatively, browse to
http://<router IP>/fwupdate.html.
Upload openwrt-qualcommax-ipq50xx-linksys_mx6200-squashfs-factory.ubi.
Continue with step 5.
2. Installation on alternate partition using serial connection from OEM
firmware (default login: root, password: admin):
flash_erase /dev/mtd19 0 0
nandwrite -p /dev/mtd19 openwrt-qualcommax-ipq50xx-linksys_mx6200-squashfs-factory.ubi
reboot
Continue with step 5.
3. Installation using serial connection from initramfs
setup tftp server listening on IP in 192.168.1.0/24 (other than the
router IP 192.168.1.1). In U-boot, load the initramfs image to memory:
tftp $loadaddr <your IP>:openwrt-qualcommax-ipq50xx-linksys_mx6200-initramfs-uImage.itb
boot the image using command:
bootm $loadaddr
when fully booted, scp the sysupgrade image to your router IP (default:
192.168.1.1):
scp -O <path>/openwrt-qualcommax-ipq50xx-linksys_mx6200-squashfs-sysypgrade.bin root@192.168.1.1:/tmp/
use sysupgrade to flash the image to nand:
sysupgrade -n -v /tmp/openwrt-qualcommax-ipq50xx-linksys_mx6200-squashfs-sysupgrade.bin
Continue with step 5.
4. Optionally install on alternate partition. From Openwrt:
mtd -r -e rootfs_1 -n write openwrt-qualcommax-ipq50xx-linksys_mx6200-squashfs-factory.ubi rootfs_1
Continue with step 5.
5. Setup U-boot for ability to dual boot signed (stock) and non-signed
(Openwrt) images with auto-detection.
From U-boot, run (be aware: copy line by line):
setenv setnandbootargs 'setenv bootargs init=/sbin/init ubi.mtd=rootfs rootfstype=squashfs rootwait'
setenv nandinitcmd 'setenv mtdids nand0=nand0; run setrootfscmd; ubi part rootfs 2048'
setenv setrootfscmd 'if test $boot_part = 1; then setenv mtdparts mtdparts=nand0:0x${imgsize}@0x${prikern}(rootfs); else setenv mtdparts mtdparts=nand0:0x${imgsize}@0x${altkern}(rootfs); fi'
setenv readhdr1cmd 'ubi read $loadaddr kernel 0x40; setexpr IMGOFF $loadaddr + 0x10; setexpr CODEOFF $loadaddr + 0x14; setexpr SIGOFF $loadaddr + 0x1c; setexpr CERTOFF $loadaddr + 0x24'
setenv readhdr2cmd 'setexpr.l HDR *$loadaddr; setexpr.l IMGSZ *$IMGOFF; setexpr.l CODESZ *$CODEOFF; setexpr.l SIGSZ *$SIGOFF; setexpr.l CERTSZ *$CERTOFF; setexpr TSIZE $CODESZ + $SIGSZ; setexpr TSIZE $TSIZE + $CERTSZ'
setenv testmbncmd 'if test $HDR -ne edfe0dd0 -a $IMGSZ -eq $TSIZE; then bootipq; else ubi read $loadaddr kernel $kernsize; run setnandbootargs; bootm $loadaddr; fi'
setenv bootcmd2 'if test $auto_recovery = no; then bootipq; else run nandinitcmd; run readhdr1cmd; run readhdr2cmd; run testmbncmd; fi'
setenv bootcmd 'run bootcmd2'
saveenv
6. Back to the OEM firmware.
Download firmware from OEM website:
MX6200: https://support.linksys.com/kb/article/408-en/
From serial/SSH, in Openwrt, flash OEM firmware to alternate partition:
mtd -r -e rootfs_1 -n write FW_MX6200_1.0.11.216041_prod.signed.img rootfs_1

Switching active partition:
1. From U-boot, executive the following to switch to partition 1:
setenv boot_part 1
for partition 2:
setenv boot_part 2
2. From Openwrt:
fw_printenv boot_part
In case it's 1:
fw_setenv boot_part 2
. /lib/upgrade/platform.sh
linksys_bootconfig_set_primaryboot "0:bootconfig" 1
linksys_bootconfig_set_primaryboot "0:bootconfig1" 1
In case it's 2:
fw_setenv boot_part 1
. /lib/upgrade/platform.sh
linksys_bootconfig_set_primaryboot "0:bootconfig" 0
linksys_bootconfig_set_primaryboot "0:bootconfig1" 0
and
reboot

Signed-off-by: George Moussalem <george.moussalem@outlook.com>
Link: https://github.com/openwrt/openwrt/pull/21038
Signed-off-by: Robert Marko <robimarko@gmail.com>
9 days agoqualcommax: ipq50xx: upgrade SMEM dualboot Linksys devices
George Moussalem [Thu, 4 Dec 2025 05:20:00 +0000 (09:20 +0400)] 
qualcommax: ipq50xx: upgrade SMEM dualboot Linksys devices

Add support for upgrades on dual firmware Linksys devices with the
partition table stored in SMEM and that store both the kernel and rootfs
in a single partition. Switching the active boot partition requires
updating the partition info table in SMEM in addition to setting
the active boot partition in a U-boot variable as U-boot will keep them
in sync upon reboot if they're not.

U-boot always sets the name of the active partition to rootfs and that
of the inactive partition to rootfs_1 in SMEM. when Linux loads the
partition table from SMEM it will load the right partition based on the
offset set in the SMEM partition table. For upgrades, flashing to the
alternate partition will always be to rootfs_1, while flashing the
current partition will be on rootfs.

Signed-off-by: George Moussalem <george.moussalem@outlook.com>
Link: https://github.com/openwrt/openwrt/pull/21038
Signed-off-by: Robert Marko <robimarko@gmail.com>
9 days agoqualcommax: ipq50xx: functions for bootconfig partition
George Moussalem [Wed, 3 Dec 2025 19:22:09 +0000 (23:22 +0400)] 
qualcommax: ipq50xx: functions for bootconfig partition

The BOOTCONFIG partition is used by Qualcomm's boot chain to store
metadata about the device's startup configuration. It contains info such
as versioning, configuration flags, primary boot partition, and more.

Newer devices with dual boot partitions not only store the active boot
partition in a U-boot variable but also in partition info in the
BOOTCONFIG partition. As such, add library functions to set and toggle
the active boot partition.

Signed-off-by: George Moussalem <george.moussalem@outlook.com>
Link: https://github.com/openwrt/openwrt/pull/21038
Signed-off-by: Robert Marko <robimarko@gmail.com>
9 days agoqualcommax: ipq50xx: move bootargs to Linksys board files
George Moussalem [Tue, 9 Dec 2025 11:12:32 +0000 (15:12 +0400)] 
qualcommax: ipq50xx: move bootargs to Linksys board files

Move setting kernel bootargs from the base template down to the
respective Linksys board files. This allows for having devices which
require different bootargs use the base template device tree file.

Signed-off-by: George Moussalem <george.moussalem@outlook.com>
Link: https://github.com/openwrt/openwrt/pull/21038
Signed-off-by: Robert Marko <robimarko@gmail.com>
9 days agoqualcommax: ipq50xx: load Linksys partition tables from SMEM
George Moussalem [Tue, 9 Dec 2025 11:04:56 +0000 (15:04 +0400)] 
qualcommax: ipq50xx: load Linksys partition tables from SMEM

The partition table on Linksys devices with a Qualcomm AX IPQ SoC is
stored in SMEM. As such, load partition table from SMEM rather than
statically defining them in their respective device trees. This helps
generalize the base template and requires less maintenance.

Signed-off-by: George Moussalem <george.moussalem@outlook.com>
Link: https://github.com/openwrt/openwrt/pull/21038
Signed-off-by: Robert Marko <robimarko@gmail.com>
9 days agoqualcommax: ipq50xx: remove ipq5018 and qcn6122 wifi m3 fw 21110/head
George Moussalem [Tue, 9 Dec 2025 11:47:06 +0000 (15:47 +0400)] 
qualcommax: ipq50xx: remove ipq5018 and qcn6122 wifi m3 fw

The current ath11k driver does not support loading m3 firmware for
IPQ5018 and QCN6122 wifi. Although m3 firmware entries are specified
in Q6 WCSS nodes, the driver actually skips loading them. Editing the
driver to force loading m3 results in Q6 crashes and non-functioning
wifi. As such, remove m3 firmware entries for all boards until there's
proper support in the ath11k driver.

Signed-off-by: George Moussalem <george.moussalem@outlook.com>
Link: https://github.com/openwrt/openwrt/pull/21110
Signed-off-by: Robert Marko <robimarko@gmail.com>
9 days agotoolchain: fix libgcc ABI for libc 21265/head
George Sapkin [Wed, 24 Dec 2025 02:32:01 +0000 (04:32 +0200)] 
toolchain: fix libgcc ABI for libc

libc depends on knowing libgcc's ABI, so it needs to be evaluated first.
Otherwise libc will depend on an ABI-less libgcc causing the rest of the
toolchain to fail.

Building package index...
ERROR: unable to select packages:
  libgcc (virtual):
    note: please select one of the 'provided by'
          packages explicitly
    provided by: libgcc1
    required by: world[libgcc]

Before:

libc fused dependencies: libgcc
libgcc fused dependencies:
libatomic fused dependencies: libgcc1

After:

libgcc fused dependencies:
libc fused dependencies: libgcc1
libatomic fused dependencies: libgcc1

Signed-off-by: George Sapkin <george@sapk.in>
Link: https://github.com/openwrt/openwrt/pull/21265
Signed-off-by: Robert Marko <robimarko@gmail.com>
9 days agobuild: fix missing PKG_INFO_DIR
George Sapkin [Wed, 24 Dec 2025 02:28:49 +0000 (04:28 +0200)] 
build: fix missing PKG_INFO_DIR

If the first built package has an ABI, PKG_INFO_DIR might not exist, so
ensure it does.

Signed-off-by: George Sapkin <george@sapk.in>
Link: https://github.com/openwrt/openwrt/pull/21265
Signed-off-by: Robert Marko <robimarko@gmail.com>
10 days agorealtek: pcs: rtl931x: add helper for SerDes power up/down 21184/head
Jonas Jelonek [Mon, 15 Dec 2025 19:41:16 +0000 (19:41 +0000)] 
realtek: pcs: rtl931x: add helper for SerDes power up/down

Add a dedicated helper 'rtpcs_931x_sds_power' to power down/up a SerDes.
Up to now, plain register writes to the corresponding register were used
in several places and with slightly different syntax. Use the helper to
replace the existing boilerplate code for powering on/off SerDes.

Signed-off-by: Jonas Jelonek <jelonek.jonas@gmail.com>
Link: https://github.com/openwrt/openwrt/pull/21184
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
10 days agorealtek: pcs: rtl931x: separate and reuse 1000base-x config
Jonas Jelonek [Sun, 14 Dec 2025 11:54:15 +0000 (11:54 +0000)] 
realtek: pcs: rtl931x: separate and reuse 1000base-x config

Move the configuration of 1000Base-X mode into its own function. This
way, redundant code can be replaced by a single function call.

Signed-off-by: Jonas Jelonek <jelonek.jonas@gmail.com>
Link: https://github.com/openwrt/openwrt/pull/21184
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
10 days agorealtek: pcs: rtl931x: reorder modes in mode configuration
Jonas Jelonek [Mon, 15 Dec 2025 18:45:54 +0000 (18:45 +0000)] 
realtek: pcs: rtl931x: reorder modes in mode configuration

Reorder the modes within the switch statement in
rtpcs_931x_sds_config_mode to have a proper and non-confusing order.
Have fiber modes first and MII modes after, and sort all modes in
ascending speed/capabilities order.

Signed-off-by: Jonas Jelonek <jelonek.jonas@gmail.com>
Link: https://github.com/openwrt/openwrt/pull/21184
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
10 days agorealtek: pcs: rtl931x: use hardware mode for configuration
Jonas Jelonek [Mon, 15 Dec 2025 17:44:00 +0000 (17:44 +0000)] 
realtek: pcs: rtl931x: use hardware mode for configuration

Pass the SerDes hardware mode to rtpcs_931x_sds_config_mode instead of
the PHY_INTERFACE_MODE_* mode and use it. Replace matched modes
accordingly.

Signed-off-by: Jonas Jelonek <jelonek.jonas@gmail.com>
Link: https://github.com/openwrt/openwrt/pull/21184
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
10 days agorealtek: pcs: rtl931x: map interface mode to hardware mode
Jonas Jelonek [Mon, 15 Dec 2025 17:37:01 +0000 (17:37 +0000)] 
realtek: pcs: rtl931x: map interface mode to hardware mode

The PCS driver is intended to use a dedicated hardware mode in the
future because the hardware capabilities and modes of the SerDes do not
align with the PHY_INTERFACE_MODE_* modes.

For the beginning, use the previously introduced generic mode mapping
in the SerDes setup and assign the determined hardware mode to the
corresponding field of a SerDes instance. This allows parallel usage of
both mode representations for the time being, until the phy_interface_t
modes can be dropped from internal functions completely.

Signed-off-by: Jonas Jelonek <jelonek.jonas@gmail.com>
Link: https://github.com/openwrt/openwrt/pull/21184
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
10 days agorealtek: pcs: rtl931x: move SerDes config out of setup
Jonas Jelonek [Sun, 14 Dec 2025 11:34:34 +0000 (11:34 +0000)] 
realtek: pcs: rtl931x: move SerDes config out of setup

Slim the rtpcs_931x_setup_serdes entrypoint by moving the SerDes
configuration sequences for the different SerDes modes into a dedicated
function called rtpcs_931x_sds_config_mode. They form a logical block
similar to what the SDK does and can be taken out to follow the
'divide & conquer' principle.

Signed-off-by: Jonas Jelonek <jelonek.jonas@gmail.com>
Link: https://github.com/openwrt/openwrt/pull/21184
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
10 days agorealtek: pcs: rtl931x: don't return error on USXGMII setup
Jonas Jelonek [Tue, 11 Nov 2025 09:55:42 +0000 (09:55 +0000)] 
realtek: pcs: rtl931x: don't return error on USXGMII setup

Configuring USXGMII on RTL931X was disable because it is not setup
properly right now. Affected devices need to rely on U-boot setup for
now. However, it is not the proper way to return an error in case we
just want to skip USXGMII configuration. Thus, just return 0 in that
case indicating it is properly configured.

Signed-off-by: Jonas Jelonek <jelonek.jonas@gmail.com>
Link: https://github.com/openwrt/openwrt/pull/21184
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
10 days agorealtek: pcs: add mapping for SerDes hardware mode
Jonas Jelonek [Fri, 19 Dec 2025 10:11:06 +0000 (10:11 +0000)] 
realtek: pcs: add mapping for SerDes hardware mode

Add a generic mapper for mapping the PHY_INTERFACE_MODE_* modes to the
SerDes hardware modes RTPCS_SDS_MODE_*. This is to be used by all
subtargets step-by-step and avoids having subtarget-specific code for
that simple mapping.

Signed-off-by: Jonas Jelonek <jelonek.jonas@gmail.com>
Link: https://github.com/openwrt/openwrt/pull/21184
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
10 days agorealtek: pcs: rename SerDes mode field
Jonas Jelonek [Wed, 17 Dec 2025 21:33:17 +0000 (21:33 +0000)] 
realtek: pcs: rename SerDes mode field

Rename the mode field in rtpcs_serdes from 'mode' to 'hw_mode' to make
clear what it actually is, to avoid confusion with the phy_interface_t
'mode' usually passed to functions.

Signed-off-by: Jonas Jelonek <jelonek.jonas@gmail.com>
Link: https://github.com/openwrt/openwrt/pull/21184
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
10 days agotreewide: dts: update rtl836x switch sck/sda gpio properties 21143/head
Shiji Yang [Fri, 12 Dec 2025 13:43:39 +0000 (21:43 +0800)] 
treewide: dts: update rtl836x switch sck/sda gpio properties

Rename them to follow the rtl836x driver gpiod changes.

Signed-off-by: Shiji Yang <yangshiji66@outlook.com>
Link: https://github.com/openwrt/openwrt/pull/21143
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
10 days agokernel: rtl836x: convert to gpiod API
Shiji Yang [Fri, 12 Dec 2025 13:39:40 +0000 (21:39 +0800)] 
kernel: rtl836x: convert to gpiod API

This is the recommended way for the OF based platform.

Tested-on TP-Link TL-WR2543N with RTL8367 switch:
```
root@OpenWrt:~# dmesg |grep -i rtl
[    7.941126] rtl8367 rtl8367: cannot find mdio node phandle
[    7.947562] rtl8367 rtl8367: RTL8367R ver. 0 chip found
[    9.056830] rtl8367 rtl8367: cpu_port:9, assigned to extif0
root@OpenWrt:~# cat /sys/kernel/debug/gpio
gpiochip0: GPIOs 512-529, parent: platform/18040000.gpio, 18040000.gpio:
 gpio-512 (                    |lime:status         ) out lo ACTIVE LOW
 gpio-513 (                    |rtl836x-sda         ) in  hi
 gpio-518 (                    |rtl836x-sck         ) in  lo
 gpio-520 (                    |lime:usb            ) out hi ACTIVE LOW
 gpio-523 (                    |reset               ) in  hi IRQ ACTIVE LOW
 gpio-524 (                    |wps                 ) in  hi IRQ ACTIVE LOW
```

Signed-off-by: Shiji Yang <yangshiji66@outlook.com>
Link: https://github.com/openwrt/openwrt/pull/21143
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
10 days agokernel: rtl836x: change missing mdio node log level to info
Shiji Yang [Fri, 12 Dec 2025 16:40:41 +0000 (00:40 +0800)] 
kernel: rtl836x: change missing mdio node log level to info

mdio node is optional for the rtl836x switch. Some devices use GPIO to
control the switch chip. Missing mdio is a normal behavior.

Signed-off-by: Shiji Yang <yangshiji66@outlook.com>
Link: https://github.com/openwrt/openwrt/pull/21143
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
10 days agokernel: rtl836x: directly defer probe when mdio is missing
Shiji Yang [Mon, 15 Dec 2025 11:37:03 +0000 (19:37 +0800)] 
kernel: rtl836x: directly defer probe when mdio is missing

If the switch is directly controlled by the mdio bus, we must ensure
that the mdio bus is ready instead of trying GPIO simulated bus.

Fixes: d4ac26ec4920 ("kernel: rtl8366-smi: add Realtek switch management via mii-bus")
Signed-off-by: Shiji Yang <yangshiji66@outlook.com>
Link: https://github.com/openwrt/openwrt/pull/21143
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
10 days agocryptodev-linux: add backport to build for 6.18 21190/head
John Audia [Tue, 16 Dec 2025 21:42:12 +0000 (16:42 -0500)] 
cryptodev-linux: add backport to build for 6.18

Add https://github.com/cryptodev-linux/cryptodev-linux/commit/08644db02d43478f802755903212f5ee506af73b
to allow builds against the 6.18 series of kernels.

Signed-off-by: John Audia <therealgraysky@proton.me>
Link: https://github.com/openwrt/openwrt/pull/21190
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
10 days agostrace: update to 6.18 21206/head
John Audia [Wed, 17 Dec 2025 20:46:11 +0000 (15:46 -0500)] 
strace: update to 6.18

Release Notes:
- https://github.com/strace/strace/releases/tag/v6.18

Note this updated is needed in order to fix a build failure with
the 6.18 kernel.

Signed-off-by: John Audia <therealgraysky@proton.me>
Link: https://github.com/openwrt/openwrt/pull/21206
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
10 days agorealtek: ethernet: decouple from soc_info 21183/head
Markus Stockhausen [Tue, 16 Dec 2025 10:29:04 +0000 (11:29 +0100)] 
realtek: ethernet: decouple from soc_info

The ethernet driver gets all the data from the DTS now. No need
to access the shared soc_info structure any longer.

Signed-off-by: Markus Stockhausen <markus.stockhausen@gmx.de>
Link: https://github.com/openwrt/openwrt/pull/21183
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
10 days agorealtek: ethernet: switch to new family_id location
Markus Stockhausen [Tue, 16 Dec 2025 10:23:58 +0000 (11:23 +0100)] 
realtek: ethernet: switch to new family_id location

family_id is now part of the register set and automatically assigned
during initialization. Make use of it. This is basically a conversion
from priv->family_id to priv->r->family_id.

While we are here convert some hard coded family ids to their proper
defines.

Signed-off-by: Markus Stockhausen <markus.stockhausen@gmx.de>
Link: https://github.com/openwrt/openwrt/pull/21183
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
10 days agorealtek: ethernet: switch to device_get_match_data()
Markus Stockhausen [Tue, 16 Dec 2025 10:19:52 +0000 (11:19 +0100)] 
realtek: ethernet: switch to device_get_match_data()

Now that the register configuration contains the family data derive it
from the DTS via device_get_match_data().

Signed-off-by: Markus Stockhausen <markus.stockhausen@gmx.de>
Link: https://github.com/openwrt/openwrt/pull/21183
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
10 days agorealtek: ethernet: provide soc family in register config
Markus Stockhausen [Tue, 16 Dec 2025 09:58:22 +0000 (10:58 +0100)] 
realtek: ethernet: provide soc family in register config

The ethernet driver currently determines the family from the soc_info
structure. To avoid the dependency add the family to the local register
structure.

Signed-off-by: Markus Stockhausen <markus.stockhausen@gmx.de>
Link: https://github.com/openwrt/openwrt/pull/21183
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
10 days agorealtek: ethernet: relocate ethernet below switchcore in DTS
Markus Stockhausen [Tue, 16 Dec 2025 09:03:03 +0000 (10:03 +0100)] 
realtek: ethernet: relocate ethernet below switchcore in DTS

The ethernet driver uses registers in the switchcore range.
Rearrange the DTS nodes accordingly. This allows to make use
of regmap with syscon_node_to_regmap(np->parent) later.

Signed-off-by: Markus Stockhausen <markus.stockhausen@gmx.de>
Link: https://github.com/openwrt/openwrt/pull/21183
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
10 days agorealtek: ethernet: drop devm_request_mem_region()
Markus Stockhausen [Tue, 16 Dec 2025 12:28:56 +0000 (13:28 +0100)] 
realtek: ethernet: drop devm_request_mem_region()

The ethernet driver currently "requests" the memory region of the
ethernet device according to the DTS settings. This is wrong in
two ways:

- The DTS uses arbitrary regions out of the switchcore memory
- The variable is afterwards overwritten by DMA allocation

Drop it.

Signed-off-by: Markus Stockhausen <markus.stockhausen@gmx.de>
Link: https://github.com/openwrt/openwrt/pull/21183
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
10 days agorealtek: ethernet: split ethernet compatibles
Markus Stockhausen [Tue, 16 Dec 2025 08:41:37 +0000 (09:41 +0100)] 
realtek: ethernet: split ethernet compatibles

The Realtek Otto ethernet driver currently uses a single compatible
for all different models. Split this into the the four well known
subtargets. This allows to get rid of the central mach/soc include
later.

Signed-off-by: Markus Stockhausen <markus.stockhausen@gmx.de>
Link: https://github.com/openwrt/openwrt/pull/21183
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
10 days agorealtek: phy: reorganize package handling 21204/head
Markus Stockhausen [Wed, 17 Dec 2025 19:07:36 +0000 (20:07 +0100)] 
realtek: phy: reorganize package handling

With kernel 6.18 the package shared structure will be hidden from
the phy drivers. Workaround that in advance by providing a shared
private structure that covers all information that is needed for
normal operation.

For further simplification provide a new join() function that takes
care of a consistent initialization.

Signed-off-by: Markus Stockhausen <markus.stockhausen@gmx.de>
Link: https://github.com/openwrt/openwrt/pull/21204
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
10 days agomediatek: filogic: asus,rt-ax57m: remove unused pinctrl groups
Daniel Golle [Tue, 23 Dec 2025 14:49:48 +0000 (14:49 +0000)] 
mediatek: filogic: asus,rt-ax57m: remove unused pinctrl groups

Remove unused pinctrl groups defined in the device tree, probably as a
result of importing the vendor device tree which is based on the
reference board from MediaTek's SDK.

114b5c2063 ("mediatek: filogic: Add support ASUS RT-AX57M")
Signed-off-by: Daniel Golle <daniel@makrotopia.org>
10 days agomediatek: filogic: Add support ASUS RT-AX57M 20491/head
Garrett Mesmer [Tue, 8 Jul 2025 09:50:14 +0000 (12:50 +0300)] 
mediatek: filogic: Add support ASUS RT-AX57M

ASUS RT-AX57M, RT-AX54HP V2, RT-AX1800HP V2, RT-AX1800S V2, and RT-AX3000S all use the same firmware and have identical hardware

Hardware
--------
SOC: MediaTek MT7981b
RAM: 256MB DDR3L (Winbond W632GU6NB-09)
FLASH: 128MB SPI-NAND (Winbond W25N01KVZEIR)
WIFI: Mediatek MT7981b + Mediatek MT7976DAN 802.11ax 2.4/5 GHz
ETH: MediaTek MT7531AE Switch
UART: 3V3 115200 8N1 (Pinout silkscreened / Do not connect VCC)

MAC addresses
-------------
LAN Label MAC (stored in mtd ubi Factory partition at offset 0x4)
WAN LAN
2.4G LAN + 2 in first octet
5G LAN

Installation
-----------------------------------------------------------
Vendor-UI Method
-----------------------------------------------------------
1. Download the OpenWrt initramfs.trx image.

2. Connect the PC via LAN to one of the yellow router ports and wait
   until your PC to get a DHCP lease.

3. Browse to http://192.168.1.1 (or whatever your router IP is configured as)

4. If your router is brand new, finish the setup process and log into
   the Web-UI.

5. Navigate to Administration -> Firmware Upgrade and upload the
   downloaded OpenWrt initramfs.trx image.

6. Wait for OpenWrt to boot. Open the default OpenWrt IP in a web browser and perform a system upgrade using the sysupgrade image as instructed in the top banner.

---------------------------------------------------------------------------
Revert to stock firmware:
1: Install package facinstall -> https://forum.openwrt.org/t/facinstall-package-for-easy-installation-factory-images/177587
2. Install Asus stock trx image via OpenWRT LuCI interface.

Signed-off-by: Garrett Mesmer <garrettmesm@gmail.com>
Co-authored-by: Oleg S <remittor@gmail.com>
Signed-off-by: Oleg S <remittor@gmail.com>
Link: https://github.com/openwrt/openwrt/pull/20491
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
11 days agorealtek: image: add rt-loader-no-uimage recipe 21248/head
Jonas Jelonek [Mon, 22 Dec 2025 09:57:52 +0000 (09:57 +0000)] 
realtek: image: add rt-loader-no-uimage recipe

Add a new recipe 'rt-loader-no-uimage' that passes the kernel load
address to rt-loader, causing it to use that instead of it's initial run
address.

The usual behavior is fine for uImages where the load address is
predefined in the header, U-boot loads the image to that address and
then runs it, rt-loader just takes over that address. For non-uImage
instead, the address is tightly coupled to where the image has been
transferred during serial or TFTP upload. This may not be possible on
several devices. Passing a separate kernel load address to rt-loader
decouples that and avoids taking the pain to change the load address of
the kernel itself.

Signed-off-by: Jonas Jelonek <jelonek.jonas@gmail.com>
Link: https://github.com/openwrt/openwrt/pull/21248
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>