From nobody Mon Feb 9 20:30:16 2026 Received: from zeniv.linux.org.uk (zeniv.linux.org.uk [62.89.141.173]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 63C6A1E5B95; Sat, 10 Jan 2026 04:01:00 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=62.89.141.173 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1768017665; cv=none; b=epO55RM8p/PGZQc8fwlw5ml1Yz5y+5f1ZwtbhMfYQyTpS9I3yez2fTgKa3a4bagMGnq8OwZbiQ1cpXd48e4FqcelikzGCwGnvHAGMok7QnOJIMtyP5ff4SDxEPWH2jBc9uhrnInC+z47BWMAjmZdtNH58xFjJEl3iwL+HTD7uYo= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1768017665; c=relaxed/simple; bh=1EBxgGRCUwO9vaV3rC9PJKIwxsWCiMe5NYVBWFnMIbo=; h=From:To:Cc:Subject:Date:Message-ID:In-Reply-To:References: MIME-Version; b=Xpi83ge56fLSqk0XmxlcVgNQi765VYgtfcsxIQSC6+N+7lF//yaFzbDGQhBNf1DRVN2FK9nZrp05HpKYlZhtsLeVgt8l9Z+IE0lu007qHm3eglq9ZrF5CItSyu6ovsqLj2Olzu3O1BIKGmTfsqXBy5nkauZhDEpV72O5nyxQguE= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=zeniv.linux.org.uk; spf=none smtp.mailfrom=ftp.linux.org.uk; dkim=pass (2048-bit key) header.d=linux.org.uk header.i=@linux.org.uk header.b=f7gmULfr; arc=none smtp.client-ip=62.89.141.173 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=zeniv.linux.org.uk Authentication-Results: smtp.subspace.kernel.org; spf=none smtp.mailfrom=ftp.linux.org.uk Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=linux.org.uk header.i=@linux.org.uk header.b="f7gmULfr" DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=linux.org.uk; s=zeniv-20220401; h=Sender:Content-Transfer-Encoding: MIME-Version:References:In-Reply-To:Message-ID:Date:Subject:Cc:To:From: Reply-To:Content-Type:Content-ID:Content-Description; bh=l2LUE689TUBjRJhqWoI4FSTJJqCMuaDthYKZkiYtSho=; b=f7gmULfr1QczamnpQvpHORoB4Y cZlsW62CiHl2hZNjtSkrAMYnzAg+3ee4NzKQD0cwRhquSK8F9gIfJ55AnPDVTVn9irnM/Z4tVByIo mNFfBFW/wtmlpUsXUkMbOAMkVaYS+Plk/C56B9IAwv6/tGEwb/U8D4KAW4Rmy84/s1u/9SnOxy/Yg OW32w/DQT73dGjLsm4GxcsQqJZJEflD08QiKHs0aH4w1/hmnRzseN7XuTSLbTjuX3oWpFMtUSiJhS xuXBl4Li9Uu6V4rIOFZ2+yJcSbT9wwml/ntSivby0LL+rtss9AuCL2xRHuodRJy6wp38eRtGM5k4a Qj0W5Xpw==; Received: from viro by zeniv.linux.org.uk with local (Exim 4.99 #2 (Red Hat Linux)) id 1veQB9-000000085aJ-2fZG; Sat, 10 Jan 2026 04:02:19 +0000 From: Al Viro To: linux-mm@kvack.org Cc: Vlastimil Babka , Harry Yoo , linux-fsdevel@vger.kernel.org, Linus Torvalds , Christian Brauner , Jan Kara , Mateusz Guzik , linux-kernel@vger.kernel.org Subject: [RFC PATCH 12/15] turn task_struct_cachep static-duration Date: Sat, 10 Jan 2026 04:02:14 +0000 Message-ID: <20260110040217.1927971-13-viro@zeniv.linux.org.uk> X-Mailer: git-send-email 2.52.0 In-Reply-To: <20260110040217.1927971-1-viro@zeniv.linux.org.uk> References: <20260110040217.1927971-1-viro@zeniv.linux.org.uk> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Sender: Al Viro Content-Type: text/plain; charset="utf-8" Signed-off-by: Al Viro --- kernel/fork.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/kernel/fork.c b/kernel/fork.c index f83ca2f5826f..8f0dfefd82f0 100644 --- a/kernel/fork.c +++ b/kernel/fork.c @@ -178,7 +178,8 @@ void __weak arch_release_task_struct(struct task_struct= *tsk) { } =20 -static struct kmem_cache *task_struct_cachep; +static struct kmem_cache_opaque task_struct_cache; +#define task_struct_cachep to_kmem_cache(&task_struct_cache) =20 static inline struct task_struct *alloc_task_struct_node(int node) { @@ -860,7 +861,7 @@ void __init fork_init(void) =20 /* create a slab on which task_structs can be allocated */ task_struct_whitelist(&useroffset, &usersize); - task_struct_cachep =3D kmem_cache_create_usercopy("task_struct", + kmem_cache_setup_usercopy(task_struct_cachep, "task_struct", arch_task_struct_size, align, SLAB_PANIC|SLAB_ACCOUNT, useroffset, usersize, NULL); --=20 2.47.3