Received: by 2002:a25:6193:0:0:0:0:0 with SMTP id v141csp1769738ybb; Thu, 26 Mar 2020 07:04:04 -0700 (PDT) X-Google-Smtp-Source: ADFU+vu+yFOnbykRhSqD4XHXAk6pISZ3giBP78pw5t/ghlw9ggIc9WdL+F/9a8PToM8e4Bmpe+YQ X-Received: by 2002:aca:3284:: with SMTP id y126mr81707oiy.175.1585231444372; Thu, 26 Mar 2020 07:04:04 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1585231444; cv=none; d=google.com; s=arc-20160816; b=Ic7Bv3+QeoN2HaZMcYtQOE6Riv6hXeWMUYKlBiLttgnIlpq1EcVHNYu+x20cgJGE54 FRqQxkzZO2izLiiDTdpQvHWwru07/yIvhsknzQqyO/LxvMxyNqWyv00Hb4bcZMNkGEwF duqJx78kLl5JRWjV2aypcccUfvaukKX0rbmNk2TLFkajuuDWaZAkTPfmsiumQw3BrM1v 8IzjNPUeBAQKF2VY/wiHBnk72AsWLfSF8O2sSMWShfwWKBbL3MedzcJan8Kuye9rvSjU X8CGRiewHHWlbXSUDCLAci/PxXVOVVVr40oDCb2A7hJc2Khe8M2ikcDf2AA55fzFUVPl TlbA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:in-reply-to:content-disposition :mime-version:references:mail-followup-to:message-id:subject:cc:to :from:date; bh=GeIyWY/wActIbhIbE7NVEw2wfceJ8b1KyQg3INlSTrQ=; b=UryxCZ0kG8fDWv0UD0VgJDgQ0zPxCx/oY1CGXsiMdx7cNb2L3wneauSRVJbcFrEdfZ eFCrr+GEsH3DaOe2oJ+8hY/fYOpI0h/PHfVmHlsmpgsmkplnsMJfnNJR2ZTyjktK28Vy y1c9Gtip4U0pQM7Nve12Ayj2Jo7LKT3b+XFYXUXn6CIqTAJk32S8hfQ6qHEM3nzRycsw Bi3qTs5teMYGqVaY0xpfKUC0/3/xA9htkFAhct8ESIVKPtPVCDijhYnot0qt0vqfhysR SSPpjLTyaCF/+wxO4MaJQJ4YtxEo0n66Vag8aEAhK1dIecmkiUXryiksdYmN+xRhWUsz fm6g== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=QUARANTINE sp=NONE dis=NONE) header.from=vmware.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id n25si1248133otk.255.2020.03.26.07.03.26; Thu, 26 Mar 2020 07:04:04 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=QUARANTINE sp=NONE dis=NONE) header.from=vmware.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727942AbgCZOCJ (ORCPT + 99 others); Thu, 26 Mar 2020 10:02:09 -0400 Received: from ex13-edg-ou-001.vmware.com ([208.91.0.189]:50722 "EHLO EX13-EDG-OU-001.vmware.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727920AbgCZOCH (ORCPT ); Thu, 26 Mar 2020 10:02:07 -0400 X-Greylist: delayed 904 seconds by postgrey-1.27 at vger.kernel.org; Thu, 26 Mar 2020 10:02:06 EDT Received: from sc9-mailhost3.vmware.com (10.113.161.73) by EX13-EDG-OU-001.vmware.com (10.113.208.155) with Microsoft SMTP Server id 15.0.1156.6; Thu, 26 Mar 2020 06:46:58 -0700 Received: from localhost (unknown [10.129.220.242]) by sc9-mailhost3.vmware.com (Postfix) with ESMTP id 3112B40CAD; Thu, 26 Mar 2020 06:47:02 -0700 (PDT) Date: Thu, 26 Mar 2020 06:47:01 -0700 From: Matt Helsley To: Nick Desaulniers CC: , , Mauro Carvalho Chehab , Jonathan Corbet , Wolfram Sang , Kamalesh Babulal , "Raphael Gault" , , Subject: Re: [PATCH] objtool: Documentation: document UACCESS warnings Message-ID: <20200326134701.GA118458@rlwimi.vmware.com> Mail-Followup-To: Matt Helsley , Nick Desaulniers , jpoimboe@redhat.com, peterz@infradead.org, Mauro Carvalho Chehab , Jonathan Corbet , Wolfram Sang , Kamalesh Babulal , Raphael Gault , linux-kernel@vger.kernel.org, clang-built-linux@googlegroups.com References: <20200323212538.GN2452@worktop.programming.kicks-ass.net> <20200324001321.39562-1-ndesaulniers@google.com> MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Disposition: inline In-Reply-To: <20200324001321.39562-1-ndesaulniers@google.com> Received-SPF: None (EX13-EDG-OU-001.vmware.com: mhelsley@vmware.com does not designate permitted sender hosts) Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Mon, Mar 23, 2020 at 05:13:20PM -0700, Nick Desaulniers wrote: > Compiling with Clang and CONFIG_KASAN=y was exposing a few warnings: > call to memset() with UACCESS enabled > > Document how to fix these for future travelers. > > Link: https://github.com/ClangBuiltLinux/linux/issues/876 > Suggested-by: Peter Zijlstra > Signed-off-by: Nick Desaulniers > --- > .../Documentation/stack-validation.txt | 20 +++++++++++++++++++ > 1 file changed, 20 insertions(+) > > diff --git a/tools/objtool/Documentation/stack-validation.txt b/tools/objtool/Documentation/stack-validation.txt > index de094670050b..156fee13ba02 100644 > --- a/tools/objtool/Documentation/stack-validation.txt > +++ b/tools/objtool/Documentation/stack-validation.txt > @@ -289,6 +289,26 @@ they mean, and suggestions for how to fix them. > might be corrupt due to a gcc bug. For more details, see: > https://gcc.gnu.org/bugzilla/show_bug.cgi?id=70646 > > +9. file.o: warning: objtool: funcA() call to funcB() with UACCESS enabled > + > + This means that an unexpected call to a non-whitelisted function exists > + outside of arch-specific guards. > + X86: SMAP (stac/clac): __uaccess_begin()/__uaccess_end() > + ARM: PAN: uaccess_enable()/uaccess_enable() I think you meant to put "disable" here ^^^^^^ Cheers, -Matt Helsley