Debian Codegraph @

upstream/debian-unstable/man2/PR_GET_THP_DISABLE.2const

raw
1 .\" Copyright 2014-2015, Michael Kerrisk <[email protected]>
2 .\" Copyright, the authors of the Linux man-pages project
3 .\"
4 .\" SPDX-License-Identifier: Linux-man-pages-copyleft
5 .\"
6 .TH PR_GET_THP_DISABLE 2const 2026-02-08 "Linux man-pages 6.18"
7 .SH NAME
8 PR_GET_THP_DISABLE
9 \-
10 get the state of the "THP disable" flags for the calling thread
11 .SH LIBRARY
12 Standard C library
13 .RI ( libc ,\~ \-lc )
14 .SH SYNOPSIS
15 .nf
16 .BR "#include <linux/prctl.h>" " /* Definition of " PR_* " constants */"
17 .B #include <sys/prctl.h>
18 .P
19 .B int prctl(PR_GET_THP_DISABLE, 0L, 0L, 0L, 0L);
20 .fi
21 .SH DESCRIPTION
22 Return a value whose bits indicate how THP-disable is configured
23 for the calling thread.
24 The returned value is interpreted as follows:
25 .TP
26 .B 0b00
27 No THP-disable behavior specified.
28 .TP
29 .B 0b01
30 THP is entirely disabled for this process.
31 .TP
32 .B 0b11
33 THP-except-advised mode is set for this process.
34 .SH RETURN VALUE
35 On success,
36 .BR PR_GET_THP_DISABLE ,
37 returns the value described above.
38 On error, \-1 is returned, and
39 .I errno
40 is set to indicate the error.
41 .SH STANDARDS
42 Linux.
43 .SH HISTORY
44 Linux 3.15.
45 .SH SEE ALSO
46 .BR prctl (2),
47 .BR PR_SET_THP_DISABLE (2const)