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 for Android: free password hash cracker in your pocket
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date:	Thu, 13 Mar 2014 13:56:43 -0700
From:	Eric Dumazet <eric.dumazet@...il.com>
To:	paulmck@...ux.vnet.ibm.com
Cc:	John Fastabend <john.fastabend@...il.com>,
	xiyou.wangcong@...il.com, jhs@...atatu.com, netdev@...r.kernel.org,
	davem@...emloft.net
Subject: Re: [RCU PATCH 06/14] net: sched: fw use RCU

On Thu, 2014-03-13 at 13:22 -0700, Paul E. McKenney wrote:

> Hmmm...  You know, the offset that kfree uses is a byte offset.  I see
> no reason why any of the rcu_head structures should be misaligned.  If
> HTSIZE is too big by only a factor of four or smaller, would the following
> (untested) patch to RCU be appropriate?
> 
> 							Thanx, Paul
> 
> ------------------------------------------------------------------------
> 
> rcu: Increase kfree_rcu() offset range
> 
> The kfree_rcu() function operates by placing an offset into the rcu_head
> structure in place of the function pointer that is normally there.
> This offset cannot exceed 4095, on the theory that no Linux kernel will
> ever have executable code in page zero.  However, the rcu_head structure
> contains a pair of function pointers, and should never be misaligned.
> This commit therefore divides the offset by the size of a pointer when
> being placed into the rcu_head structure, and multiplies it by this
> same constant when pulling it out.
> 
> Signed-off-by: Paul E. McKenney <paulmck@...ux.vnet.ibm.com>

SGTM, thanks Paul.

Reviewed-by: Eric Dumazet <edumzzet@...gle.com>


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