From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 462BDC433FE for ; Wed, 30 Nov 2022 05:40:56 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S233475AbiK3Fky (ORCPT ); Wed, 30 Nov 2022 00:40:54 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:45154 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229648AbiK3Fkt (ORCPT ); Wed, 30 Nov 2022 00:40:49 -0500 Received: from ams.source.kernel.org (ams.source.kernel.org [IPv6:2604:1380:4601:e00::1]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 9E6FC3FB97 for ; Tue, 29 Nov 2022 21:40:47 -0800 (PST) Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ams.source.kernel.org (Postfix) with ESMTPS id 3E9DAB81A32 for ; Wed, 30 Nov 2022 05:40:46 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id AA106C433C1; Wed, 30 Nov 2022 05:40:44 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1669786844; bh=cGYM4HbWASBVByr69I639VWeErhXmhz0z9ewvew8r7c=; h=Date:From:To:Cc:Subject:References:In-Reply-To:From; b=hgIb9wZHfv69M9YpnGkCZ1SyfCo1JvTo2zk+8c1Mn2mzni7anbYmDHpefoYsaAhTU bLg5EMbL2poeol4T0EHUlRqyN9YFp3C61yCA200vKUqQeUhuGpPbVE3B5vBRM35wBG RCzoXevGmHQKZr1UqsQ9mSaG9SktpU/IKT5qRiNZ+s6SKUjS2nP+yXAbEJirq2MsaO FvwegJuzfvsT/Woutj3zyA1xP2Ebz3CWWky8ujNLQ4VFTmmbjeLDRZKtz2Am/xZK+p 19B4CNNLwewWxQUgTN76k/CTqHJyhB33jgG7j1G4mBDVf/mz4CdbtQd/QzMpmJ53gu mpsUnjW8PkkFA== Date: Tue, 29 Nov 2022 21:40:42 -0800 From: Eric Biggers To: Alexander Potapenko Cc: tglx@linutronix.de, mingo@redhat.com, bp@alien8.de, dave.hansen@linux.intel.com, x86@kernel.org, linux-kernel@vger.kernel.org Subject: Re: [PATCH] x86: suppress KMSAN reports in arch_within_stack_frames() Message-ID: References: <20221118172305.3321253-1-glider@google.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20221118172305.3321253-1-glider@google.com> Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Fri, Nov 18, 2022 at 06:23:05PM +0100, Alexander Potapenko wrote: > arch_within_stack_frames() performs stack walking and may confuse > KMSAN by stepping on stale shadow values. To prevent false positive > reports, disable KMSAN checks in this function. > > This fixes KMSAN's interoperability with CONFIG_HARDENED_USERCOPY. > > Link: https://github.com/google/kmsan/issues/89 > Link: https://lore.kernel.org/lkml/Y3b9AAEKp2Vr3e6O@sol.localdomain/ > Cc: Eric Biggers > Signed-off-by: Alexander Potapenko > --- > arch/x86/include/asm/thread_info.h | 5 +++++ > 1 file changed, 5 insertions(+) Tested-by: Eric Biggers - Eric