[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <20071018.223820.49264165.davem@davemloft.net>
Date: Thu, 18 Oct 2007 22:38:20 -0700 (PDT)
From: David Miller <davem@...emloft.net>
To: herbert@...dor.apana.org.au
Cc: benh@...nel.crashing.org, akpm@...ux-foundation.org,
linux-kernel@...r.kernel.org, linuxppc-dev@...abs.org,
mingo@...e.hu, tglx@...utronix.de, torvalds@...ux-foundation.org,
netdev@...r.kernel.org
Subject: Re: [NET]: Fix possible dev_deactivate race condition
From: Herbert Xu <herbert@...dor.apana.org.au>
Date: Fri, 19 Oct 2007 13:36:24 +0800
> [NET]: Fix possible dev_deactivate race condition
>
> The function dev_deactivate is supposed to only return when
> all outstanding transmissions have completed. Unfortunately
> it is possible for store operations in the driver's transmit
> function to only become visible after dev_deactivate returns.
>
> This patch fixes this by taking the queue lock after we see
> the end of the queue run. This ensures that all effects of
> any previous transmit calls are visible.
>
> If however we detect that there is another queue run occuring,
> then we'll warn about it because this should never happen as
> we have pointed dev->qdisc to noop_qdisc within the same queue
> lock earlier in the functino.
>
> Signed-off-by: Herbert Xu <herbert@...dor.apana.org.au>
Applied, thanks Herbert!
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists