Commit graph

67681 commits

Author SHA1 Message Date
Robert Marko
fd76f6f08f generic: add CONFIG_REGULATOR_QCOM_USB_VBUS
CONFIG_REGULATOR_QCOM_USB_VBUS showed up on Layerscape recently, and it
looks like multiple targets disable it manually, so simply disable it in
generic configuration instead.

Signed-off-by: Robert Marko <robimarko@gmail.com>
2026-02-27 11:13:03 +01:00
Tim Harvey
eef354ff34 imx: cortexa53: enable DMA contiguous memory allocator
Enable and configure DMA contiguous memory allocator. Without this
CMA itself will be disabled.

Fixes: ae8bf1a26e ("imx: add imx8m support")
Signed-off-by: Tim Harvey <tharvey@gateworks.com>
Link: https://github.com/openwrt/openwrt/pull/21950
Signed-off-by: Robert Marko <robimarko@gmail.com>
2026-02-27 11:02:05 +01:00
Thomas Richard
6678487f16 arm-trusted-firmware-stm32: bump to v2.14
Some checks are pending
Build all core packages / Build all core packages for selected target (push) Waiting to run
Bump arm-trusted-firmware-stm32 to upstream release v2.14.

Signed-off-by: Thomas Richard <thomas.richard@bootlin.com>
Link: https://github.com/openwrt/openwrt/pull/21965
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
2026-02-26 23:34:10 +01:00
Thomas Richard
0903b398a3 uboot-stm32: bump to 2026.01
Bump uboot-stm32 to upstream release 2026.01.

Two upstream patches were backported to resolve silent crash on
STM32MP135F-DK board.

Signed-off-by: Thomas Richard <thomas.richard@bootlin.com>
Link: https://github.com/openwrt/openwrt/pull/21965
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
2026-02-26 23:34:10 +01:00
Thomas Richard
02d64076aa optee-os-stm32: bump to 4.9.0
Bump optee-os-stm32 to upstream release 4.9.0.

Signed-off-by: Thomas Richard <thomas.richard@bootlin.com>
Link: https://github.com/openwrt/openwrt/pull/21965
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
2026-02-26 23:34:10 +01:00
Hauke Mehrtens
efcd70cb19 mac80211: activate BRCMFMAC_SDIO on x86
Some checks are pending
Build Kernel / Build all affected Kernels (push) Waiting to run
Build all core packages / Build all core packages for selected target (push) Waiting to run
Activate the option BRCMFMAC_SDIO by default on x86 too. x86 already
compiles MMC support into the kernel. This will just compile brcmfmac
with MMC support.

Fixes: https://github.com/openwrt/openwrt/issues/22155
Link: https://github.com/openwrt/openwrt/pull/22171
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
2026-02-26 20:19:01 +01:00
Hauke Mehrtens
69daeebc9a wifi-scripts: fix handling of 64 character WPA key
The key variable is not defined in the scope when setting wpa_psk. Use
config.key instead.
This fixes configuration the 64 characters wpa_psk directly.

Reported-by: donjoe in OpenWrt Forum
Link: https://github.com/openwrt/openwrt/pull/22182
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
2026-02-26 20:17:31 +01:00
Hauke Mehrtens
758c8a26e9 ramips: mt7621: fix network configuration
The configuration for the dlink,dir-1360-a1 also changed the settings
for the devices defined on top of it. "lan1 lan2 lan3 lan4" "wan" is
the default configuration, no need to add it here.

Fixes: 7a8e2efed5 ("ramips: add support for D-Link DIR-1360 A1")
Reported-by: schmars in IRC
Link: https://github.com/openwrt/openwrt/pull/22179
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
2026-02-26 20:16:24 +01:00
Felix Fietkau
c4d875cae2 netifd: update to Git HEAD (2026-02-26)
Some checks are pending
Build all core packages / Build all core packages for selected target (push) Waiting to run
69a5afc9713a bridge: skip present toggle in bridge_free_member() when device is active

