Messages in this thread Patch in this message | | | From | Lai Jiangshan <> | Subject | [PATCH 9/9] fsnotify: remove fsnotify_init() | Date | Sat, 16 Mar 2013 00:50:57 +0800 |
| |
Since fsnotify_init() is empty in runtime, remove it. The build time test is moved to notification.c
Signed-off-by: Lai Jiangshan <laijs@cn.fujitsu.com> Cc: Eric Paris <eparis@parisplace.org> --- fs/notify/fsnotify.c | 8 -------- fs/notify/notification.c | 2 ++ 2 files changed, 2 insertions(+), 8 deletions(-)
diff --git a/fs/notify/fsnotify.c b/fs/notify/fsnotify.c index eaa0e9e..2ea0c1a 100644 --- a/fs/notify/fsnotify.c +++ b/fs/notify/fsnotify.c @@ -295,11 +295,3 @@ out: return ret; } EXPORT_SYMBOL_GPL(fsnotify); - -static __init int fsnotify_init(void) -{ - BUILD_BUG_ON(HWEIGHT32(ALL_FSNOTIFY_EVENTS) != 23); - - return 0; -} -core_initcall(fsnotify_init); diff --git a/fs/notify/notification.c b/fs/notify/notification.c index 7b51b05..80fc0b5 100644 --- a/fs/notify/notification.c +++ b/fs/notify/notification.c @@ -453,6 +453,8 @@ static __init int fsnotify_notification_init(void) fsnotify_event_cachep = KMEM_CACHE(fsnotify_event, SLAB_PANIC); fsnotify_event_holder_cachep = KMEM_CACHE(fsnotify_event_holder, SLAB_PANIC); + BUILD_BUG_ON(HWEIGHT32(ALL_FSNOTIFY_EVENTS) != 23); + q_overflow_event = fsnotify_create_event(NULL, FS_Q_OVERFLOW, NULL, FSNOTIFY_EVENT_NONE, NULL, 0, GFP_KERNEL); -- 1.7.4.4
| |