realtek: dsa: rtl930x: Fix flow control with ingress shaping
authorSven Eckelmann <[email protected]>
Mon, 1 Dec 2025 12:58:40 +0000 (13:58 +0100)
committerRobert Marko <[email protected]>
Tue, 2 Dec 2025 09:42:24 +0000 (10:42 +0100)
commit141ac0b2bd1e7cbad1a75fe17a7b47a3778d16ca
treea327ec4c89e72d7ed045cee4fabbca48cacb78f0
parent2bc79783233c5d8612bfa5831cd334cab62b3e5e
realtek: dsa: rtl930x: Fix flow control with ingress shaping

Tests with ingress shaping and enabled flow control showed really high
packet loss. It seems like the MAC pause frames are not created correctly
when both burst high off is set to the same value as burst high on.

By default, RTL930x has set the burst high values to:

* on: 64K
* off: 32K

Using the same 1:2 ratio seems to solve the high packet loss rate during
UDP tests.

Fixes: 2e74eb6d93a7 ("realtek: dsa: rtl93xx: Support per port throttling")
Signed-off-by: Sven Eckelmann <[email protected]>
Link: https://github.com/openwrt/openwrt/pull/21011
Signed-off-by: Robert Marko <[email protected]>
target/linux/realtek/files-6.12/drivers/net/dsa/rtl83xx/rtl930x.c