[Top] [All Lists]

Re: [XFRM] Handle device down/unregister events

To: "David S. Miller" <davem@xxxxxxxxxx>
Subject: Re: [XFRM] Handle device down/unregister events
From: Herbert Xu <herbert@xxxxxxxxxxxxxxxxxxx>
Date: Thu, 27 Nov 2003 21:59:07 +1100
Cc: kuznet@xxxxxxxxxxxxx, jmorris@xxxxxxxxxx, netdev@xxxxxxxxxxx
In-reply-to: <20031125222059.6730f242.davem@xxxxxxxxxx>
References: <20031126044355.GA18805@xxxxxxxxxxxxxxxxxxx> <20031125222059.6730f242.davem@xxxxxxxxxx>
Sender: netdev-bounce@xxxxxxxxxxx
User-agent: Mutt/1.5.4i
On Tue, Nov 25, 2003 at 10:20:59PM -0800, David S. Miller wrote:
> Thanks for catching this, I'll review and apply your patch soon.

Hmm, it looks like my patch has a slight race in it.  It is possible
for a device to be added to a dst, go down and unregister, and then
the dst is added to a bundle.

This isn't really a problem for net devices without destructors though
since the UNREGISTER event is rebroadcast at regular intervals.

However, it also affects xfrm_flush_bundle() and xfrm states don't
enjoy the benefit of repeated flushes.

Here is an updated patch that checks whether a dst is still valid
before adding it to a bundle.

Debian GNU/Linux 3.0 is out! ( )
Email:  Herbert Xu ~{PmV>HI~} <herbert@xxxxxxxxxxxxxxxxxxx>
Home Page:
PGP Key:

Attachment: p
Description: Text document

<Prev in Thread] Current Thread [Next in Thread>