From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mails.dpdk.org (mails.dpdk.org [217.70.189.124]) by inbox.dpdk.org (Postfix) with ESMTP id CAD674280D; Wed, 22 Mar 2023 19:08:21 +0100 (CET) Received: from mails.dpdk.org (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 5B3DD40E09; Wed, 22 Mar 2023 19:08:21 +0100 (CET) Received: from linux.microsoft.com (linux.microsoft.com [13.77.154.182]) by mails.dpdk.org (Postfix) with ESMTP id D3DC940E09 for ; Wed, 22 Mar 2023 19:08:19 +0100 (CET) Received: by linux.microsoft.com (Postfix, from userid 1086) id 32AB520FB6C4; Wed, 22 Mar 2023 11:08:19 -0700 (PDT) DKIM-Filter: OpenDKIM Filter v2.11.0 linux.microsoft.com 32AB520FB6C4 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linux.microsoft.com; s=default; t=1679508499; bh=0hCx5mrr6kC5DTsk3pVEMAhCwX9Ow5LWtBcv36NVEtQ=; h=Date:From:To:Cc:Subject:References:In-Reply-To:From; b=l5X7PeHRvB1tV/leuR4UR3lpygwJTigb9tmHw5n7zFWXfah5KQzhiQ/WlLCsuknjd SogDWE8hx7IoPQu57AotfgwuTCzj3pcqHfrgrTfkdMMme3q2Fku3J7rRSqZZujSf1n FG1Z803A3BSs2gjB4hcbVdFQ+Dl6WOCYCyEeThXo= Date: Wed, 22 Mar 2023 11:08:19 -0700 From: Tyler Retzlaff To: dev@dpdk.org Cc: thomas@monjalon.net, mb@smartsharesystems.com, Honnappa.Nagarahalli@arm.com, david.marchand@redhat.com Subject: Re: [PATCH] devtools: stop compiler atomics with no C11 equivalent Message-ID: <20230322180819.GB28785@linuxonhyperv3.guj3yctzbm1etfxqx2vob5hsef.xx.internal.cloudapp.net> References: <1679329321-26073-1-git-send-email-roretzla@linux.microsoft.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <1679329321-26073-1-git-send-email-roretzla@linux.microsoft.com> User-Agent: Mutt/1.5.21 (2010-09-15) X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dev-bounces@dpdk.org adding a few more people to cc for attention On Mon, Mar 20, 2023 at 09:22:01AM -0700, Tyler Retzlaff wrote: > Refrain from using compiler __atomic_{add,and,nand,or,sub,xor}_fetch() > to ease future adoption of C11 standard atomics. > > Signed-off-by: Tyler Retzlaff > --- > devtools/checkpatches.sh | 8 ++++++++ > 1 file changed, 8 insertions(+) > > diff --git a/devtools/checkpatches.sh b/devtools/checkpatches.sh > index 1dee094..1ed6d51 100755 > --- a/devtools/checkpatches.sh > +++ b/devtools/checkpatches.sh > @@ -119,6 +119,14 @@ check_forbidden_additions() { # > -f $(dirname $(readlink -f $0))/check-forbidden-tokens.awk \ > "$1" || res=1 > > + # refrain from using compiler __atomic_{add,and,nand,or,sub,xor}_fetch() > + awk -v FOLDERS="lib drivers app examples" \ > + -v EXPRESSIONS="__atomic_(add|and|nand|or|sub|xor)_fetch\\\(" \ > + -v RET_ON_FAIL=1 \ > + -v MESSAGE='Using __atomic_{add,and,nand,or,sub,xor}_fetch' \ > + -f $(dirname $(readlink -f $0))/check-forbidden-tokens.awk \ > + "$1" || res=1 > + > # forbid use of __reserved which is a reserved keyword in Windows system headers > awk -v FOLDERS="lib drivers app examples" \ > -v EXPRESSIONS='\\<__reserved\\>' \ > -- > 1.8.3.1