Skip to content

Commit

Permalink
uapi/auxvec: Define AT_HWCAP3 and AT_HWCAP4 aux vector, entries
Browse files Browse the repository at this point in the history
The powerpc toolchain keeps a copy of the HWCAP bit masks in the TCB
for fast access by the __builtin_cpu_supports() built-in function. The
TCB space for the HWCAP entries - which are created in pairs - is an ABI
extension, so waiting to create the space for HWCAP3 and HWCAP4 until
they are needed is problematic. Define AT_HWCAP3 and AT_HWCAP4 in the
generic uapi header so they can be used in glibc to reserve space in the
powerpc TCB for their future use.

I scanned through the Linux and GLIBC source codes looking for unused
AT_* values and 29 and 30 did not seem to be used, so they are what I
went with.

Signed-off-by: Peter Bergner <[email protected]>
Acked-by: Adhemerval Zanella <[email protected]>
Acked-by: Nicholas Piggin <[email protected]>
Acked-by: Szabolcs Nagy <[email protected]>
Acked-by: Arnd Bergmann <[email protected]>
Signed-off-by: Michael Ellerman <[email protected]>
Link: https://msgid.link/[email protected]
  • Loading branch information
peter-bergner authored and mpe committed Feb 16, 2024
1 parent 4b26558 commit 3281366
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions include/uapi/linux/auxvec.h
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,8 @@
#define AT_HWCAP2 26 /* extension of AT_HWCAP */
#define AT_RSEQ_FEATURE_SIZE 27 /* rseq supported feature size */
#define AT_RSEQ_ALIGN 28 /* rseq allocation alignment */
#define AT_HWCAP3 29 /* extension of AT_HWCAP */
#define AT_HWCAP4 30 /* extension of AT_HWCAP */

#define AT_EXECFN 31 /* filename of program */

Expand Down

0 comments on commit 3281366

Please sign in to comment.