PR_SET_TAGGED_ADDR_CTRL
control support for passing tagged user-space addresses to the kernel
- Provided by: manpages-dev (Version: 6.9.1-1)
- Source: manpages
- Report a bug
control support for passing tagged user-space addresses to the kernel
Standard C library (libc, -lc)
#include <linux/prctl.h> /* Definition of PR_* constants */ #include <sys/prctl.h>
int prctl(PR_SET_TAGGED_ADDR_CTRL, long mode, 0L, 0L, 0L);
Controls support for passing tagged user-space addresses to the kernel (i.e., addresses where bits 56—63 are not all zero).
The level of support is selected by support, which can be one of the following:
On success, the mode specified in mode is set for the calling thread.
If prctl(PR_SET_TAGGED_ADDR_CTRL, 0L, 0L, 0L, 0L) fails with EINVAL, then all addresses passed to the kernel must be untagged.
Irrespective of which mode is set, addresses passed to certain interfaces must always be untagged:
This list of exclusions may shrink when moving from one kernel version to a later kernel version. While the kernel may make some guarantees for backwards compatibility reasons, for the purposes of new software the effect of passing tagged addresses to these interfaces is unspecified.
The mode set by this call is inherited across fork(2) and clone(2). The mode is reset by execve(2) to 0 (i.e., tagged addresses not permitted in the user/kernel ABI).
On success, 0 is returned. On error, -1 is returned, and errno is set to indicate the error.
Linux. arm64 only.
Linux 5.4 (arm64).
This call is primarily intended for use by the run-time environment. A successful PR_SET_TAGGED_ADDR_CTRL call elsewhere may crash the calling process. The conditions for using it safely are complex and system-dependent. Don't use it unless you know what you are doing.
prctl(2), PR_SET_TAGGED_ADDR_CTRL(2const)
For more information, see the kernel source file Documentation/arm64/tagged-address-abi.rst.