From: Mark Rutland <mark.rutland@arm.com>
To: mingo@kernel.org
Cc: linux-kernel@vger.kernel.org, akpm@linux-foundation.org,
anders.roxell@linaro.org, boqun.feng@gmail.com,
mark.rutland@arm.com, naresh.kamboju@linaro.org,
peterz@infradead.org, will.deacon@arm.com
Subject: [PATCH 1/2] locking/atomics: Change 'fold' to 'grep'
Date: Mon, 10 Dec 2018 17:50:34 +0000 [thread overview]
Message-ID: <20181210175035.45096-2-mark.rutland@arm.com> (raw)
In-Reply-To: <20181210175035.45096-1-mark.rutland@arm.com>
From: Anders Roxell <anders.roxell@linaro.org>
Some distibutions and build systems doesn't include 'fold' from
coreutils default.
.../scripts/atomic/atomic-tbl.sh: line 183: fold: command not found
Rework to use 'grep' instead of 'fold' to use a dependency that is
already used a lot in the kernel.
Reported-by: Naresh Kamboju <naresh.kamboju@linaro.org>
Suggested-by: Will Deacon <will.deacon@arm.com>
Signed-off-by: Anders Roxell <anders.roxell@linaro.org>
[Mark: rework commit message]
Signed-off-by: Mark Rutland <mark.rutland@arm.com>
---
scripts/atomic/atomic-tbl.sh | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/scripts/atomic/atomic-tbl.sh b/scripts/atomic/atomic-tbl.sh
index 9d6be538a987..81d5c32039dd 100755
--- a/scripts/atomic/atomic-tbl.sh
+++ b/scripts/atomic/atomic-tbl.sh
@@ -180,7 +180,7 @@ gen_proto_variants()
#gen_proto(meta, ...)
gen_proto() {
local meta="$1"; shift
- for m in $(echo "${meta}" | fold -w1); do
+ for m in $(echo "${meta}" | grep -o .); do
gen_proto_variants "${m}" "$@"
done
}
--
2.11.0
next prev parent reply other threads:[~2018-12-10 17:50 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2018-12-10 17:50 [PATCH 0/2] locking/atomics: fix and improvement Mark Rutland
2018-12-10 17:50 ` Mark Rutland [this message]
2018-12-10 19:01 ` [PATCH 1/2] locking/atomics: Change 'fold' to 'grep' Will Deacon
2018-12-10 17:50 ` [PATCH 2/2] locking/atomics: Check atomic headers with sha1sum Mark Rutland
2018-12-10 19:03 ` Will Deacon
2018-12-12 10:18 ` [PATCH 0/2] locking/atomics: fix and improvement Mark Rutland
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20181210175035.45096-2-mark.rutland@arm.com \
--to=mark.rutland@arm.com \
--cc=akpm@linux-foundation.org \
--cc=anders.roxell@linaro.org \
--cc=boqun.feng@gmail.com \
--cc=linux-kernel@vger.kernel.org \
--cc=mingo@kernel.org \
--cc=naresh.kamboju@linaro.org \
--cc=peterz@infradead.org \
--cc=will.deacon@arm.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®