realtek: Enclose complex macros in parentheses
authorSven Eckelmann <[email protected]>
Sun, 23 Nov 2025 11:43:28 +0000 (12:43 +0100)
committerHauke Mehrtens <[email protected]>
Mon, 24 Nov 2025 23:28:49 +0000 (00:28 +0100)
commit039c9802a1f8e52bccc4c3c9c752a4cb27641db7
tree7b85fd8bef3236153dda240fc950e3a6b6e771d3
parentc6ed536839a4d66d4a05f1da8d0ffc6173cbae13
realtek: Enclose complex macros in parentheses

The macros will be inserted as is by the pre-compiler into places which
uses them. This can cause weird effects because this can break the syntax
or the ordering of operations. Just adding parentheses can avoid a lot of
these unexpected effects.

(for even more complex, multi-expression macros, `do {...} while (0)` is
required).

Signed-off-by: Sven Eckelmann <[email protected]>
Link: https://github.com/openwrt/openwrt/pull/20906
Signed-off-by: Hauke Mehrtens <[email protected]>
target/linux/realtek/files-6.12/drivers/net/dsa/rtl83xx/rtl838x.c
target/linux/realtek/files-6.12/drivers/net/dsa/rtl83xx/rtl839x.c
target/linux/realtek/files-6.12/drivers/net/dsa/rtl83xx/rtl930x.c
target/linux/realtek/files-6.12/drivers/net/dsa/rtl83xx/rtl931x.c