Message ID | 20231115203401.2495875-16-iii@linux.ibm.com (mailing list archive) |
---|---|
State | New |
Headers | show
Return-Path: <owner-linux-mm@kvack.org> X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from kanga.kvack.org (kanga.kvack.org [205.233.56.17]) by smtp.lore.kernel.org (Postfix) with ESMTP id 7131FC2BB3F for <linux-mm@archiver.kernel.org>; Wed, 15 Nov 2023 21:04:41 +0000 (UTC) Received: by kanga.kvack.org (Postfix) id EC7036B03C0; Wed, 15 Nov 2023 16:04:40 -0500 (EST) Received: by kanga.kvack.org (Postfix, from userid 40) id E76DD6B03C1; Wed, 15 Nov 2023 16:04:40 -0500 (EST) X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id D17B26B03C2; Wed, 15 Nov 2023 16:04:40 -0500 (EST) X-Delivered-To: linux-mm@kvack.org Received: from relay.hostedemail.com (smtprelay0010.hostedemail.com [216.40.44.10]) by kanga.kvack.org (Postfix) with ESMTP id C49776B03C0 for <linux-mm@kvack.org>; Wed, 15 Nov 2023 16:04:40 -0500 (EST) Received: from smtpin07.hostedemail.com (a10.router.float.18 [10.200.18.1]) by unirelay05.hostedemail.com (Postfix) with ESMTP id 9E0C640AFE for <linux-mm@kvack.org>; Wed, 15 Nov 2023 21:04:40 +0000 (UTC) X-FDA: 81461417520.07.7DF6B94 Received: from mx0a-001b2d01.pphosted.com (mx0a-001b2d01.pphosted.com [148.163.156.1]) by imf06.hostedemail.com (Postfix) with ESMTP id 3DCDF180032 for <linux-mm@kvack.org>; Wed, 15 Nov 2023 21:04:37 +0000 (UTC) Authentication-Results: imf06.hostedemail.com; dkim=pass header.d=ibm.com header.s=pp1 header.b=L4vfRnZw; spf=pass (imf06.hostedemail.com: domain of iii@linux.ibm.com designates 148.163.156.1 as permitted sender) smtp.mailfrom=iii@linux.ibm.com; dmarc=pass (policy=none) header.from=ibm.com ARC-Seal: i=1; s=arc-20220608; d=hostedemail.com; t=1700082278; a=rsa-sha256; cv=none; b=GY7xyLCfLy0oA+4SuCkVMpmj4c7EL92gl00ODQRDHOXSCM74VReVpXLOVTmA1xunKjkNKn QgcuFrOmHPOJvhEojFMxpoKRpW6fh8VYJNskuN+6xiYJxGnlSo9Ga+47Q7xi90/thQ4M0V CumBfNM0Sb3FJytxNYoDzFepNlNyKDc= ARC-Authentication-Results: i=1; imf06.hostedemail.com; dkim=pass header.d=ibm.com header.s=pp1 header.b=L4vfRnZw; spf=pass (imf06.hostedemail.com: domain of iii@linux.ibm.com designates 148.163.156.1 as permitted sender) smtp.mailfrom=iii@linux.ibm.com; dmarc=pass (policy=none) header.from=ibm.com ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=hostedemail.com; s=arc-20220608; t=1700082278; h=from:from:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:cc:mime-version:mime-version: content-type:content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references:dkim-signature; bh=CdLKZ8qn4zwP446RCUpjk9jgcaOUrqtk3L/VG0jpav4=; b=fIeXTcJmW0QhcNsbkfGa0z6r/5cGYb7nuiTj4EgG0nGRbu6WP1y8q+gLrBSbQp71x4N48e Ref5R1pyygLF6AeNFQ2Qwf1aWNKiqjuP7X0bQ/Gben5IuAzMG2iziGHR+RwLPvs58CKqau LUwBiAAxfwcKkTA9Lf8cSuNislgP9us= Received: from pps.filterd (m0353726.ppops.net [127.0.0.1]) by mx0a-001b2d01.pphosted.com (8.17.1.19/8.17.1.19) with ESMTP id 3AFKCEZD020041; Wed, 15 Nov 2023 20:34:40 GMT DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=ibm.com; h=from : to : cc : subject : date : message-id : in-reply-to : references : mime-version : content-transfer-encoding; s=pp1; bh=CdLKZ8qn4zwP446RCUpjk9jgcaOUrqtk3L/VG0jpav4=; b=L4vfRnZw+uGxcpOsqqjyq5CRN5624Kzp2tNN8n4PxBcJ/OAfJ841PgRUGX2S6CtWH6iX TOzamQWSIylWufoTf4R348IeH9/fLgWdt6BnH6Rke8ieYwA0wDY2q2iTQDn5QkxXPzop 1RKGcNey8ZSXARkJEXjgkTTPVr/cvTNAm9J2lV+EJZEDJ7egUr1K7S/a5aNgC+S+Mop4 7cWNldlkSe1URRejUSF/DlPIl4rPL7iFsqHrr04DJZ03BdVNTr+g4lceMePlcPn2ztBR k9JKwUmbCsRVqVK0/B9H9NsUSKmZjtinmipZ3/8Ap64vTAwc0xw39sVO/5GraNnv43su lg== Received: from pps.reinject (localhost [127.0.0.1]) by mx0a-001b2d01.pphosted.com (PPS) with ESMTPS id 3ud4thgk2y-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT); Wed, 15 Nov 2023 20:34:39 +0000 Received: from m0353726.ppops.net (m0353726.ppops.net [127.0.0.1]) by pps.reinject (8.17.1.5/8.17.1.5) with ESMTP id 3AFKCZk7021216; Wed, 15 Nov 2023 20:34:39 GMT Received: from ppma22.wdc07v.mail.ibm.com (5c.69.3da9.ip4.static.sl-reverse.com [169.61.105.92]) by mx0a-001b2d01.pphosted.com (PPS) with ESMTPS id 3ud4thgk2h-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT); Wed, 15 Nov 2023 20:34:39 +0000 Received: from pps.filterd (ppma22.wdc07v.mail.ibm.com [127.0.0.1]) by ppma22.wdc07v.mail.ibm.com (8.17.1.19/8.17.1.19) with ESMTP id 3AFKJ36R017548; Wed, 15 Nov 2023 20:34:37 GMT Received: from smtprelay06.fra02v.mail.ibm.com ([9.218.2.230]) by ppma22.wdc07v.mail.ibm.com (PPS) with ESMTPS id 3uamayj7ae-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT); Wed, 15 Nov 2023 20:34:37 +0000 Received: from smtpav01.fra02v.mail.ibm.com (smtpav01.fra02v.mail.ibm.com [10.20.54.100]) by smtprelay06.fra02v.mail.ibm.com (8.14.9/8.14.9/NCO v10.0) with ESMTP id 3AFKYYHx44434164 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK); Wed, 15 Nov 2023 20:34:34 GMT Received: from smtpav01.fra02v.mail.ibm.com (unknown [127.0.0.1]) by IMSVA (Postfix) with ESMTP id 415CC20043; Wed, 15 Nov 2023 20:34:34 +0000 (GMT) Received: from smtpav01.fra02v.mail.ibm.com (unknown [127.0.0.1]) by IMSVA (Postfix) with ESMTP id EC1D520040; Wed, 15 Nov 2023 20:34:32 +0000 (GMT) Received: from heavy.boeblingen.de.ibm.com (unknown [9.179.9.51]) by smtpav01.fra02v.mail.ibm.com (Postfix) with ESMTP; Wed, 15 Nov 2023 20:34:32 +0000 (GMT) From: Ilya Leoshkevich <iii@linux.ibm.com> To: Alexander Gordeev <agordeev@linux.ibm.com>, Alexander Potapenko <glider@google.com>, Andrew Morton <akpm@linux-foundation.org>, Christoph Lameter <cl@linux.com>, David Rientjes <rientjes@google.com>, Joonsoo Kim <iamjoonsoo.kim@lge.com>, Marco Elver <elver@google.com>, Masami Hiramatsu <mhiramat@kernel.org>, Pekka Enberg <penberg@kernel.org>, Steven Rostedt <rostedt@goodmis.org>, Vasily Gorbik <gor@linux.ibm.com>, Vlastimil Babka <vbabka@suse.cz> Cc: Christian Borntraeger <borntraeger@linux.ibm.com>, Dmitry Vyukov <dvyukov@google.com>, Hyeonggon Yoo <42.hyeyoo@gmail.com>, kasan-dev@googlegroups.com, linux-kernel@vger.kernel.org, linux-mm@kvack.org, linux-s390@vger.kernel.org, linux-trace-kernel@vger.kernel.org, Mark Rutland <mark.rutland@arm.com>, Roman Gushchin <roman.gushchin@linux.dev>, Sven Schnelle <svens@linux.ibm.com>, Ilya Leoshkevich <iii@linux.ibm.com> Subject: [PATCH 15/32] mm: slub: Let KMSAN access metadata Date: Wed, 15 Nov 2023 21:30:47 +0100 Message-ID: <20231115203401.2495875-16-iii@linux.ibm.com> X-Mailer: git-send-email 2.41.0 In-Reply-To: <20231115203401.2495875-1-iii@linux.ibm.com> References: <20231115203401.2495875-1-iii@linux.ibm.com> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-TM-AS-GCONF: 00 X-Proofpoint-GUID: CXyK3LQ24vo0EH6joaIYozyRUtTOEyS8 X-Proofpoint-ORIG-GUID: qdS6d-wEuyX6_5mdxK25IrNeVjaBw2Cq X-Proofpoint-Virus-Version: vendor=baseguard engine=ICAP:2.0.272,Aquarius:18.0.987,Hydra:6.0.619,FMLib:17.11.176.26 definitions=2023-11-15_20,2023-11-15_01,2023-05-22_02 X-Proofpoint-Spam-Details: rule=outbound_notspam policy=outbound score=0 malwarescore=0 impostorscore=0 lowpriorityscore=0 phishscore=0 suspectscore=0 adultscore=0 priorityscore=1501 mlxscore=0 mlxlogscore=999 clxscore=1015 spamscore=0 bulkscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.12.0-2311060000 definitions=main-2311150163 X-Rspamd-Server: rspam08 X-Rspamd-Queue-Id: 3DCDF180032 X-Stat-Signature: 7af4xgeppodjo7zjr87ziikot9bc67ut X-Rspam-User: X-HE-Tag: 1700082277-686757 X-HE-Meta: U2FsdGVkX18DLO7P99yC74RFN2wYUSH+Ib7sXoOOwHycALlQVvr4zFCTZAnF1nwimlReti5VQdXlsf+clGjjYVFwDyi5KhSKl0GjZoUV2kJWRtsxg4oTvkGrd5XhWoqcFJHKiPWHerZeHXBollcD5RLdaIyoYD2yYtPI7cyPf3+ZVUYOM64J9HVwB+UrfyonjtwLbaThMJIApKhMLC8YtTtcAPU9+EvBAsKN3H7haMseXQ54kQwH8ImUj/0wiSoYwP+0ZJbmeSDAoh6hBrYo5ExjMbNxIEcp2/8FrgP6HaENripjTYKOp0YA4OEih3Q7JYiRNQQfCzTCR978RjGqv8/DRxSYcaBauhXM5qck8J/ENwLnjFC4KXOX2fgulGb+7bkm0C44c1+XhUUMbtz+GCXiYy/0gTMIjj0yHlCSoB4ll1/f2iBKUUj1bcizq4Q8f9UX+4NSXEmhH6PWV+FbM9uW1l9dwwnnpfHMQC/cG1oZqJ5pYa5EgIZ73VpF7LkkNYiYaeyfrYPKv2hRM23WCq9ial6gbSZTmH72HttPntdLwDOWcBfHIMeMrkoycVGtXC5FbqP1pTzxBnZY/wYf6cUU79GTZDfMAp1HnB2oquPpWmKpL8N8+0lcuwwebnTgsdOFK11vK5M/SRyB0smgF86Kc8YV4J8GekshvaBcmBD5SklbLixKnJxmEGwlNtef0/P2mnJuY7DnzYcDCao+/pB42NuI3e0TmZLeymaBBJNAdhSXXI2cgByLWvIQYMMbOSQShbcQ01EIEiwqEkIWm/2tnPrBN7pMQj5qLF7JXPzrA23xhDzBR3V3Eqm95LLv/sb+Q5A9AIB3oETBM2cMKptvAcao+f9esJG637vVwIA+Zm9vPNbN+OwiCFwMmTkcajzI7EkEUvaiXL/6tJO/6yAb7xY7r0n4gJUNoBNtkxAU11h19Buhr2BlKDWkZvjKKJFW7V/jUy8L5vFi+vw kncUb0ya TOd2hwIr7LZTnv5zrYaUGA31C/rbCmAQhvPxOjUu76B5CbLqFWxWD22K1kUfTb4Ls/4YYT2ftlPV/6qhZ/C7kHwai+7a4h6M8TQu3cCWmem0mSZEPVZQoC6DBAtOdlTFQDgd66F4kO/DPdxsvgoMr+iPvfqEXxiZ2PZdQLLdIOQeYeW628lpxwnrxRQu9GGdRQtucK4lASh4UM2Jzp/7rFlP44Q== X-Bogosity: Ham, tests=bogofilter, spamicity=0.000006, version=1.2.4 Sender: owner-linux-mm@kvack.org Precedence: bulk X-Loop: owner-majordomo@kvack.org List-ID: <linux-mm.kvack.org> List-Subscribe: <mailto:majordomo@kvack.org> List-Unsubscribe: <mailto:majordomo@kvack.org> |
Series |
kmsan: Enable on s390
|
expand
|
diff --git a/mm/slub.c b/mm/slub.c index 8d9aa4d7cb7e..0b52bff99326 100644 --- a/mm/slub.c +++ b/mm/slub.c @@ -700,10 +700,12 @@ static int disable_higher_order_debug; static inline void metadata_access_enable(void) { kasan_disable_current(); + kmsan_disable_current(); } static inline void metadata_access_disable(void) { + kmsan_enable_current(); kasan_enable_current(); }
Building the kernel with CONFIG_SLUB_DEBUG and CONFIG_KMSAN causes KMSAN to complain about touching redzones in kfree(). Fix by extending the existing KASAN-related metadata_access_enable() and metadata_access_disable() functions to KMSAN. Signed-off-by: Ilya Leoshkevich <iii@linux.ibm.com> --- mm/slub.c | 2 ++ 1 file changed, 2 insertions(+)