The provided information about FDB flushing is not really up to date. The DSA core automatically calls port_fast_age() when necessary, and drivers should just implement that rather than hooking it to port_bridge_leave, port_stp_state_set and others.
Unified · Split
| @@ -738,15 +738,11 @@ Bridge layer · 737 unmodified lines | ||
| 738 | 738 | - ``port_bridge_leave``: bridge layer function invoked when a given switch port is |
| 739 | 739 | removed from a bridge, this function should do what's necessary at the |
| 740 | 740 | switch level to deny the leaving port from ingress/egress traffic from the |
| 741 | − remaining bridge members. When the port leaves the bridge, it should be aged | |
| 742 | − out at the switch hardware for the switch to (re) learn MAC addresses behind | |
| 743 | − this port. | |
| 741 | + remaining bridge members. | |
| 744 | 742 | |
| 745 | 743 | - ``port_stp_state_set``: bridge layer function invoked when a given switch port STP |
| 746 | 744 | state is computed by the bridge layer and should be propagated to switch |
| 747 | − hardware to forward/block/learn traffic. The switch driver is responsible for | |
| 748 | − computing a STP state change based on current and asked parameters and perform | |
| 749 | − the relevant ageing based on the intersection results | |
| 745 | + hardware to forward/block/learn traffic. | |
| 750 | 746 | |
| 751 | 747 | - ``port_bridge_flags``: bridge layer function invoked when a port must |
| 752 | 748 | configure its settings for e.g. flooding of unknown traffic or source address |
| @@ -775,6 +771,12 @@ Bridge layer · 22 unmodified lines | ||
| 775 | 771 | - ``port_bridge_tx_fwd_unoffload``: bridge layer function invoked when a driver |
| 776 | 772 | leaves a bridge port which had the TX forwarding offload feature enabled. |
| 777 | 773 | |
| 774 | +- ``port_fast_age``: bridge layer function invoked when flushing the | |
| 775 | + dynamically learned FDB entries on the port is necessary. This is called when | |
| 776 | + transitioning from an STP state where learning should take place to an STP | |
| 777 | + state where it shouldn't, or when leaving a bridge, or when address learning | |
| 778 | + is turned off via ``port_bridge_flags``. | |
| 779 | + | |
| 778 | 780 | Bridge VLAN filtering |
| 779 | 781 | --------------------- |
| 780 | 782 | |