Signed-off-by: Felix Fietkau <nbd@nbd.name>
2026-02-26 12:05:35 +00:00
Rosen Penev
f5637607a2 bcm53xx: meraki mx6x: use nvmem MAC assignment
Some checks failed
Build Kernel / Build all affected Kernels (push) Has been cancelled
Userspace handling is deprecated. Once mac-base goes upstream, the patch
itself can go upstream as well.

Signed-off-by: Rosen Penev <rosenp@gmail.com>
Link: https://github.com/openwrt/openwrt/pull/22058
Signed-off-by: Robert Marko <robimarko@gmail.com>
2026-02-25 16:17:05 +01:00
Shiji Yang
73a41c38e7 ramips: dts: convert to dt-bindings clock index
Some checks are pending
Build Kernel / Build all affected Kernels (push) Waiting to run
Use clock index macros defined in dt-bindings header to improve the
code readability.

Signed-off-by: Shiji Yang <yangshiji66@outlook.com>
Link: https://github.com/openwrt/openwrt/pull/22163
Signed-off-by: Robert Marko <robimarko@gmail.com>
2026-02-25 14:06:02 +01:00
Sander Vanheule
ba57225066 realtek: hog the GS1900-24E external IC reset line
Some checks are pending
Build Kernel / Build all affected Kernels (push) Waiting to run
The GPIO line connecting to the reset signals of the GS1900-24E(A1)'s
external ICs (RTL8218B phys and RTL8231 expander) cannot be asserted by
the MDIO subsystem, as the reset is shared between busses.

To prevent users from accidentally asserting the reset line, a GPIO hog
is created to permanently de-assert the signal, reliably keeping the
phys and GPIO expanders on.

Tested-by: Simon Fischer <simi.fischa@gmail.com>
Signed-off-by: Sander Vanheule <sander@svanheule.net>
2026-02-24 21:29:26 +01:00
Sander Vanheule
cdbd9eb448 realtek: rtl838x: drop GS1900 MDIO reset GPIO
The reset line wired to the RTL8231 on the GS1900 series may also
connect to other external ICs on the board. On the GS1900-24E, the
reset line is wired (via buffers) to the board's RTL8231 expanders and
the RTL8218 phys. As these external devices (phys) are on different
busses, the reset line shouldn't be specified on one bus or the other.

Drop the reset specification from the generic GPIO description, so it
can be added back on a per-device basis after confirming the behavior.

Link: https://github.com/openwrt/openwrt/issues/18620
Fixes: fd978c2e80 ("realtek: Enable Zyxel GS1900's RTL8231 reset line")
Signed-off-by: Sander Vanheule <sander@svanheule.net>
2026-02-24 21:29:26 +01:00
Hauke Mehrtens
7c5e329b54 wireless-regdb: update to version 2026.02.04
Some checks failed
Build Kernel / Build all affected Kernels (push) Waiting to run
Build all core packages / Build all core packages for selected target (push) Has been cancelled
75bedc5 wireless-regdb: Update regulatory info for Australia (AU) for 2025
a6e5195 wireless-regdb: Update broken link in regulatory.bin(5) manpage
9e8c67f wireless-regdb: Update regulatory info for Malaysia (MY) for 2024
61a4637 wireless-regdb: Update regulatory info for Malaysia (MY) for 2025
5cefe55 wireless-regdb: Update regulatory info for Tunisia (TN) on 6GHz for 2025
1a729ae wireless-regdb: Update regulatory info for Canada (CA) for 2025
ea20dfa wireless-regdb: update regulatory database based on preceding changes

Link: https://github.com/openwrt/openwrt/pull/22150
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
2026-02-24 20:24:25 +01:00
Jonas Lochmann
5f063d18bd iproute2: include upstream patch for musl libc
Due to a missing include, the constant UINT_MAX is undefined. This
fixes issues when building v25.12.0-rc5. Including a newer version of
iproute2 would include the patch, but causes other building issues.

Signed-off-by: Jonas Lochmann <openwrt@jonaslochmann.de>
Link: https://github.com/openwrt/openwrt/pull/22128
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
2026-02-24 20:21:50 +01:00
Ahmed Naseef
7ee18e84dc econet: en7528: split DASAN H660GM-A into Airtel and Generic variants
The DASAN H660GM-A GPON ONT exists in two hardware variants, one
distributed by ISPs and one sold directly by the manufacturer [1].

