diff options
author | David Rientjes <rientjes@google.com> | 2007-10-17 02:25:53 -0400 |
---|---|---|
committer | Linus Torvalds <torvalds@woody.linux-foundation.org> | 2007-10-17 11:42:45 -0400 |
commit | 70e24bdf6d2fead14631e72a07fba012400c521e (patch) | |
tree | 2c00056dfdf90f733876c717159bb8bbf9f440fe /include | |
parent | 5a3135c2e77fe88cdea20b5e3f4761068b799ac2 (diff) |
oom: move constraints to enum
The OOM killer's CONSTRAINT definitions are really more appropriate in an
enum, so define them in include/linux/oom.h.
Cc: Andrea Arcangeli <andrea@suse.de>
Acked-by: Christoph Lameter <clameter@sgi.com>
Signed-off-by: David Rientjes <rientjes@google.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'include')
-rw-r--r-- | include/linux/oom.h | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/include/linux/oom.h b/include/linux/oom.h index b40bb4e32c2f..cf6ebf5b422c 100644 --- a/include/linux/oom.h +++ b/include/linux/oom.h | |||
@@ -11,6 +11,15 @@ | |||
11 | 11 | ||
12 | #ifdef __KERNEL__ | 12 | #ifdef __KERNEL__ |
13 | 13 | ||
14 | /* | ||
15 | * Types of limitations to the nodes from which allocations may occur | ||
16 | */ | ||
17 | enum oom_constraint { | ||
18 | CONSTRAINT_NONE, | ||
19 | CONSTRAINT_CPUSET, | ||
20 | CONSTRAINT_MEMORY_POLICY, | ||
21 | }; | ||
22 | |||
14 | extern void out_of_memory(struct zonelist *zonelist, gfp_t gfp_mask, int order); | 23 | extern void out_of_memory(struct zonelist *zonelist, gfp_t gfp_mask, int order); |
15 | extern int register_oom_notifier(struct notifier_block *nb); | 24 | extern int register_oom_notifier(struct notifier_block *nb); |
16 | extern int unregister_oom_notifier(struct notifier_block *nb); | 25 | extern int unregister_oom_notifier(struct notifier_block *nb); |