Received: by 2002:a05:6a10:8c0a:0:0:0:0 with SMTP id go10csp2711578pxb; Sun, 28 Feb 2021 10:24:25 -0800 (PST) X-Google-Smtp-Source: ABdhPJw7s1i32KJEZNV2WfwdkNmVXGU4FKr5Q8YBFrZ5weTkJlM93Bqz8QnetV5i9nUTwKqWGAyX X-Received: by 2002:a17:907:9870:: with SMTP id ko16mr2571126ejc.227.1614536665060; Sun, 28 Feb 2021 10:24:25 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1614536665; cv=none; d=google.com; s=arc-20160816; b=NQCiurj8p0+IByMYRBLQYwBfuXPzT9wZiYDo3DHR2mnh/NHwxo1DdUCIxbofBDl5IB 5C8XKRtyVa8yhPXg2A+eWMmPryE5ruGnqpnrssBqLxKAVP1kMxTGr2gygWN0fdQ4DBwh ola5h1Ul2BnUpmSbXYf8mzAXiRIqUBPSbfO3jeOqL45omnBdr3slFbsQLtoLdr/I6751 hQUH77zLQZX+tpK9696jbhwQuV7NQAvxG2WXQNDR2anBABE1R3lbPM6lezqHaAuViSoG I1YJz2PbsEhsR6+gws0hOwWJyXmNU6l3/op7BbnifLC3T0vwl8jBtSELkC1ss8etHThN tafg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:in-reply-to:content-disposition:mime-version :references:message-id:subject:cc:to:from:date:dkim-signature; bh=7YUkIDahw7q5sGV9rCrNMX4FzoCaiw+1r02YFIypIQM=; b=AZJ3ruW8Wddtd5V/Is/nnAXLFzNrnaJ01+zs42+OaMydWenRNz1h/9k1ZfafILn7V8 Lr2Z6NHIZWKsg34HopC+rAAqa/E22uWVDuYEzOBovG/nWE5qL0ih5AIq0/xH528g0xx1 UzR+Xzg4X54Ph0++gbFL6jrQ+9c8pPCkxJ9R2/CwX+ZvIeFiEnxp0bDCmUfKnuE/ICao yfGkRIkSV/c78s4Fpt+N8J9yy32yTJW3xR1YiIpZs7SA+pniDOoOBaQbA++M4A5yOehy uD1Q9YcwssQLu827oeL1fXzWryq+c74BapZnw91q5O/O/YWeNaySpn0no+SApvdE0fi6 PIQA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmail.com header.s=20161025 header.b=H78eikpl; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id a3si10040326ejd.66.2021.02.28.10.23.59; Sun, 28 Feb 2021 10:24:25 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@gmail.com header.s=20161025 header.b=H78eikpl; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S230260AbhB1REE (ORCPT + 99 others); Sun, 28 Feb 2021 12:04:04 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:47294 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229982AbhB1REC (ORCPT ); Sun, 28 Feb 2021 12:04:02 -0500 Received: from mail-ej1-x62c.google.com (mail-ej1-x62c.google.com [IPv6:2a00:1450:4864:20::62c]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id C5A05C06174A for ; Sun, 28 Feb 2021 09:03:21 -0800 (PST) Received: by mail-ej1-x62c.google.com with SMTP id g5so23815008ejt.2 for ; Sun, 28 Feb 2021 09:03:21 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=date:from:to:cc:subject:message-id:references:mime-version :content-disposition:in-reply-to; bh=7YUkIDahw7q5sGV9rCrNMX4FzoCaiw+1r02YFIypIQM=; b=H78eikpl8j98214OsgKn3iahzs2L7hObYlWWutvuzZZglIfdn9s/0f/yVJaJm9dMh8 GQIN3+f/QYSjOdXYiO8JZxlftF9prODkSNhQq0VZaQMoVjTJEpC5eMUZVFBnIz3WzAfP qWmkgMNw+GnBSldmBlVr/S4Vjdxnbx7CqMA52NBUUrHL1HNQQiEt+Xjzt7JXXlmhPQeg hltM8V4gNuCfGoBeys0tGZjgSana6XA7bhJeQiD8thlFNTQOssM8uv5zApG/fRtjVyTt ZnViyImysmY+1DIDOXGIqrTMC5CZTGkdcb0u7NoBLQnDo3984/Q1NYnZ/gq+Ocsu8Q9W SUjA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:date:from:to:cc:subject:message-id:references :mime-version:content-disposition:in-reply-to; bh=7YUkIDahw7q5sGV9rCrNMX4FzoCaiw+1r02YFIypIQM=; b=ijIFAXwoRg8X+rSIfpDByIwIUbhBTaly2Rgz1XiFJkCdnqKYPySiPf0Npue2H3LXDP e/84ZarMF6S7/+KbXK8HdCXPp+QPo+L3LHrB+kvzYsv0m/aryHd/zC7gtGahcNjhet5+ 1fCM2SwcyGpiRbFpmJbpLiR1uLkKm7bLaqnIoECUXMflC4iHehG1rkE7ALW9nrYTf802 n5Lce9GUzV/wjgCVdxQYm5AUeiZEgYXAbx1cpaA32PUACo94Pzg7FZTg5eHm9B03iJwk 2iza6HNYEqncqr2a/tCPUsfBh4I6heSWKdPsxvlKGOk4t6SbXunNDYJLUVV0Q98JdwCS 4ozA== X-Gm-Message-State: AOAM531lInSj06KHD4B5/CuLznXJ3TzlfEa7OgAHEYosoUpSiFi5EYOl 9l69n31ge0wRIMm0pU9kiA== X-Received: by 2002:a17:907:1b1f:: with SMTP id mp31mr12142090ejc.348.1614531800545; Sun, 28 Feb 2021 09:03:20 -0800 (PST) Received: from localhost.localdomain ([46.53.249.223]) by smtp.gmail.com with ESMTPSA id t6sm6539494edq.48.2021.02.28.09.03.20 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sun, 28 Feb 2021 09:03:20 -0800 (PST) Date: Sun, 28 Feb 2021 20:03:18 +0300 From: Alexey Dobriyan To: torvalds@linux-foundation.org Cc: linux-kernel@vger.kernel.org, akpm@linux-foundation.org, will@kernel.org, peterz@infradead.org, boqun.feng@gmail.com Subject: [PATCH 08/11] pragma once: convert scripts/atomic/ Message-ID: References: MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline In-Reply-To: Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From f10fe79897fa9600f144c76bc5df52dba28b7a66 Mon Sep 17 00:00:00 2001 From: Alexey Dobriyan Date: Tue, 9 Feb 2021 01:37:55 +0300 Subject: [PATCH 08/11] pragma once: convert scripts/atomic/ Generate atomic headers without include guards. Signed-off-by: Alexey Dobriyan --- include/asm-generic/atomic-instrumented.h | 9 ++------- include/asm-generic/atomic-long.h | 9 ++------- include/linux/atomic-arch-fallback.h | 9 ++------- include/linux/atomic-fallback.h | 9 ++------- scripts/atomic/gen-atomic-fallback.sh | 10 +--------- scripts/atomic/gen-atomic-instrumented.sh | 10 +--------- scripts/atomic/gen-atomic-long.sh | 7 +------ 7 files changed, 11 insertions(+), 52 deletions(-) diff --git a/include/asm-generic/atomic-instrumented.h b/include/asm-generic/atomic-instrumented.h index 888b6cfeed91..7c50dc944da4 100644 --- a/include/asm-generic/atomic-instrumented.h +++ b/include/asm-generic/atomic-instrumented.h @@ -1,5 +1,5 @@ // SPDX-License-Identifier: GPL-2.0 - +#pragma once // Generated by scripts/atomic/gen-atomic-instrumented.sh // DO NOT MODIFY THIS FILE DIRECTLY @@ -14,9 +14,6 @@ * arch_ variants (i.e. arch_atomic_read()/arch_atomic_cmpxchg()) to avoid * double instrumentation. */ -#ifndef _ASM_GENERIC_ATOMIC_INSTRUMENTED_H -#define _ASM_GENERIC_ATOMIC_INSTRUMENTED_H - #include #include #include @@ -1828,6 +1825,4 @@ atomic64_dec_if_positive(atomic64_t *v) instrument_atomic_write(__ai_ptr, 2 * sizeof(*__ai_ptr)); \ arch_cmpxchg_double_local(__ai_ptr, __VA_ARGS__); \ }) - -#endif /* _ASM_GENERIC_ATOMIC_INSTRUMENTED_H */ -// 4bec382e44520f4d8267e42620054db26a659ea3 +// d4532f98463d7403bde1d3199c19ef660be362a4 diff --git a/include/asm-generic/atomic-long.h b/include/asm-generic/atomic-long.h index 073cf40f431b..99627cd42f32 100644 --- a/include/asm-generic/atomic-long.h +++ b/include/asm-generic/atomic-long.h @@ -1,11 +1,7 @@ // SPDX-License-Identifier: GPL-2.0 - +#pragma once // Generated by scripts/atomic/gen-atomic-long.sh // DO NOT MODIFY THIS FILE DIRECTLY - -#ifndef _ASM_GENERIC_ATOMIC_LONG_H -#define _ASM_GENERIC_ATOMIC_LONG_H - #include #include @@ -1010,5 +1006,4 @@ atomic_long_dec_if_positive(atomic_long_t *v) } #endif /* CONFIG_64BIT */ -#endif /* _ASM_GENERIC_ATOMIC_LONG_H */ -// a624200981f552b2c6be4f32fe44da8289f30d87 +// d6f8dde6d86814728f0671cfc505c9a3361a70a0 diff --git a/include/linux/atomic-arch-fallback.h b/include/linux/atomic-arch-fallback.h index a3dba31df01e..477c53f3a4d6 100644 --- a/include/linux/atomic-arch-fallback.h +++ b/include/linux/atomic-arch-fallback.h @@ -1,11 +1,7 @@ // SPDX-License-Identifier: GPL-2.0 - +#pragma once // Generated by scripts/atomic/gen-atomic-fallback.sh // DO NOT MODIFY THIS FILE DIRECTLY - -#ifndef _LINUX_ATOMIC_FALLBACK_H -#define _LINUX_ATOMIC_FALLBACK_H - #include #ifndef arch_xchg_relaxed @@ -2357,5 +2353,4 @@ arch_atomic64_dec_if_positive(atomic64_t *v) #define arch_atomic64_dec_if_positive arch_atomic64_dec_if_positive #endif -#endif /* _LINUX_ATOMIC_FALLBACK_H */ -// cca554917d7ea73d5e3e7397dd70c484cad9b2c4 +// 97eae5341271dde782071fb73ff76f4b7bfa4808 diff --git a/include/linux/atomic-fallback.h b/include/linux/atomic-fallback.h index 2a3f55d98be9..eecc9ee88af6 100644 --- a/include/linux/atomic-fallback.h +++ b/include/linux/atomic-fallback.h @@ -1,11 +1,7 @@ // SPDX-License-Identifier: GPL-2.0 - +#pragma once // Generated by scripts/atomic/gen-atomic-fallback.sh // DO NOT MODIFY THIS FILE DIRECTLY - -#ifndef _LINUX_ATOMIC_FALLBACK_H -#define _LINUX_ATOMIC_FALLBACK_H - #include #ifndef xchg_relaxed @@ -2591,5 +2587,4 @@ atomic64_dec_if_positive(atomic64_t *v) #define atomic64_dec_if_positive atomic64_dec_if_positive #endif -#endif /* _LINUX_ATOMIC_FALLBACK_H */ -// d78e6c293c661c15188f0ec05bce45188c8d5892 +// a697a2a982652cdb954bc317199caba6ae5c3ed9 diff --git a/scripts/atomic/gen-atomic-fallback.sh b/scripts/atomic/gen-atomic-fallback.sh index 317a6cec76e1..27a63ae3a458 100755 --- a/scripts/atomic/gen-atomic-fallback.sh +++ b/scripts/atomic/gen-atomic-fallback.sh @@ -223,13 +223,9 @@ gen_try_cmpxchg_fallbacks() cat << EOF // SPDX-License-Identifier: GPL-2.0 - +#pragma once // Generated by $0 // DO NOT MODIFY THIS FILE DIRECTLY - -#ifndef _LINUX_ATOMIC_FALLBACK_H -#define _LINUX_ATOMIC_FALLBACK_H - #include EOF @@ -254,7 +250,3 @@ EOF grep '^[a-z]' "$1" | while read name meta args; do gen_proto "${meta}" "${name}" "${ARCH}" "atomic64" "s64" ${args} done - -cat < #include #include @@ -202,8 +199,3 @@ gen_xchg "cmpxchg_double" "2 * " printf "\n\n" gen_xchg "cmpxchg_double_local" "2 * " - -cat < #include @@ -98,5 +94,4 @@ done cat <