diff options
author | Paul Menage <menage@google.com> | 2008-10-18 23:28:05 -0400 |
---|---|---|
committer | Linus Torvalds <torvalds@linux-foundation.org> | 2008-10-20 11:52:38 -0400 |
commit | 886465f407e57d6c3c81013c919ea670ce1ae0d0 (patch) | |
tree | c8981531dee58b1fc19a383068d6770c030bd534 /include/linux/cgroup.h | |
parent | cc31edceee04a7b87f2be48f9489ebb72d264844 (diff) |
cgroups: fix declaration of cgroup_mm_owner_callbacks
The choice of real/dummy declaration for cgroup_mm_owner_callbacks()
shouldn't be based on CONFIG_MM_OWNER, but on CONFIG_CGROUPS. Otherwise
kernel/exit.c fails to compile when something other than a cgroups
controller selects CONFIG_MM_OWNER
Signed-off-by: Paul Menage <menage@google.com>
Acked-by: Pekka Enberg <penberg@cs.helsinki.fi>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'include/linux/cgroup.h')
-rw-r--r-- | include/linux/cgroup.h | 15 |
1 files changed, 6 insertions, 9 deletions
diff --git a/include/linux/cgroup.h b/include/linux/cgroup.h index 8ab91880a0ad..8b00f6643e93 100644 --- a/include/linux/cgroup.h +++ b/include/linux/cgroup.h | |||
@@ -403,6 +403,9 @@ void cgroup_iter_end(struct cgroup *cgrp, struct cgroup_iter *it); | |||
403 | int cgroup_scan_tasks(struct cgroup_scanner *scan); | 403 | int cgroup_scan_tasks(struct cgroup_scanner *scan); |
404 | int cgroup_attach_task(struct cgroup *, struct task_struct *); | 404 | int cgroup_attach_task(struct cgroup *, struct task_struct *); |
405 | 405 | ||
406 | void cgroup_mm_owner_callbacks(struct task_struct *old, | ||
407 | struct task_struct *new); | ||
408 | |||
406 | #else /* !CONFIG_CGROUPS */ | 409 | #else /* !CONFIG_CGROUPS */ |
407 | 410 | ||
408 | static inline int cgroup_init_early(void) { return 0; } | 411 | static inline int cgroup_init_early(void) { return 0; } |
@@ -421,15 +424,9 @@ static inline int cgroupstats_build(struct cgroupstats *stats, | |||
421 | return -EINVAL; | 424 | return -EINVAL; |
422 | } | 425 | } |
423 | 426 | ||
427 | static inline void cgroup_mm_owner_callbacks(struct task_struct *old, | ||
428 | struct task_struct *new) {} | ||
429 | |||
424 | #endif /* !CONFIG_CGROUPS */ | 430 | #endif /* !CONFIG_CGROUPS */ |
425 | 431 | ||
426 | #ifdef CONFIG_MM_OWNER | ||
427 | extern void | ||
428 | cgroup_mm_owner_callbacks(struct task_struct *old, struct task_struct *new); | ||
429 | #else /* !CONFIG_MM_OWNER */ | ||
430 | static inline void | ||
431 | cgroup_mm_owner_callbacks(struct task_struct *old, struct task_struct *new) | ||
432 | { | ||
433 | } | ||
434 | #endif /* CONFIG_MM_OWNER */ | ||
435 | #endif /* _LINUX_CGROUP_H */ | 432 | #endif /* _LINUX_CGROUP_H */ |