Split the single DTS into a shared dtsi and per-variant DTS files
with the correct GPIO mappings, flash layout, and LED definitions.

Variant comparison:

  Feature        | Airtel                    | Generic
  ---------------+---------------------------+-------------------------
  Supplied by    | Airtel Xstream Fiber      | Retail
  Flash          | Micron MT29F2G01ABAGD     | Micron MT29F1G01ABAFD
                 | 256 MB                    | 128 MB
  Known P/N      | DPW-G-P-66GMAZ-A3         | DPW:G-P-660GMAY-G0
                 | (some units unlabelled)   | DPW:G-P-660GMAY-G3
  WPS LED        | Yes                       | No
  WLAN button    | No                        | Yes
  USB LED        | No                        | Yes
  LAN LEDs       | Green only                | Green + Amber

[1] https://dasanns.com/en/solution/detail.php?mode=view&cat_no=32&offset=&idx=122

Tested-by: Arif Rahman Hakim <arif2785id@gmail.com>
Signed-off-by: Ahmed Naseef <naseefkm@gmail.com>
Link: https://github.com/openwrt/openwrt/pull/22095
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
2026-02-24 20:17:24 +01:00
Felix Fietkau
55c01365de mac80211: backport eMLSR/eMLMR parsing support
Some checks are pending
Build Kernel / Build all affected Kernels (push) Waiting to run
Build all core packages / Build all core packages for selected target (push) Waiting to run
Needed for an upcoming mt76 update

Signed-off-by: Felix Fietkau <nbd@nbd.name>
2026-02-24 19:40:55 +01:00
Mieczyslaw Nalewaj
22ccb445e6 mt7620: workaround jal imm26 and redundant PAGE_ALIGN
Some checks are pending
Build Kernel / Build all affected Kernels (push) Waiting to run
On MT7620-class platforms (CONFIG_NET_RALINK_MT7620) we observe sporadic
wrong-jump-targets, kernel oopses, hanging, corrupted backtraces or even
"half-written" instructions when the compiler emits a direct 'jal imm26'
call.
This is triggered in:
  - the small random helpers inside get_random_u32_below(), and
  - the blkcg_maybe_throttle_current() call in resume_user_mode_work().

This patch forces those two call sites to use an indirect call via
a volatile function pointer (load into register + jalr) when building
for MT7620, avoiding embedding a 26-bit immediate jump target.

Additionally, on MT7620 builds the exec path in fs/exec.c is modified:
  - skip arch_align_stack() + PAGE_ALIGN() in setup_arg_pages()
    because the micro-randomization (< PAGE_SIZE) implemented by many
    ports (including MT7620) is negated immediately by PAGE_ALIGN().
    Skipping the redundant PAGE_ALIGN() reduces exposure to the
    problematic code pattern.

These changes are targeted workarounds for MT7620; behavioral logic is unchanged.

Signed-off-by: Mieczyslaw Nalewaj <namiltd@yahoo.com>
Link: https://github.com/openwrt/openwrt/pull/20553
Signed-off-by: Robert Marko <robimarko@gmail.com>
2026-02-24 14:40:39 +01:00
Robert Marko
dfbaf84650 ath79: mikrotik: fix DEVICE_PACKAGES
Instead of redifining the DEVICE_PACKAGES, make sure to expand the list
so yafut is included by default as well.

Fixes: 42cd486787 ("ath79: remove kmod-ath9k and wpad from Mikrotik RB750r2")
Signed-off-by: Robert Marko <robimarko@gmail.com>
2026-02-24 14:37:33 +01:00
Robert Marko
7bbe8d560c mvebu: use libdeflate for FitImage
Some checks are pending
Build Kernel / Build all affected Kernels (push) Waiting to run
Build all core packages / Build all core packages for selected target (push) Waiting to run
Use libdeflate for faster and better compression in FitImages.

Signed-off-by: Robert Marko <robert.marko@sartura.hr>
2026-02-24 11:47:22 +01:00
Tim Harvey
231553b280 imx: cortexa53: remove KSZ9477 static driver
The KSZ9477 driver was added to the cortexa53 kernel to support the
Gateworks Venice product family which has a board with this switch. Now
that the kmod-dsa-ksz9477 driver is available as a package remove the
static configuration ad add the package.

