lkml.org 
[lkml]   [2018]   [Dec]   [6]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH] scripts/atomic: change 'fold' to 'grep'
[+ Ingo and Mark]

On Tue, Dec 04, 2018 at 10:47:13PM +0100, Anders Roxell wrote:
> 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>
> ---
> 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

Acked-by: Will Deacon <will.deacon@arm.com>

Ingo -- please can you take this one via -tip?

Cheers,

Will

\
 
 \ /
  Last update: 2018-12-06 16:53    [W:0.043 / U:0.780 seconds]
©2003-2018 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site