Skip to content

Commit 155ed9f

Browse files
committed
perf beauty: Cover more flags in the move_mount syscall argument beautifier
Previously the regext expected MOVE_MOUNT_[FT]_*, but in the next patch a flag that doesn't match that expression will be added, MOVE_MOUNT_SET_GROUP To make this more future proof, take advantage of the fact that the only one we don't need to cover is MOVE_MOUNT__MASK and use MOVE_MOUNT_[^_]+_*_. Signed-off-by: Arnaldo Carvalho de Melo <[email protected]>
1 parent 2c3ef25 commit 155ed9f

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

tools/perf/trace/beauty/move_mount_flags.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ fi
1010
linux_mount=${linux_header_dir}/mount.h
1111

1212
printf "static const char *move_mount_flags[] = {\n"
13-
regex='^[[:space:]]*#[[:space:]]*define[[:space:]]+MOVE_MOUNT_([FT]_[[:alnum:]_]+)[[:space:]]+(0x[[:xdigit:]]+)[[:space:]]*.*'
13+
regex='^[[:space:]]*#[[:space:]]*define[[:space:]]+MOVE_MOUNT_([^_]+_[[:alnum:]_]+)[[:space:]]+(0x[[:xdigit:]]+)[[:space:]]*.*'
1414
egrep $regex ${linux_mount} | \
1515
sed -r "s/$regex/\2 \1/g" | \
1616
xargs printf "\t[ilog2(%s) + 1] = \"%s\",\n"

0 commit comments

Comments
 (0)