Skip to content

Commit d9744f9

Browse files
committed
tools headers: Synchronize prctl.h ABI header
To pick up changes from: 2d2123b ("arm64/sve: Add prctl controls for userspace vector length management") 7582e22 ("arm64/sve: Backend logic for setting the vector length") That showed a limitation of the regexp used in tools/perf/trace/beauty/prctl_option.sh, that matches only PR_{SET,GET}_, but should match a few more, like PR_MPX_*, PR_CAP_* and the one added by the above commit, PR_SVE_SET_*. This silences this warning when building tools/perf: Warning: Kernel ABI header at 'tools/include/uapi/linux/prctl.h' differs from latest version at 'include/uapi/linux/prctl.h' Support for those extra prctl options should be left for the next merge window tho. Cc: Adrian Hunter <adrian.hunter@intel.com> Cc: Dave Martin <Dave.Martin@arm.com> Cc: David Ahern <dsahern@gmail.com> Cc: Jiri Olsa <jolsa@kernel.org> Cc: Namhyung Kim <namhyung@kernel.org> Cc: Wang Nan <wangnan0@huawei.com> Cc: Will Deacon <will.deacon@arm.com> Link: https://lkml.kernel.org/n/tip-r52dsyuzy04qzqyfcifjs35t@git.kernel.org Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
1 parent 374fbe5 commit d9744f9

File tree

1 file changed

+9
-0
lines changed

1 file changed

+9
-0
lines changed

tools/include/uapi/linux/prctl.h

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -198,4 +198,13 @@ struct prctl_mm_map {
198198
# define PR_CAP_AMBIENT_LOWER 3
199199
# define PR_CAP_AMBIENT_CLEAR_ALL 4
200200

201+
/* arm64 Scalable Vector Extension controls */
202+
/* Flag values must be kept in sync with ptrace NT_ARM_SVE interface */
203+
#define PR_SVE_SET_VL 50 /* set task vector length */
204+
# define PR_SVE_SET_VL_ONEXEC (1 << 18) /* defer effect until exec */
205+
#define PR_SVE_GET_VL 51 /* get task vector length */
206+
/* Bits common to PR_SVE_SET_VL and PR_SVE_GET_VL */
207+
# define PR_SVE_VL_LEN_MASK 0xffff
208+
# define PR_SVE_VL_INHERIT (1 << 17) /* inherit across exec */
209+
201210
#endif /* _LINUX_PRCTL_H */

0 commit comments

Comments
 (0)