[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <CAF1J0HOpsbD-4ZPd3kJPE9YmUy4ihmWr5TSou9HuHzFNA1Wy=Q@mail.gmail.com>
Date: Wed, 5 Jun 2013 15:53:30 +0300
From: Mike Rapoport <mike.rapoport@...ellosystems.com>
To: David Stevens <dlstevens@...ibm.com>
Cc: netdev@...r.kernel.org, netdev-owner@...r.kernel.org,
Stephen Hemminger <stephen@...workplumber.org>,
Thomas Graf <tgraf@...g.ch>
Subject: Re: [RFC] vxlan: convert remote list to list_rcu
On Tue, Jun 4, 2013 at 10:02 PM, David Stevens <dlstevens@...ibm.com> wrote:
> netdev-owner@...r.kernel.org wrote on 06/04/2013 01:20:22 PM:
>
>> From: Mike Rapoport <mike.rapoport@...ellosystems.com>
>
>> If I've understood you right it would be something like this:
>>
>
> All the tabs are removed in the code I got-- don't know if
> it's your mailer or my reader....
My mailer, I afraid. Sorry about that.
> This isn't correct -- I led you into that one,
> but the original code is what we'd need -- it isn't
> "rdst NULL" this is checking, but really "dst == INADDR_ANY",
> which is probably what it ought to be, instead of "0".
> At any rate, the check there works and needs to stay;
> dst == INADDR_ANY is a distinct case from rdst == NULL.
Yeah, it looked wrong to me, but it was too late in the evening for me :)
> Also looks like you're missing a brace on the L2MISS check --
> the miss and the drop are only if the all-zeroes lookup
> fails.
I'm not sure if we can allow empty list of default destinations. I
think that the fdb entry for ALL_ZEROS_MAC should always contain at
least one entry corresponding to current default_dst.
> But the general idea looks good. If you remove the
> is_zero_ether_addr() check in rtnl_fdb_add and rtnl_fdb_del,
> then the existing fdb_add/fdb_append/fdb_del code code
> would allow changes, including multiple destinations, to
> the default destinations as well.
Yeah, but in this case 'fdb del 00:00:00:00:00:00' kills all the
defaults and makes userspace responsible to restore those that are
still valid.
Maybe in the case of 'fdb del 00:00:00:00:00:00' we should require
NDA_DST to be present...
Another issue with making default destinations fdb with ALL_ZEROS_MAC
is that vxlan_cleanup may eventually garbage collect it.
I'll experiment some more to see if maintaining separate list of
default destinations or making them fdb comes cleaner at the end.
> But there's more to it, too -- default_dst and all its references
> would need to be replaced for joining groups and the netlink
> part, and removed from vxlan_dev.
Again, there should always be at least one default destination. And if
the references for default_dst should be replaced, some defaults need
to be kept in vxlan_dev for fallbacks...
> +-DLS
>
--
Sincerely yours,
Mike.
--
To unsubscribe from this list: send the line "unsubscribe netdev" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Powered by blists - more mailing lists