From nobody Tue Apr 7 18:04:07 2026 Received: from smtpbg151.qq.com (smtpbg151.qq.com [18.169.211.239]) (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 7601A1A3164 for ; Thu, 12 Mar 2026 05:38:38 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=18.169.211.239 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1773293927; cv=none; b=iLF780hc4oMNaJmEtNCE0ps9jyyt1IAqEIa8qZhHNrrUGoBdCAMaokiE0UzgiCzWBLbpzP2XoDsQybzouENyB2nHEoBlTJKxrAUNoNYelQVdR8GwffTIMQAVmCacUGVmhOnckd/GOcdElep36S1nXkFEvvdAOmjosVgPGYBKi+0= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1773293927; c=relaxed/simple; bh=HyuXPAauMCNTKQGHtOCvWnGbllacfmkXgFtQjdZ0+aA=; h=From:To:Cc:Subject:Date:Message-Id:MIME-Version; b=K3jfiLlOMR3vLELIOUHXgzGmBB1VYAa+fjZJqTZAnZZa/yHcB74vFHD2eGwE+woBp5OhYFbkQb3ANT+qeye0LvQM3byTMdyK3HEDZeFLzSb/kr/6zWofeoITZWEzKlTLuoiMjSYDkPA7W2+H0MOLzzMEFKJ4XGIPYIySqfTnVNk= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=reject dis=none) header.from=smail.nju.edu.cn; spf=pass smtp.mailfrom=smail.nju.edu.cn; dkim=pass (1024-bit key) header.d=smail.nju.edu.cn header.i=@smail.nju.edu.cn header.b=GGWSwl7h; arc=none smtp.client-ip=18.169.211.239 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=reject dis=none) header.from=smail.nju.edu.cn Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=smail.nju.edu.cn Authentication-Results: smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=smail.nju.edu.cn header.i=@smail.nju.edu.cn header.b="GGWSwl7h" DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=smail.nju.edu.cn; s=iohv2404; t=1773293910; bh=S7zqxscsZyZh7mgw0/pnqA4Yu1cOAV4wQEkNTVFKvhM=; h=From:To:Subject:Date:Message-Id:MIME-Version; b=GGWSwl7hNAAUVUgkqNdrSI7PhVnElGFLStvLd9L2vhia0oLdNhQQw/Jn4BKFaaXFU hZAD1aNArWf02nNfRWkjNRJh07WzVRRPQtlPV5HS6BL27uoK9mJjoRF4Gtc9NPtgfq GYPw7R6CsoAn9I8HTJ6bNMZl+h9s9ZFzTTVF90U4= X-QQ-mid: zesmtpsz8t1773293899t228bcc05 X-QQ-Originating-IP: etJ1NdoKLHmWJnKVzDXJD8fcm0xhyvAd0lKeIEq+uGk= Received: from localhost.localdomain ( [116.172.93.199]) by bizesmtp.qq.com (ESMTP) with id ; Thu, 12 Mar 2026 13:38:17 +0800 (CST) X-QQ-SSF: 0000000000000000000000000000000 X-QQ-GoodBg: 1 X-BIZMAIL-ID: 1308595872313830691 EX-QQ-RecipientCnt: 12 From: Kexin Sun To: ryabinin.a.a@gmail.com, kasan-dev@googlegroups.com Cc: glider@google.com, andreyknvl@gmail.com, dvyukov@google.com, vincenzo.frascino@arm.com, linux-kernel@vger.kernel.org, julia.lawall@inria.fr, xutong.ma@inria.fr, yunbolyu@smu.edu.sg, ratnadiraw@smu.edu.sg, Kexin Sun Subject: [PATCH v2] kasan: update outdated comment Date: Thu, 12 Mar 2026 13:38:12 +0800 Message-Id: <20260312053812.1365-1-kexinsun@smail.nju.edu.cn> X-Mailer: git-send-email 2.25.1 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 X-QQ-SENDSIZE: 520 Feedback-ID: zesmtpsz:smail.nju.edu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walXQsuggVsb7ERlsFdtDlTIDAwLpn5ke QmAnQfOUKKOH/e8QjzcH01EwsasxQ8Gm3frt/r43loB+BPzJu+jQoKLk/F1glG0yneGNsDN AhA2GvVI2dUZr4YjkigNiOPVZKNC0iOi3uxXYYuWjPM X-QQ-XMRINFO: MSVp+SPm3vtSI1QTLgDHQqIV1w2oNKDqfg== X-QQ-RECHKSPAM: 0 Content-Type: text/plain; charset="utf-8" The function kmalloc_large() was renamed kmalloc_large_noprof() by commit 7bd230a26648 ("mm/slab: enable slab allocation tagging for kmalloc and friends"), and subsequently renamed __kmalloc_large_noprof() by commit a0a44d9175b3 ("mm, slab: don't wrap internal functions with alloc_hooks()"), making it an internal implementation detail. Large kmalloc allocations are now performed through the public kmalloc() interface directly, making the reference to KMALLOC_MAX_SIZE also stale (KMALLOC_MAX_CACHE_SIZE would be more accurate). Remove the references to kmalloc_large() and KMALLOC_MAX_SIZE, and rephrase the description for large kmalloc allocations. Suggested-by: Andrey Ryabinin Assisted-by: unnamed:deepseek-v3.2 coccinelle Signed-off-by: Kexin Sun Reviewed-by: Andrey Ryabinin --- include/linux/kasan.h | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/include/linux/kasan.h b/include/linux/kasan.h index 338a1921a50a..bf233bde68c7 100644 --- a/include/linux/kasan.h +++ b/include/linux/kasan.h @@ -352,8 +352,8 @@ bool __kasan_mempool_poison_object(void *ptr, unsigned = long ip); * kasan_mempool_unpoison_object(). * * This function operates on all slab allocations including large kmalloc - * allocations (the ones returned by kmalloc_large() or by kmalloc() with = the - * size > KMALLOC_MAX_SIZE). + * allocations (i.e. the ones backed directly by the buddy allocator rather + * than kmalloc slab caches). * * Return: true if the allocation can be safely reused; false otherwise. */ @@ -381,8 +381,8 @@ void __kasan_mempool_unpoison_object(void *ptr, size_t = size, unsigned long ip); * original tags based on the pointer value. * * This function operates on all slab allocations including large kmalloc - * allocations (the ones returned by kmalloc_large() or by kmalloc() with = the - * size > KMALLOC_MAX_SIZE). + * allocations (i.e. the ones backed directly by the buddy allocator rather + * than kmalloc slab caches). */ static __always_inline void kasan_mempool_unpoison_object(void *ptr, size_t size) --=20 2.25.1