On Tue, Mar 06, 2012 at 02:37:16PM -0800, Pravin B Shelar wrote:
> Signed-off-by: Pravin B Shelar <[email protected]>
This code in netdev_linux_get_etheraddr() looks awkward to me:
if (netdev_dev->cache_valid & VALID_ETHERADDR) {
goto out;
}
get_etheraddr(netdev_dev);
out:
How about, instead:
if (!(netdev_dev->cache_valid & VALID_ETHERADDR)) {
get_etheraddr(netdev_dev);
}
Like MTU, the Ethernet address is part of the rtnetlink messages, so
it would make sense to populate and refresh it directly from the
rtnetlink callback the same way that we now refresh MTU.
I think that we should drop the hwaddr_family parameter from
set_etheraddr(), because it is always passed as a hard-coded
ARPHRD_ETHER.
Thanks,
Ben.
_______________________________________________
dev mailing list
[email protected]
http://openvswitch.org/mailman/listinfo/dev