This resolves an issue caused by having the switch driver static and the
PHY driver as a module such that the PHY driver was not registered early
enough to be used causing some errata to not be worked around.

Signed-off-by: Tim Harvey <tharvey@gateworks.com>
Link: https://github.com/openwrt/openwrt/pull/22120
Signed-off-by: Robert Marko <robimarko@gmail.com>
2026-02-24 10:48:01 +01:00
Tim Harvey
c053b22573 kernel: netdevices: add KSZ9477 DSA switch packages
This adds kernel packages for the Microchip KSZ9477 switch family.

Signed-off-by: Tim Harvey <tharvey@gateworks.com>
Link: https://github.com/openwrt/openwrt/pull/22120
Signed-off-by: Robert Marko <robimarko@gmail.com>
2026-02-24 10:48:00 +01:00
Rosen Penev
2eb1f7df26 mac80211: ath9k: fix memory leak
Some checks are pending
Build Kernel / Build all affected Kernels (push) Waiting to run
Build all core packages / Build all core packages for selected target (push) Waiting to run
sc->gpiochip is assigned to gc when it should be the other way around.
This allows gpiod_free to work properly.

Fixes: e78dc2eae4 ("mac80211: ath9k: clean up gpiochi")
Signed-off-by: Rosen Penev <rosenp@gmail.com>
Link: https://github.com/openwrt/openwrt/pull/22158
Signed-off-by: Robert Marko <robimarko@gmail.com>
2026-02-24 09:58:42 +01:00
Markus Stockhausen
cf4cd07777 realtek: dsa: allow building as a module
Some checks are pending
Build Kernel / Build all affected Kernels (push) Waiting to run
Build all core packages / Build all core packages for selected target (push) Waiting to run
The makefile recipe is wrong and a module compilation tries
to build each object individually. Fix that. This allows to
build the dsa driver as a module.

Suggested-by: Balázs Triszka <info@balika011.hu>
Signed-off-by: Markus Stockhausen <markus.stockhausen@gmx.de>
Link: https://github.com/openwrt/openwrt/pull/22121
Signed-off-by: Robert Marko <robimarko@gmail.com>
2026-02-23 22:03:03 +01:00
Markus Stockhausen
f45cfd1f43 realtek: eth: remove fixed dsa coupling
The ethernet driver has a hard link to the dsa driver. Especially
the setup_tc() function must be available when the driver loads.
Decouple it by using a dsa callback recipe.

Suggested-by: Balázs Triszka <info@balika011.hu>
Signed-off-by: Markus Stockhausen <markus.stockhausen@gmx.de>
Link: https://github.com/openwrt/openwrt/pull/22121
Signed-off-by: Robert Marko <robimarko@gmail.com>
2026-02-23 22:03:02 +01:00
Markus Stockhausen
c6bbdb6489 realtek: mach: export soc_info
We do not want to rely on the soc_info structure. But at the moment
it is still referenced in several places. Add an EXPORT() to it.
So drivers that need access to this structure can be build as modules.

Suggested-by: Balázs Triszka <info@balika011.hu>
Signed-off-by: Markus Stockhausen <markus.stockhausen@gmx.de>
Link: https://github.com/openwrt/openwrt/pull/22121
Signed-off-by: Robert Marko <robimarko@gmail.com>
2026-02-23 22:03:02 +01:00
Eicke Herbertz
42cd486787 ath79: remove kmod-ath9k and wpad from Mikrotik RB750r2
The RB750r2 (HEXLite) does not have wifi and those packages bloat the image
by a significant amount. When building a custom image with WireGuard and
booting that from initramfs, there wasn't enough space left in tmpfs to
upload and flash the squashfs image. Investigating what packages I could
remove, I discovered these unneeded ones.

Signed-off-by: Eicke Herbertz <wolletd@posteo.de>
Link: https://github.com/openwrt/openwrt/pull/22134
Signed-off-by: Robert Marko <robimarko@gmail.com>
2026-02-23 22:00:21 +01:00
Shiji Yang
0bfcb0a36c kernel: net: fix deadlock caused by phy led trigger
Register phy led_triggers earlier to avoid AB-BA deadlock.

Fixes: https://github.com/openwrt/openwrt/issues/18472
Signed-off-by: Shiji Yang <yangshiji66@outlook.com>
Link: https://github.com/openwrt/openwrt/pull/22136
Signed-off-by: Robert Marko <robimarko@gmail.com>
2026-02-23 21:56:42 +01:00
Robert Marko
f0c9cbd35b netifd: update to Git HEAD (2026-02-23)
Some checks are pending
Build all core packages / Build all core packages for selected target (push) Waiting to run
299a51f0c301 global: add support for PSE-PD control

Signed-off-by: Robert Marko <robimarko@gmail.com>
2026-02-23 21:46:49 +01:00
Rosen Penev
ee5999cf78 treewide: linksys: use nvmem MAC for hw_mac_addr
Some checks are pending
Build Kernel / Build all affected Kernels (push) Waiting to run
Given that Linksys is the same brand and probably use the same OEM, it
stands to reason all devinfo hw_mac_addr implementations are the same.

Signed-off-by: Rosen Penev <rosenp@gmail.com>
Link: https://github.com/openwrt/openwrt/pull/22092
Signed-off-by: Robert Marko <robimarko@gmail.com>
2026-02-23 10:56:00 +01:00
Rosen Penev
581d10ebfc ipq806x: nbg6817: use nvmem for MAC addresses
Userspace handling is deprecated. NVMEM allows more flexibility in terms
of exotic setups while keeping correct MAC addresses.

env-size taken from file in uboot-envtools.

Signed-off-by: Rosen Penev <rosenp@gmail.com>
Link: https://github.com/openwrt/openwrt/pull/22107
Signed-off-by: Robert Marko <robimarko@gmail.com>
2026-02-23 10:54:08 +01:00
Rosen Penev
aef4d9e677 ipq806x: ac400i: use nvmem for MAC addresses
Userspace handling is deprecated. NVMEM allows flexibility in terms of
exotic setups by avoiding random MAC addresses.

u-boot env-size taken from the entry in uboot-envtools

Signed-off-by: Rosen Penev <rosenp@gmail.com>
Link: https://github.com/openwrt/openwrt/pull/22107
Signed-off-by: Robert Marko <robimarko@gmail.com>
2026-02-23 10:54:08 +01:00
Shiji Yang
eb3b8b3862 mediatek: backport various pinctrl fixes
Some checks are pending
Build Kernel / Build all affected Kernels (push) Waiting to run
Build all core packages / Build all core packages for selected target (push) Waiting to run
Backport patches from upstream linux and mtk-openwrt-feeds to fix
MT7981 register offset issue and correct MT798x IES register config.

Signed-off-by: Shiji Yang <yangshiji66@outlook.com>
Link: https://github.com/openwrt/openwrt/pull/21423
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
2026-02-22 23:07:18 +01:00
Shiji Yang
b18518c2f0 uboot-mediatek: backport various pinctrl fixes
Backport patches from upstream u-boot and mtk-openwrt-feeds to fix
MT7981 register offset issue and correct MT798x IES register config.

Signed-off-by: Shiji Yang <yangshiji66@outlook.com>
Link: https://github.com/openwrt/openwrt/pull/21423
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
2026-02-22 23:07:18 +01:00
Felix Baumann
85250b94f6 mediatek: add the aquantia kmod to bpi-r4
Some checks are pending
Build Kernel / Build all affected Kernels (push) Waiting to run
The banana pi r4 comes with 2 sfp+ ports running at 10gbps
Readd support for aquantia sfp+ modules that was removed by
57a127c9e7

Closes: #19878
Signed-off-by: Felix Baumann <felix.bau@gmx.de>
Link: https://github.com/openwrt/openwrt/pull/19884
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
2026-02-22 01:31:27 +01:00
Markus Stockhausen
75c772899c realtek: dsa: derive dsa port count and irq mask from cpu port
Some checks are pending
Build Kernel / Build all affected Kernels (push) Waiting to run
Avoid a family_id check and derive the values from the cpu port.

