net: hsr: add offloading support
Add support for offloading of HSR/PRP (IEC 62439-3) tag insertion tag removal, duplicate generation and forwarding. For HSR, insertion involves the switch adding a 6 byte HSR header after the 14 byte Ethernet header. For PRP it adds a 6 byte trailer. Tag removal involves automatically stripping the HSR/PRP header/trailer in the switch. This is possible when the switch also performs auto deduplication using the HSR/PRP header/trailer (making it no longer required). Forwarding involves automatically forwarding between redundant ports in an HSR. This is crucial because delay is accumulated as a frame passes through each node in the ring. Duplication involves the switch automatically sending a single frame from the CPU port to both redundant ports. This is required because the inserted HSR/PRP header/trailer must contain the same sequence number on the frames sent out both redundant ports. Export is_hsr_master so DSA can tell them apart from other devices in dsa_slave_changeupper. Signed-off-by:George McCollister <george.mccollister@gmail.com> Reviewed-by:
Vladimir Oltean <olteanv@gmail.com> Signed-off-by:
David S. Miller <davem@davemloft.net>
Showing
- Documentation/networking/netdev-features.rst 21 additions, 0 deletionsDocumentation/networking/netdev-features.rst
- include/linux/if_hsr.h 27 additions, 0 deletionsinclude/linux/if_hsr.h
- include/linux/netdev_features.h 9 additions, 0 deletionsinclude/linux/netdev_features.h
- net/ethtool/common.c 4 additions, 0 deletionsnet/ethtool/common.c
- net/hsr/hsr_device.c 3 additions, 11 deletionsnet/hsr/hsr_device.c
- net/hsr/hsr_device.h 0 additions, 1 deletionnet/hsr/hsr_device.h
- net/hsr/hsr_forward.c 24 additions, 3 deletionsnet/hsr/hsr_forward.c
- net/hsr/hsr_forward.h 1 addition, 0 deletionsnet/hsr/hsr_forward.h
- net/hsr/hsr_framereg.c 2 additions, 0 deletionsnet/hsr/hsr_framereg.c
- net/hsr/hsr_main.c 11 additions, 0 deletionsnet/hsr/hsr_main.c
- net/hsr/hsr_main.h 1 addition, 7 deletionsnet/hsr/hsr_main.h
- net/hsr/hsr_slave.c 6 additions, 4 deletionsnet/hsr/hsr_slave.c
Loading
Please register or sign in to comment