kcmp: fs/epoll: wrap kcmp code with CONFIG_CHECKPOINT_RESTORE
PATCH 30/96 kcmp: fs/epoll: wrap kcmp code with CONFIG_CHECKPOINT_RESTORE
From: Cyrill Gorcunov <[email protected]>
Subject: kcmp: fs/epoll: wrap kcmp code with CONFIG_CHECKPOINT_RESTORE
kcmp syscall is build iif CONFIG_CHECKPOINT_RESTORE is selected, so wrap appropriate helpers in epoll code with the config to build it conditionally.
Signed-off-by Cyrill Gorcunov <[email protected]>
Reported-by Andrew Morton <[email protected]>
Cc Andrey Vagin <[email protected]>
Cc Al Viro <[email protected]>
Cc Pavel Emelyanov <[email protected]>
Cc Michael Kerrisk <[email protected]>
Cc Jason Baron <[email protected]>
Cc Andy Lutomirski <[email protected]>
Signed-off-by Andrew Morton <[email protected]>
---
fs/eventpoll.c | 2 ++ include/linux/eventpoll.h | 2 ++ 2 files changed, 4 insertions(+)
fs/eventpoll.c renamed from fs/eventpoll.c~kcmp-fs-epoll-wrap-kcmp-code-with-config_checkpoint_restore +2 -0
@@ -1077,6 +1077,7 @@ static struct epitem *ep_find(struct evereturn epir; } +#ifdef CONFIG_CHECKPOINT_RESTORE static struct epitem *ep_find_tfd (struct eventpoll *ep,int tfd,unsigned long toff) {struct rb_node *rbp;
@@ -1118,6 +1119,7 @@ struct file *get_epoll_tfile_raw_ptr(str return file_raw; } +#endif /* CONFIG_CHECKPOINT_RESTORE */ /* * This is the callback that is passed to the wait queue wakeup
include/linux/eventpoll.h renamed from include/linux/eventpoll.h~kcmp-fs-epoll-wrap-kcmp-code-with-config_checkpoint_restore +2 -0
@@ -23,7 +23,9 @@ struct file;#ifdef CONFIG_EPOLL +#ifdef CONFIG_CHECKPOINT_RESTORE struct file *get_epoll_tfile_raw_ptr (struct file *file,int tfd,unsigned long toff); +#endif /* Used to initialize the epoll bits inside the "struct file" */ static inline void eventpoll_init_file (struct file *file)
_