Signed-off-by: Markus Stockhausen <markus.stockhausen@gmx.de>
Link: https://github.com/openwrt/openwrt/pull/22068
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
2026-02-21 20:33:28 +01:00
Markus Stockhausen
9a0bd2d1aa realtek: dsa: move n_pie_blocks into config structure
Place it where it belongs.

Signed-off-by: Markus Stockhausen <markus.stockhausen@gmx.de>
Link: https://github.com/openwrt/openwrt/pull/22068
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
2026-02-21 20:33:28 +01:00
Markus Stockhausen
42a311bac9 realtek: dsa: move n_counters into config structure
Place it where it belongs.

Signed-off-by: Markus Stockhausen <markus.stockhausen@gmx.de>
Link: https://github.com/openwrt/openwrt/pull/22068
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
2026-02-21 20:33:28 +01:00
Markus Stockhausen
b74e261d56 realtek: eth: merge & simplify irq handlers
Two different irq handlers exist for RTL83xx and RTL93xx. Basically
they do always the same.

- Check transmit interrupts (not needed anymore)
- Check rx overflow interrupts (not needed anymore)
- Determine rx interrupts and queues that must be processed.
- In case of RTL839x check for L2 interrupts

With all the recent refactoring their logic is more or less the
same. Merge them into one handler. For better readability add a
helper that determines the work (aka rings) that needs to be
processed.

Signed-off-by: Markus Stockhausen <markus.stockhausen@gmx.de>
Link: https://github.com/openwrt/openwrt/pull/22023
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
2026-02-21 20:30:15 +01:00
Markus Stockhausen
8e33c40c7f realtek: fix LGS352C DTS
Some checks are pending
Build Kernel / Build all affected Kernels (push) Waiting to run
There is a wrong port assignment for the 4 SFP+ ports
on that device. Additionally the transmit polarity
change option was missed. Fix that.

Fixes: f88135b ("realtek: add support for Linksys LGS352C")
Signed-off-by: Markus Stockhausen <markus.stockhausen@gmx.de>
Link: https://github.com/openwrt/openwrt/pull/22119
Signed-off-by: Robert Marko <robimarko@gmail.com>
2026-02-21 18:58:38 +01:00
Jonas Jelonek
00ceb1ed17 realtek: pcs: rtl931x: configure SerDes-backing MAC groups
Some checks are pending
Build Kernel / Build all affected Kernels (push) Waiting to run
RTL931x organizes MACs into 12 groups (one per SerDes) that must be
explicitly enabled before link establishment. Without initialization,
link may fail or packets may be corrupted, especially in USXGMII/XSGMII
modes. This is the case for devices which lack initialization by the
bootloader.

Simply enable all MACs in all groups by writing 0xffffffff to the
registers. Unused MACs and reserved bits are harmless, avoiding complex
logic to always set only needed MACs.

This is placed in the PCS driver since the MAC groups are assigned per
SerDes and the DSA driver lacks SerDes awareness (on purpose)

Signed-off-by: Jonas Jelonek <jelonek.jonas@gmail.com>
Link: https://github.com/openwrt/openwrt/pull/22088
Signed-off-by: Robert Marko <robimarko@gmail.com>
2026-02-21 14:04:48 +01:00
Jonas Jelonek
81b148fd38 realtek: add support for XikeStor SKS8300-12X V1
Some checks are pending
Build Kernel / Build all affected Kernels (push) Waiting to run
Hardware:
  - SoC: RTL9313
  - Memory: 512MB
  - Flash: SPI-NOR 32MB (GigaDevice GD25Q256EFIR)
  - Ethernet: 12x 1/2.5/10 Gbps (SFP+)
  - LED/Keys (GPIO): 1x/1x
  - UART: "Console" port on the front panel
    - type: RS-232C
    - connector: RJ-45
    - settings: 9600n8 / 115200n8
  - Watchdog: Diodes PT7A7514WE
  - Monitoring: LM75A
  - Power: 100-240 VAC 50/60 Hz C13/C14

Important notes:
---------------

