From mboxrd@z Thu Jan 1 00:00:00 1970 From: "David S. Miller" Subject: Re: atomic_dec_and_test for child dst needed in dst_destroy? Date: Tue, 5 Apr 2005 14:48:53 -0700 Message-ID: <20050405144853.0523fde6.davem@davemloft.net> References: Mime-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Cc: christoph@lameter.com, netdev@oss.sgi.com Return-path: To: Herbert Xu In-Reply-To: Sender: netdev-bounce@oss.sgi.com Errors-to: netdev-bounce@oss.sgi.com List-Id: netdev.vger.kernel.org On Wed, 06 Apr 2005 07:45:06 +1000 Herbert Xu wrote: > When we are not the real parent of the dst (e.g., when we're xfrm_dst > and the child is an rtentry), it may already be on the GC list. > > In fact the current code is buggy to, we need to check dst->flags > before the dec as dst may no longer be valid afterwards. > > Signed-off-by: Herbert Xu Good catch Herbert, I'll apply this.