Support for RTL838x based managed switches

Actually, the first code for LAG was added before that: https://git.openwrt.org/?p=openwrt/openwrt.git;a=commit;h=6f67c079e61a01d599af34dbb852a4fe99d0f52d

At the time, there kernel didn't support LAGs for DSA switches yet (so the implementation uses a netdevice event handler in the driver). Then the commit you linked implemented the actual DSA LAG callbacks from the kernel. However, it also kept the old implementation.

The result is that the current implementation is a mess that just doesn't work properly. Some time ago, I started an attempt to fix it (https://github.com/janh/openwrt/commits/realtek-fix-lag/), but didn't finish it. Note that in the current state of this branch, hardware offloading of LAG is intentionally disabled, as rtl83xx_lag_can_offload returns false. I did this because I wanted a reference for testing, which unfortunately turned up some other more important issues to work on.

Here is a previous comment from me about LAG support:

7 Likes