* the device uses 9600 Baud by default but this extremely slows down the
  device when using the serial console. OpenWrt is configured to use
  115200 Baud. If you need to enter the bootloader, you need to use 9600
  Baud.

* PT7A7514WE watchdog is fed through hardware-assisted SYS_LED. However,
  the bootloader seems to deactivate that again during autoboot. There's
  a quirk in early arch setup for this.

* a kernel binary "nos.img" needs to be stored into JFFS2 filesystem
  using 4KiB erase block instead of 64KiB.

* V1 is the version with the 19"-sized case. As of 2026, there's a newer
  version with a narrow case.

Flash instructions using initramfs image:
-----------------------------------------

(mostly taken from 0dc0b98295)

 1. Prepare TFTP server with an IP address in 192.168.2.0/24.
 2. Connect your PC to Port 1 on SKS8300-12X.
 3. Power on SKS8300-12X and interrupt autoboot by Ctrl + B.
 4. Login to the vendor CLI by Ctrl + F and "diagshell_unipoe_env" as password.
 5. Switch baudrate to 115200 by running a command and then reconnect
    with different settings:

    baudrate 115200

 6. Switch to U-Boot CLI by "debug_unish_env".
 7. Enable Port 1 with the following commands:

    rtk 10g 0 fiber1g	# (or fiber10g if 10GBase-*R)
    rtk ext-devInit 0	# init RTL8231 that holds SFP GPIOs
    rtk ext-pinSet 2 0	# set tx-disable of port 1 to LOW

 8. Transfer initramfs image via TFTP and boot it:

    tftpboot 0x82000000 <serverip>:<image name>
    bootm 0x82000000

 9. On the initramfs image, backup the stock firmware if needed.
10. Upload (or download) sysupgrade image to the device.
11. Erase "firmware" partition to cleanup JFFS2 of stock FW:

    mtd erase firmware

12. Perform sysupgrade with the sysupgrade image.
13. Wait until the flash completes and the system reboots into OpenWrt.

Reverting to stock firmware:
----------------------------

(taken from 0dc0b98295)

1. Prepare OpenWrt SDK to use the mkfs.jffs2 tool contained in it

   Note: the official mkfs.jffs2 tool in mtd-utils doesn't support 4KiB
         erase size and not usable for SKS8300-8X

2. Create a directory for working
3. Download official firmware for SKS8300-8X from XikeStor's official
   website
4. Rename the downloaded firmware to "nos.img" and place it to the
   working directory
5. Create a JFFS2 filesystem binary with the working directory

   /path/to/mkfs.jffs2 -p -b -U -v -e 4KiB -x lzma \
       -o nos.img.jffs2 -d /path/to/working/dir/

6. Upload the created JFFS2 filesystem binary to the device
7. Erase the "firmware" partition

   mtd erase firmware

8. Write the JFFS2 filesystem binary to the "firmware" partition

   mtd write /path/to/nos.img.jffs2 firmware

9. After writing, reboot the device by power cycle

Signed-off-by: Jonas Jelonek <jelonek.jonas@gmail.com>
Link: https://github.com/openwrt/openwrt/pull/21922
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
2026-02-21 00:49:51 +01:00
Jonas Jelonek
659719d8ca realtek: image: make xikestor-nosimg a common recipe
Make xikestor-nosimg a common recipe in the Makefile to allow usage for
other subtargets too, not only rtl930x.

Signed-off-by: Jonas Jelonek <jelonek.jonas@gmail.com>
Link: https://github.com/openwrt/openwrt/pull/21922
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
2026-02-21 00:49:51 +01:00
Jonas Jelonek
7f74364672 realtek: arch: add early watchdog quirk
On some XikeStor switches (SKS8300-8X, SKS8300-12X), the SYS_LED/GPIO0 is
used to feed an external PT7A7514WE watchdog. While this was no issue on
SKS8300-8X, the bootloader on the SKS8300-12X seems to deactivate the
automatic feeding on purpose by setting the pin function of to GPIO0
instead of SYS_LED. This kills the periodic signal generated on that pin.
This causes the kernel to just stop quite early and reset the system
entirely.

