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  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]
Date:	Sat, 20 Feb 2010 05:07:30 +0100
From:	Eric Dumazet <eric.dumazet@...il.com>
To:	Stephen Hemminger <shemminger@...tta.com>
Cc:	Alexander Viro <viro@...iv.linux.org.uk>,
	Andrew Morton <akpm@...ux-foundation.org>,
	Rusty Russell <rusty@...tcorp.com.au>,
	Peter Oberparleiter <oberpar@...ux.vnet.ibm.com>,
	Miklos Szeredi <mszeredi@...e.cz>,
	"Paul E. McKenney" <paulmck@...ux.vnet.ibm.com>,
	"David S. Miller" <davem@...emloft.net>,
	Jiri Pirko <jpirko@...hat.com>, Jiri Olsa <jolsa@...hat.com>,
	Ingo Molnar <mingo@...e.hu>,
	Alexey Dobriyan <adobriyan@...il.com>,
	Jamal Hadi Salim <hadi@...erus.ca>,
	Neil Horman <nhorman@...driver.com>, netdev@...r.kernel.org
Subject: Re: [PATCH 3/3] af_key: locking change

Le vendredi 19 février 2010 à 13:59 -0800, Stephen Hemminger a écrit :
> pièce jointe document texte brut (pfkey-rcu.patch)
> Get rid of custom locking that was using wait queue, lock, and atomic
> to basically build a queued mutex.  Use RCU for read side.
> 
> Signed-off-by: Stephen Hemminger <shemminger@...tta.com>

Excellent

Acked-by: Eric Dumazet <eric.dumazet@...il.com>

I dont know why you used synchronize_sched() instead of
synchronize_rcu().

I prefer _rcu() variant because its all about rcu after all, and fact it
is mapped to synchronize_sched() is an implementation detail.

(I am not saying implementation doesnt matter, Paul :) )

>  }
>  
>  static struct proto key_proto = {
> @@ -223,6 +177,7 @@ static int pfkey_release(struct socket *
>  	sock_orphan(sk);
>  	sock->sk = NULL;
>  	skb_queue_purge(&sk->sk_write_queue);
> +	synchronize_sched();
>  	sock_put(sk);
>  
>  	return 0;


--
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