[ovs-dev] [netlink v4 27/52] datapath: Change userspace vport interface to use Netlink attributes.

Jesse Gross jesse at nicira.com
Fri Jan 21 02:54:56 UTC 2011


On Thu, Jan 20, 2011 at 6:03 PM, Ben Pfaff <blp at nicira.com> wrote:
>        mutable->flags = nla_get_u32(a[TNLAT_FLAGS]);
> +       if (mutable->flags & ~TNL_F_PUBLIC)
> +               return -EINVAL;

This is a little bit different from the Netlink policy of ignoring
attributes that aren't recognized.  Should we do
nla_get_u32(a[TNLAT_FLAGS]) & TNL_F_PUBLIC instead?

Otherwise it looks good.  The capwap key code looks a little strange
because it is checking for flow based keys when it is not really using
them.  However, the net result should be right, which is to enforce
that no key attributes were set.  Maybe the comment could be expanded
a little bit to explain this.




More information about the dev mailing list