Because this happens very early, it doesn't work to define this as a
pinctrl entry or GPIO hog. The drivers aren't even loaded at that stage.
To work around the issue, we need to configure this in the arch-specific
early setup. An affected device needs to have a corresponding node in
the DTS that is picked up then.

Signed-off-by: Jonas Jelonek <jelonek.jonas@gmail.com>
Link: https://github.com/openwrt/openwrt/pull/21922
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
2026-02-21 00:49:51 +01:00
Jan Hoffmann
3bf55d8bd4 realtek: switch Netgear RTL8380 devices to NVMEM
Use NVMEM in device tree to set the label and eth0 MAC address based on
the U-Boot environment.

Invididual port MAC addresses and bridge MAC are still handled in the
02_network script to maintain the current assignment.

Signed-off-by: Jan Hoffmann <jan@3e8.eu>
Link: https://github.com/openwrt/openwrt/pull/22055
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
2026-02-21 00:31:48 +01:00
Jan Hoffmann
3f4b03cfe1 realtek: rtl838x: enable U-Boot env NVMEM layout in kernel
This is a preparation to convert some more RTL838x devices to NVMEM.

Signed-off-by: Jan Hoffmann <jan@3e8.eu>
Link: https://github.com/openwrt/openwrt/pull/22055
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
2026-02-21 00:31:48 +01:00
Markus Stockhausen
1ff39f9e98 realtek: mdio: setup polling for RTL8261
Startup of mdio on a RTL8216 based device currently shows the
following warnings.

[1.948608] skip polling setup for unknown PHY 001ccaf3 on port 0
[1.968920] skip polling setup for unknown PHY 001ccaf3 on port 8
[1.989171] skip polling setup for unknown PHY 001ccaf3 on port 16
[2.009704] skip polling setup for unknown PHY 001ccaf3 on port 20
[2.030209] skip polling setup for unknown PHY 001ccaf3 on port 24
[2.052270] realtek-otto-serdes-mdio 1b000000.switchcore:mdio-serdes:
           Realtek SerDes mdio bus initialized, 12 SerDes, 64 pages

Add the phy detection to the mdio bus so that polling setup works.
While we are here sort the phy ids alphabetically.

Signed-off-by: Markus Stockhausen <markus.stockhausen@gmx.de>
Link: https://github.com/openwrt/openwrt/pull/22109
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
2026-02-21 00:29:07 +01:00
Rosen Penev
b270580dea Revert "bmips: huawei-hg556a-c: use nvmem for wifi eeprom"
Some checks failed
Build Kernel / Build all affected Kernels (push) Waiting to run
Build all core packages / Build all core packages for selected target (push) Has been cancelled
Build and Push prebuilt tools container / Build and Push all prebuilt containers (push) Has been cancelled
Build Toolchains / Build Toolchains for each target (push) Has been cancelled
This reverts commit 72f43ac220.

The NVMEM codepath does not perform automatic byte conversion. It can be
fixed but the upstream version is quite different from the local
mac80211 patch. Revert until mac80211 gets updated and the whole mess
can get squared away.

Signed-off-by: Rosen Penev <rosenp@gmail.com>
Link: https://github.com/openwrt/openwrt/pull/22091
Signed-off-by: Robert Marko <robimarko@gmail.com>
2026-02-20 23:01:29 +01:00
Markus Stockhausen
0efd79b185 realtek: mdio: use register field indentation
Make clearer which field belongs to which register. For this
sort the fields below the registers and use indentation.

Signed-off-by: Markus Stockhausen <markus.stockhausen@gmx.de>
Link: https://github.com/openwrt/openwrt/pull/22075
Signed-off-by: Robert Marko <robimarko@gmail.com>
2026-02-20 22:56:53 +01:00
Markus Stockhausen
2e507f2edc realtek: mdio: taker over RTL931x PHY polling from DSA
PHY polling setup has found a home in the mdio driver. For RTL931x
there still exists a setup sequence for polling type (serdes/mdio)
in the DSA driver. Put it where it belongs.

Signed-off-by: Markus Stockhausen <markus.stockhausen@gmx.de>
Link: https://github.com/openwrt/openwrt/pull/22075
Signed-off-by: Robert Marko <robimarko@gmail.com>
2026-02-20 22:56:53 +01:00