mirror of
https://github.com/logicog/RTLPlayground.git
synced 2026-10-29 17:54:14 +08:00
trap: deliver reserved multicast to the CPU by trap, STP first
A reserved-multicast trap goes to the port named in EXT_CPU_CTRL, which names no port out of reset, so trapped frames were dropped at ingress. trap_init() points it at the CPU port once at startup, and trap_rma_set() changes only the action field of an RMA register. A trapped frame arrives without the VLAN tag a forwarded one gets, so TRAP_RX_BODY() gives the offset of the payload for both forms. STP now traps its address while it runs instead of steering it with a static L2 entry per VLAN, so turning it on no longer walks the VLAN table and a pvid change no longer needs stp off and on. With STP off the flooding entries are restored as before. A trapped BPDU passes the tagged-only ingress filter that drops a forwarded one, so the stp_setup() warning about such ports goes.
This commit is contained in:
1 parent
84d9408151
commit
14b2ce1c49
8 files changed
+97
-48
No files matched your search
@@ -285,6 +285,12 @@
|
||||
*/
|
||||
#define RTL8373_RLDP_TIMER 0x1074
|
||||
#define RTL837X_RMA0_CONF 0x4ecc
|
||||
#define RTL837X_RMA2_CONF 0x4ed4
|
||||
#define RTL837X_RMA_ACT_MASK 0x30
|
||||
#define RTL837X_RMA_ACT_FORWARD 0x00
|
||||
#define RTL837X_RMA_ACT_TRAP 0x10
|
||||
#define RTL837X_RMA_ACT_DROP 0x20
|
||||
#define RTL837X_EXT_CPU_CTRL 0x6724
|
||||
#define RTL837X_IMR_INT_PORT_LINK_STS_CHG 0x5f34
|
||||
#define RTL837X_ISR_SW_INT_MODE 0x5f84
|
||||
#define RTL837X_ISR_INT_PORT_LINK_CHG 0x5f88
|
||||
|
||||
Reference in new issue
Block a user