From: "Timo Teräs" <timo.teras@iki•fi>
To: Patrick McHardy <kaber@trash•net>
Cc: netdev@vger•kernel.org
Subject: Re: [PATCH 2/2] ipv4: flush ARP entries on device change
Date: Thu, 04 Mar 2010 13:15:11 +0200 [thread overview]
Message-ID: <4B8F963F.5020901@iki.fi> (raw)
In-Reply-To: <4B8E75E1.8060909@trash.net>
Patrick McHardy wrote:
> Timo Teräs wrote:
>> Patrick McHardy wrote:
>>> Timo Teräs wrote:
>>>> Patrick McHardy wrote:
>>>>> Timo Teras wrote:
>>>>> It would be nice if we could restrict this to IFF_NOARP changes.
>>>> Yes. But I did not see any easy way to figure out which flags have
>>>> changed.
>>>>
>>>> Should we just keep a copy of the previous IFF_NOARP bit somewhere
>>>> (where?).
>>>> Or did I miss something obvious?
>>> We shouldn't have any arp entries for devices with IFF_NOARP set,
>>> so perhaps we can flush only in that case. The transition IFF_NOARP
>>> -> ~IFF_NOARP shouldn't need flushing.
>> IFF_NOARP devices do have neighbor entries with the nud NOARP.
>> Exactly those entries I want to flush when IFF_NOARP flag is
>> removed.
>>
>> You can see those entries with "ip neigh show nud all". You have
>> them e.g. for loopback stuff and broad-/multicast stuff in general.
>> With IFF_NOARP you get them on all unicast addresses used.
>
> I see. I don't have a better suggestion, except perhaps
> to store the bit in dev->priv_flags.
Ok.
Should I make a patch that uses dev->priv_flags and repost?
Or would make sense to have more generic way, e.g. keep copy
of the previous flags in struct net_device so notifiers can
check which ones changed (or would this have locking issues?).
- Timo
next prev parent reply other threads:[~2010-03-04 11:15 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2010-03-03 14:01 [PATCH 1/2] gre: fix hard header destination address checking Timo Teras
2010-03-03 14:01 ` [PATCH 2/2] ipv4: flush ARP entries on device change Timo Teras
2010-03-03 14:06 ` Patrick McHardy
2010-03-03 14:20 ` Timo Teräs
2010-03-03 14:33 ` Patrick McHardy
2010-03-03 14:39 ` Timo Teräs
2010-03-03 14:44 ` Patrick McHardy
2010-03-04 11:15 ` Timo Teräs [this message]
2010-03-04 8:41 ` [PATCH 1/2] gre: fix hard header destination address checking David Miller
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=4B8F963F.5020901@iki.fi \
--to=timo.teras@iki$(echo .)fi \
--cc=kaber@trash$(echo .)net \
--cc=netdev@vger$(echo .)kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox