diff options
author | Manfred Spraul <[email protected]> | 2011-11-02 13:38:56 -0700 |
---|---|---|
committer | Linus Torvalds <[email protected]> | 2011-11-02 16:07:01 -0700 |
commit | f567a18590742b811287b7512fb0908deac4eef7 (patch) | |
tree | 5ed76fc1727cbce2b64776afd5c682414f0c1726 | |
parent | e57940d719e9fc5223d133b631f8cb5232d6064e (diff) |
include/linux/sem.h: make sysv_sem empty if SYSVIPC is disabled
For the sysvsem undo, each task struct contains a sysv_sem structure with
a pointer to the undo information.
This pointer is only necessary if sysvipc is enabled - thus the pointer
can be made conditional on CONFIG_SYSVIPC.
Signed-off-by: Manfred Spraul <[email protected]>
Acked-by: Peter Zijlstra <[email protected]>
Cc: Thomas Gleixner <[email protected]>
Cc: Mike Galbraith <[email protected]>
Signed-off-by: Andrew Morton <[email protected]>
Signed-off-by: Linus Torvalds <[email protected]>
-rw-r--r-- | include/linux/sem.h | 9 |
1 files changed, 7 insertions, 2 deletions
diff --git a/include/linux/sem.h b/include/linux/sem.h index 464842621a4a..10d6b226afc5 100644 --- a/include/linux/sem.h +++ b/include/linux/sem.h @@ -96,16 +96,21 @@ struct sem_array { int complex_count; /* pending complex operations */ }; +#ifdef CONFIG_SYSVIPC + struct sysv_sem { struct sem_undo_list *undo_list; }; -#ifdef CONFIG_SYSVIPC - extern int copy_semundo(unsigned long clone_flags, struct task_struct *tsk); extern void exit_sem(struct task_struct *tsk); #else + +struct sysv_sem { + /* empty */ +}; + static inline int copy_semundo(unsigned long clone_flags, struct task_struct *tsk) { return 0; |