]> git.ipfire.org Git - thirdparty/openwrt.git/commit
realtek: dsa: rtl839x: fix uninitialized global access
authorMarkus Stockhausen <markus.stockhausen@gmx.de>
Sun, 25 Jan 2026 18:07:32 +0000 (19:07 +0100)
committerHauke Mehrtens <hauke@hauke-m.de>
Sun, 8 Feb 2026 20:25:29 +0000 (21:25 +0100)
commit21414937d11d4e75e2a7a11cbd6e36f243c2d4bb
treead556859c786f86076644bf67977e879cae68d2d
parent0837be599dee9c13b83130b5effc2bb6faed4fa1
realtek: dsa: rtl839x: fix uninitialized global access

Setup for DSA QOS on RTL839x accesses unitialized memory. For some
reason the handover of the priv structure was realized via global
intermediate variable switch_priv. During refactoring for adbb9a6
("realtek: dsa: rtl83xx: fix init section mismatch") this was not
noticed. Since then RTL839x devices crash during startup.

Fix this by using standard handover via function parameters.

Fixes: e81affb9 ("realtek: dsa: rtl83xx: fix init section mismatch")
Signed-off-by: Markus Stockhausen <markus.stockhausen@gmx.de>
Link: https://github.com/openwrt/openwrt/pull/21703
Signed-off-by: Robert Marko <robimarko@gmail.com>
(cherry picked from commit ac9646394482ba2e464ccf75e74c936485028305)
Link: https://github.com/openwrt/openwrt/pull/21900
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
target/linux/realtek/files-6.12/drivers/net/dsa/rtl83xx/qos.c