[][kernel][mt7988][eth][Add DIP dynamic allocation to the LRO]

[Description]
Add DIP dynamic allocation to the LRO.

The LRO2 is equipped with only 4 DIP registers, with each GMAC occupying
2 DIPS. As a result, GMAC3 will not be able to allocate a DIP register.
Therefore, we add a dymanic allocation to enhance the user scenario.

Besides, users can utilize the commands listed below to operate LRO.
  - Check LRO status
    ethtool -k ethX |grep large-receive-offload
  - Turn on LRO
    ethtool -K ethX lro on
    // Please ensure that ethX has been remove from br-lan
  - Turn off LRO
    ethtool -K ethX lro off
    // Please ensure that ethX has been remove from br-lan
  - Add LRO RX action
    ethtool -N ethX flow-type tcp4 dst-ip DIP action 0 loc Y
    // DIP can be any arbitrary IP address, and Y can be 0 or 1
  - Dump LRO RX action
    ethtool -n ethX

Without this patch, GMAC3 will not be able to allocate a DIP register.

[Release-log]
N/A


Change-Id: I9c0bcc32a85924ad4c426a803a6c7020d08a2f25
Reviewed-on: https://gerrit.mediatek.inc/c/openwrt/feeds/mtk_openwrt_feeds/+/8357291
1 file changed