On Wed, Mar 7, 2012 at 10:32 AM, Ben Pfaff <[email protected]> wrote:
> 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);
>    }
>
ok.

> 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.
>
right, I can get it from notification.

> I think that we should drop the hwaddr_family parameter from
> set_etheraddr(), because it is always passed as a hard-coded
> ARPHRD_ETHER.
>

ok.

> Thanks,
>
> Ben.
_______________________________________________
dev mailing list
[email protected]
http://openvswitch.org/mailman/listinfo/dev

Reply via email to