diff options
author | Andi Kleen <andi@firstfloor.org> | 2009-09-16 13:50:14 +0400 |
---|---|---|
committer | Andi Kleen <ak@linux.intel.com> | 2009-09-16 13:50:14 +0400 |
commit | 4db96cf077aa938b11fe7ac79ecc9b29ec00fbab (patch) | |
tree | ec196e85769159f29952e34305795b47513639a0 /include/linux/prctl.h | |
parent | 6746aff74da293b5fd24e5c68b870b721e86cd5f (diff) | |
download | linux-4db96cf077aa938b11fe7ac79ecc9b29ec00fbab.tar.xz |
HWPOISON: Add PR_MCE_KILL prctl to control early kill behaviour per process
This allows processes to override their early/late kill
behaviour on hardware memory errors.
Typically applications which are memory error aware is
better of with early kill (see the error as soon
as possible), all others with late kill (only
see the error when the error is really impacting execution)
There's a global sysctl, but this way an application
can set its specific policy.
We're using two bits, one to signify that the process
stated its intention and that
I also made the prctl future proof by enforcing
the unused arguments are 0.
The state is inherited to children.
Note this makes us officially run out of process flags
on 32bit, but the next patch can easily add another field.
Manpage patch will be supplied separately.
Signed-off-by: Andi Kleen <ak@linux.intel.com>
Diffstat (limited to 'include/linux/prctl.h')
-rw-r--r-- | include/linux/prctl.h | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/include/linux/prctl.h b/include/linux/prctl.h index b00df4c79c63..3dc303197e67 100644 --- a/include/linux/prctl.h +++ b/include/linux/prctl.h @@ -88,4 +88,6 @@ #define PR_TASK_PERF_COUNTERS_DISABLE 31 #define PR_TASK_PERF_COUNTERS_ENABLE 32 +#define PR_MCE_KILL 33 + #endif /* _LINUX_PRCTL_H */ |