On 19 February 2013 17:11, Rafał Miłecki <zaj...@gmail.com> wrote: > 2013/2/19 Jonas Gorski <j...@openwrt.org>: >> On 19 February 2013 16:17, Rafał Miłecki <zaj...@gmail.com> wrote: >>> Setting this bit stops BCM53125 (bgmac actually) from receiving any >>> packets. In theory setting "managed" mode makes sense when enabling VLAN >>> (at least for me?) but for some reason it breaks configuration. >>> >>> This bit is cleared in b53_switch_reset and it seems the same is done in >>> bcmrobo.c which never sets that bit again. >> >> The bit is a bit misnamed, it doesn't enable management per se but >> actually enables special treatment for the CPU port and certain >> ethernet frames (IIRC multicast joins/leaves etc). It's probably fine >> to keep it disabled until we want to use multicast snooping or 802.1x >> authentication (which IIRC require this to allow "trap to CPU" to >> work), or want to implement open vswitch support (as if ;-). > > Thanks for explaining. Can you suggest any better name for this bit? > Something we could replace SM_SW_FWD_MODE with?
Well that's the name broadcom uses it its documentation, so I wouldn't want to go too far from it, else it will be confusing for people comparing it with the documentation ;-) >>> I'm not sure about clearing SM_SW_FWD_MODE bit in the "else" inside of >>> b53_enable_vlan. Should be drop that too? >> >> Probably just clear it unconditionally. I need to make sure first it >> doesn't break 5325 or 53115. > > We already clear it unconditionally in the "else" of b53_enable_vlan > :) So... is that alright, or maybe we should do the opposite and *set* > that bit in the "else" of b53_enable_vlan (when *disabling* VLAN)? Definitely not. The bit is for telling the switch that there is "management software" running behind the CPU port, so enabling it in the non-vlan case makes even less sense. I think the 5365 programmer's guide explains it a bit. > Maybe I could try disabling VLAN with "swconfig" to test if it works, > and play with that SM_SW_FWD_MODE bit. > > -- > Rafał > _______________________________________________ > openwrt-devel mailing list > openwrt-devel@lists.openwrt.org > https://lists.openwrt.org/mailman/listinfo/openwrt-devel _______________________________________________ openwrt-devel mailing list openwrt-devel@lists.openwrt.org https://lists.openwrt.org/mailman/listinfo/openwrt-devel