[ovs-dev] [PATCH 17/18] bridge: Set multicast snooping table configuration

Ben Pfaff blp at nicira.com
Tue May 20 23:30:13 UTC 2014


On Fri, Apr 11, 2014 at 06:34:22PM -0300, Flavio Leitner wrote:
> Fix bridge to create and configure multicast snooping.
> 
> Acked-by: Thomas Graf <tgraf at redhat.com>
> Signed-off-by: Flavio Leitner <fbl at redhat.com>

Code like this:
> +        if (smap_get_bool(&br->cfg->other_config,
> +                          "mcast-snooping-flood-unregistered",
> +                          false)) {
> +            br_s.flood_unreg = true;
> +        } else {
> +            br_s.flood_unreg = false;
> +        }
can be written as a simple assignment without an 'if'.  I see this in
two places.

I don't think that ofproto_port_set_mcast_snooping() can currently
fail.  I'm not sure that it's worth having extra code to disable
snooping if one call does fail.  But I guess it doesn't hurt, either.
(On the other hand, "bridge %s: could not configure %d ports,
disabling" makes it sound like more than multicast snooping being
disabled).



More information about the dev mailing list