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: <aYrsR5VYH9JHeIoZ@macos>
Date: Tue, 10 Feb 2026 17:49:17 +0100
From: Daniel Gomez <da.gomez@...nel.org>
To: Andreas Hindborg <a.hindborg@...nel.org>
Cc: Tamir Duberstein <tamird@...il.com>, Miguel Ojeda <ojeda@...nel.org>, 
	Alex Gaynor <alex.gaynor@...il.com>, Boqun Feng <boqun.feng@...il.com>, Gary Guo <gary@...yguo.net>, 
	Björn Roy Baron <bjorn3_gh@...tonmail.com>, Benno Lossin <lossin@...nel.org>, 
	Alice Ryhl <aliceryhl@...gle.com>, Trevor Gross <tmgross@...ch.edu>, 
	Danilo Krummrich <dakr@...nel.org>, Lorenzo Stoakes <lorenzo.stoakes@...cle.com>, 
	"Liam R. Howlett" <Liam.Howlett@...cle.com>, Vlastimil Babka <vbabka@...e.cz>, 
	Andrew Morton <akpm@...ux-foundation.org>, Christoph Lameter <cl@...two.org>, 
	David Rientjes <rientjes@...gle.com>, Roman Gushchin <roman.gushchin@...ux.dev>, 
	Harry Yoo <harry.yoo@...cle.com>, rust-for-linux@...r.kernel.org, linux-kernel@...r.kernel.org, 
	linux-mm@...ck.org, "Matthew Wilcox (Oracle)" <willy@...radead.org>
Subject: Re: [PATCH v3 11/12] xarray, radix-tree: enable sheaf support for
 kmem_cache

On 2026-02-09 15:38, Andreas Hindborg wrote:
> The rust null block driver plans to rely on preloading xarray nodes from
> the radix_tree_node_cachep kmem_cache.
> 
> Cc: "Matthew Wilcox (Oracle)" <willy@...radead.org>
> Signed-off-by: Andreas Hindborg <a.hindborg@...nel.org>
> ---
>  lib/radix-tree.c | 14 ++++++++++----
>  1 file changed, 10 insertions(+), 4 deletions(-)
> 
> diff --git a/lib/radix-tree.c b/lib/radix-tree.c
> index 976b9bd02a1b5..1cf0012b15ade 100644
> --- a/lib/radix-tree.c
> +++ b/lib/radix-tree.c
> @@ -1598,10 +1598,16 @@ void __init radix_tree_init(void)
>  	BUILD_BUG_ON(RADIX_TREE_MAX_TAGS + __GFP_BITS_SHIFT > 32);
>  	BUILD_BUG_ON(ROOT_IS_IDR & ~GFP_ZONEMASK);
>  	BUILD_BUG_ON(XA_CHUNK_SIZE > 255);
> -	radix_tree_node_cachep = kmem_cache_create("radix_tree_node",
> -			sizeof(struct radix_tree_node), 0,
> -			SLAB_PANIC | SLAB_RECLAIM_ACCOUNT,
> -			radix_tree_node_ctor);
> +
> +	struct kmem_cache_args args = {
> +		.ctor = radix_tree_node_ctor,
> +		.sheaf_capacity = 64,
> +	};

Is the sheaf_capacity matching the number of slots in an XArray node? If so,
this should be bindings::XA_CHUNK_SIZE.

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