From: Lorenzo Bianconi <lorenzo.bianconi@redhat.com>
To: David Ahern <dsahern@gmail.com>
Cc: davem@davemloft.net, netdev@vger.kernel.org, marek@cloudflare.com
Subject: Re: [PATCH net v2] net: neigh: fix multiple neigh timer scheduling
Date: Sun, 14 Jul 2019 22:04:18 +0200 [thread overview]
Message-ID: <20190714200418.GA28813@localhost.localdomain> (raw)
In-Reply-To: <26f58e35-f1f8-9543-819f-ef7f52da1e49@gmail.com>
[-- Attachment #1: Type: text/plain, Size: 1136 bytes --]
> On 7/14/19 2:45 AM, Lorenzo Bianconi wrote:
> > @@ -1124,7 +1125,9 @@ int __neigh_event_send(struct neighbour *neigh, struct sk_buff *skb)
> >
> > atomic_set(&neigh->probes,
> > NEIGH_VAR(neigh->parms, UCAST_PROBES));
> > - neigh->nud_state = NUD_INCOMPLETE;
> > + if (check_timer)
> > + neigh_del_timer(neigh);
>
> Why not just always call neigh_del_timer and avoid the check_timer flag?
> Let the NUD_IN_TIMER flag handle whether anything needs to be done.
ack, I have been too paranoid here. I will post a v3 fixing it.
Regards,
Lorenzo
>
> > + neigh->nud_state = NUD_INCOMPLETE;
> > neigh->updated = now;
> > next = now + max(NEIGH_VAR(neigh->parms, RETRANS_TIME),
> > HZ/2);
> > @@ -1140,6 +1143,8 @@ int __neigh_event_send(struct neighbour *neigh, struct sk_buff *skb)
> > }
> > } else if (neigh->nud_state & NUD_STALE) {
> > neigh_dbg(2, "neigh %p is delayed\n", neigh);
> > + if (check_timer)
> > + neigh_del_timer(neigh);
> > neigh->nud_state = NUD_DELAY;
> > neigh->updated = jiffies;
> > neigh_add_timer(neigh, jiffies +
>
[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 228 bytes --]
prev parent reply other threads:[~2019-07-14 20:04 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2019-07-14 8:45 [PATCH net v2] net: neigh: fix multiple neigh timer scheduling Lorenzo Bianconi
2019-07-14 13:58 ` David Ahern
2019-07-14 19:15 ` David Miller
2019-07-14 20:04 ` Lorenzo Bianconi [this message]
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=20190714200418.GA28813@localhost.localdomain \
--to=lorenzo.bianconi@redhat.com \
--cc=davem@davemloft.net \
--cc=dsahern@gmail.com \
--cc=marek@cloudflare.com \
--cc=netdev@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.