Received: by 2002:a25:d7c1:0:0:0:0:0 with SMTP id o184csp3549330ybg; Mon, 28 Oct 2019 14:47:14 -0700 (PDT) X-Google-Smtp-Source: APXvYqzgtfZBd657Tr5L0fwCkZkrQX34iIzNjVGFpntlAzgUcY9iVX6lR+X55iMXZvlgAV8o3nHA X-Received: by 2002:a05:6402:2c5:: with SMTP id b5mr22150561edx.157.1572299233868; Mon, 28 Oct 2019 14:47:13 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1572299233; cv=none; d=google.com; s=arc-20160816; b=oLgMo7k9fCjw0F7ChIYQOXvefGYwQQMl79HqWNfer5xFuUgdFadGf528J4varRTct2 akR+aO5dl4dw2EI45Zauh3ZE+vJFFM1agzL6J3BZIAsgan6kFMi4+rILdF7oHFRyOmzG F8Q77f4bKPhR9j0JXRff7Uq+F3m3iVNlPL33f5/lSOO7Ey7yf54XWAb/3uJ6pWOB93Z3 T6M2/nG8G5pDe5lUN0+fPUpLl15xCmZjRDEtF3XQ0yve8rSeiSRjS/GnczBUZQSSsnmz iMB4fBN0NVpmYD+gfwfduH3sWITnLcNm2TNwO59R781+gXpb8tMOE/RlotJfK275X4X0 toXg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding:mime-version :user-agent:references:in-reply-to:date:cc:to:from:subject :message-id; bh=kLFxOFqdpfD97DffmBLVTqLbSi9LJhONTmJfTcEaTKg=; b=lIlcVpkNn0v1dVONMjK7AiiTYk7QquPawXfByt0lSS1ZN6Hb2pSYklIP4sMY7ylJ8r 6YeCvP5gMftceO8jSTM3Mzi+U/6qgLL1XfI/YgP9TQGUYzk/uV08RdzLd0bYyKJD0Gmv 9vT5RcNdKp4eUMm6QuHdmKpVQrFLzigBf/0PCtZx4MjBLvVGPPFcFGu6kblNL+rEUaxY RzPBkpInmF9c43lIdNY3UXrGLIsufRpehJEBfz6okzR2L+HAYn6zK0gElzNqulZjodeL lfbBwITWZLD8QsLTc56cY5dUjRxbyxrRNFk185hU7kzgXB2Rpa5n+hPLrVwbs1hz6CkC b3lg== 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 Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id z33si7465956edz.114.2019.10.28.14.46.49; Mon, 28 Oct 2019 14:47:13 -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 Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1732058AbfJ1R74 (ORCPT + 99 others); Mon, 28 Oct 2019 13:59:56 -0400 Received: from smtprelay0173.hostedemail.com ([216.40.44.173]:44184 "EHLO smtprelay.hostedemail.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1729738AbfJ1R74 (ORCPT ); Mon, 28 Oct 2019 13:59:56 -0400 Received: from filter.hostedemail.com (clb03-v110.bra.tucows.net [216.40.38.60]) by smtprelay02.hostedemail.com (Postfix) with ESMTP id 559525DD5; Mon, 28 Oct 2019 17:59:54 +0000 (UTC) X-Session-Marker: 6A6F6540706572636865732E636F6D X-Spam-Summary: 2,0,0,,d41d8cd98f00b204,joe@perches.com,:::::::::::,RULES_HIT:41:355:379:599:800:960:973:988:989:1260:1277:1311:1313:1314:1345:1359:1437:1515:1516:1518:1534:1542:1593:1594:1711:1730:1747:1777:1792:2194:2199:2393:2553:2559:2562:2828:2895:3138:3139:3140:3141:3142:3280:3354:3622:3865:3867:3868:3870:3872:3873:3874:4321:4362:4605:5007:6691:7974:9040:10004:10400:10848:11026:11232:11233:11658:11914:12043:12296:12297:12438:12555:12740:12760:12895:12986:13161:13229:13255:13439:14096:14097:14181:14659:14721:21080:21325:21433:21451:21627:30051:30054:30070:30090:30091,0,RBL:47.151.135.224:@perches.com:.lbl8.mailshell.net-62.14.0.100 64.201.201.201,CacheIP:none,Bayesian:0.5,0.5,0.5,Netcheck:none,DomainCache:0,MSF:not bulk,SPF:fn,MSBL:0,DNSBL:neutral,Custom_rules:0:0:0,LFtime:27,LUA_SUMMARY:none X-HE-Tag: room92_5654232a53661 X-Filterd-Recvd-Size: 3478 Received: from XPS-9350.home (unknown [47.151.135.224]) (Authenticated sender: joe@perches.com) by omf10.hostedemail.com (Postfix) with ESMTPA; Mon, 28 Oct 2019 17:59:53 +0000 (UTC) Message-ID: <19fd23e98bab65a1ee624445193bd2ed86108881.camel@perches.com> Subject: Re: [PATCH] compiler*.h: Add '__' prefix and suffix to all __attribute__ #defines From: Joe Perches To: Miguel Ojeda , Luc Van Oostenryck , linux-sparse@vger.kernel.org Cc: Andrew Morton , linux-kernel , clang-built-linux Date: Mon, 28 Oct 2019 10:59:47 -0700 In-Reply-To: References: <7a15bc8ad7437dc3a044a4f9cd283500bd0b5f36.camel@perches.com> Content-Type: text/plain; charset="ISO-8859-1" User-Agent: Evolution 3.34.1-2 MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Mon, 2019-10-28 at 18:37 +0100, Miguel Ojeda wrote: > On Mon, Oct 28, 2019 at 12:43 PM Joe Perches wrote: > > diff --git a/include/linux/compiler_types.h b/include/linux/compiler_types.h > > index 72393a..b8c2145 100644 > > --- a/include/linux/compiler_types.h > > +++ b/include/linux/compiler_types.h > > @@ -5,27 +5,27 @@ > > #ifndef __ASSEMBLY__ > > > > #ifdef __CHECKER__ > > -# define __user __attribute__((noderef, address_space(1))) [] > Just in case: for these ones (i.e. __CHECKER__), did you check if > sparse handles this syntax? (I don't recall myself if it does). > > Other than that, thanks for the cleanup too! I can pick it up in the > the compiler-attributes tree and put it in -next. Thanks for asking and no, I did not until just now. Turns out sparse does _not_ handle these changes and the checking fails for these ____. sparse would have to update parse.c or the __CHECKER__ changes would need to be reverted. Perhaps update parse.c like: --- parse.c | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/parse.c b/parse.c index 48a63..4464e 100644 --- a/parse.c +++ b/parse.c @@ -549,13 +549,19 @@ static struct init_keyword { { "aligned", NS_KEYWORD, .op = &aligned_op }, { "__aligned__",NS_KEYWORD, .op = &aligned_op }, { "nocast", NS_KEYWORD, MOD_NOCAST, .op = &attr_mod_op }, + { "__nocast__", NS_KEYWORD, MOD_NOCAST, .op = &attr_mod_op }, { "noderef", NS_KEYWORD, MOD_NODEREF, .op = &attr_mod_op }, + { "__noderef__",NS_KEYWORD, MOD_NODEREF, .op = &attr_mod_op }, { "safe", NS_KEYWORD, MOD_SAFE, .op = &attr_mod_op }, + { "__safe__", NS_KEYWORD, MOD_SAFE, .op = &attr_mod_op }, { "force", NS_KEYWORD, .op = &attr_force_op }, + { "__force__", NS_KEYWORD, .op = &attr_force_op }, { "bitwise", NS_KEYWORD, MOD_BITWISE, .op = &attr_bitwise_op }, { "__bitwise__",NS_KEYWORD, MOD_BITWISE, .op = &attr_bitwise_op }, { "address_space",NS_KEYWORD, .op = &address_space_op }, + { "__address_space__",NS_KEYWORD, .op = &address_space_op }, { "context", NS_KEYWORD, .op = &context_op }, + { "__context__",NS_KEYWORD, .op = &context_op }, { "designated_init", NS_KEYWORD, .op = &designated_init_op }, { "__designated_init__", NS_KEYWORD, .op = &designated_init_op }, { "transparent_union", NS_KEYWORD, .op = &transparent_union_op },