On Thu, May 05, 2016 at 12:18:52PM +0000, Kavanagh, Mark B wrote: > >+ if ((ret = netdev_dpdk_lookup_vhost_id(dev)) >= 0) { > >+ ifindex = VHOST_ID_TO_IFINDEX(ret); > >+ } else { > >+ ifindex = 0; > > I don't think that 0 is an appropriate value to return here, since it > overlaps with a kernel interface's index.
0 is never a valid ifindex value, at least on a POSIX system, since it is the error return value from if_nametoindex(), see: http://pubs.opengroup.org/onlinepubs/009695399/functions/if_nametoindex.html _______________________________________________ dev mailing list dev@openvswitch.org http://openvswitch.org/mailman/listinfo/dev