On Wed, Nov 08, 2017 at 04:11:12PM +0100, Egil Hjelmeland wrote:
> On 07. nov. 2017 18:58, Andrew Lunn wrote:
> >>Hi Andrew!
> >>
> >>When local application join multicast; the driver get 2 X .port_mdb_prepare
> >>+ 4 x .port_mdb_add for the address.
> >
> >Humm, i would expect equal numbers of those.
> >
> 
> To be precise: it is (1 .port_mdb_prepare + 2 x .port_mdb_add), two times.
> 
> I see that the outer repeat is due to netdev_for_each_lower_dev() in
> br_mdb_switchdev_host(). So that means we get one notification for each
> dsa-port which is joined to the bridge.

Correct. That is intentional.

> But _all_ .port_mdb_add are repeated twice as well. This is more
> interesting. I suspect that there is a missing "return 0;" in
> dsa_switch_mdb_add(), at the end of the "if
> (switchdev_trans_ph_prepare(trans)) {". Dating back to
> a1a6b7ea7f2de270a51360cc48e7c49f7a283dda.

Yes. Good catch.

     Andrew

Reply via email to