PR_GET_THP_DISABLE(2const)
π PR_GET_THP_DISABLE(2const) β a.k.a. the manual page you're reading, bestie π
okay so this is PR_GET_THP_DISABLE(2const) and it's literally the girl whose whole job is peeking at your thread's "THP disable" flags. she doesn't set anything, she doesn't change anything, she just looks and reports back. a true observer. main character energy but make it read-only. π¦
β¨ NAME β¨
PR_GET_THP_DISABLE β get the state of the "THP disable" flags for the calling thread π
π LIBRARY π
Standard C library (libc, -lc) β yeah, the usual. she lives there.
πΈ SYNOPSIS πΈ
#include <linux/prctl.h> /* Definition of PR_* constants */
#include <sys/prctl.h>
int prctl(PR_GET_THP_DISABLE, 0L, 0L, 0L, 0L);
not me calling prctl() with that many 0Ls β girl, they're all zeros, everyone just follow along, it's fine. π«Ά
π DESCRIPTION π
She returns a value whose bits tell you how THP-disable is configured for the calling thread. That's the vibe check. Then you interpret the returned bits like this:
0b00β no THP-disable behavior specified. literally nothing's been said. untouched. pristine. β¨0b01β THP is entirely disabled for this process. all of it. gone. blocked. π0b11β THP-except-advised mode is set for this process. so it's giving "only where advised" energy. iykyk. π
heads up: this is bit-y business, so read the returned value as bits, not as a regular "oh it's 1 or 3" situation. the description above is the whole truth and nothing but. π
β RETURN VALUE β
On success, PR_GET_THP_DISABLE returns the value described above (the bit-thing from the DESCRIPTION, you got this). π
On error, -1 is returned, and errno is set to indicate the error. classic. love that for us. π
π₯ STANDARDS π₯
Linux. that's it. that's the section. periodt. π
π§ HISTORY π§
Linux 3.15. an icon, an era, a moment. π
π SEE ALSO π
prctl(2)PR_SET_THP_DISABLE(2const)β the setter to this getter, her other half fr fr π«Ά
and that's the page, bestie!! go forth and read your flags responsibly πβ¨ no cap, this was Linux man-pages 6.20, dated 2026-02-08, and yes she slayed every single line of it. bye bye πππΈ
π¦ where this page comes from
- arch rolling: man-pages 6.20-1 Β· BSD-2-Clause AND BSD-3-Clause AND BSD-4.3TAHOE AND BSD-4-Clause-UC AND GPL-1.0-or-later AND GPL-2.0-only AND GPL-2.0-or-later AND GPL-3.0-or-later AND LGPL-3.0-linking-exception AND LGPL-3.0-or-later AND LicenseRef-Public-Domain AND LicenseRef-UltraPermissive AND Linux-man-pages-1-para AND Linux-man-pages-copyleft AND Linux-man-pages-copyleft-2-para AND Linux-man-pages-copyleft-var AND MIT AND Spencer-94
- nixpkgs unstable: man-pages 6.20
- π the page's license: Linux-man-pages-copyleft
- Copyright 2014-2015, Michael Kerrisk <mtk.manpages@gmail.com>
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms