lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <1341353309.2839.19.camel@bwh-desktop.uk.solarflarecom.com>
Date:	Tue, 3 Jul 2012 23:08:29 +0100
From:	Ben Hutchings <bhutchings@...arflare.com>
To:	David Miller <davem@...emloft.net>
CC:	<netdev@...r.kernel.org>
Subject: Re: [PATCH 12/19] neigh: Convert over to dst_neigh_lookup_skb().

On Tue, 2012-07-03 at 02:46 -0700, David Miller wrote:
> Signed-off-by: David S. Miller <davem@...emloft.net>
> ---
>  net/core/neighbour.c |   10 ++++++++--
>  1 file changed, 8 insertions(+), 2 deletions(-)
> 
> diff --git a/net/core/neighbour.c b/net/core/neighbour.c
> index a793af9..eb3efdc 100644
> --- a/net/core/neighbour.c
> +++ b/net/core/neighbour.c
> @@ -1202,9 +1202,15 @@ int neigh_update(struct neighbour *neigh, const u8 *lladdr, u8 new,
>  
>  			rcu_read_lock();
>  			/* On shaper/eql skb->dst->neighbour != neigh :( */

It might be time to delete that comment too.

Ben.

> -			if (dst && (n2 = dst_get_neighbour_noref(dst)) != NULL)
> -				n1 = n2;
> +			n2 = NULL;
> +			if (dst) {
> +				n2 = dst_neigh_lookup_skb(dst, skb);
> +				if (n2)
> +					n1 = n2;
> +			}
>  			n1->output(n1, skb);
> +			if (n2)
> +				neigh_release(n2);
>  			rcu_read_unlock();
>  
>  			write_lock_bh(&neigh->lock);

-- 
Ben Hutchings, Staff Engineer, Solarflare
Not speaking for my employer; that's the marketing department's job.
They asked us to note that Solarflare product names are trademarked.

--
To unsubscribe from this list: send the line "unsubscribe netdev" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