mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Lai Jiangshan <laijs@cn.fujitsu.com>
To: "Paul E. McKenney" <paulmck@linux.vnet.ibm.com>,
	Andrew Morton <akpm@linux-foundation.org>,
	linux-kernel@vger.kernel.org
Cc: Lai Jiangshan <laijs@cn.fujitsu.com>,
	Eric Paris <eparis@parisplace.org>,
	Al Viro <viro@zeniv.linux.org.uk>,
	Sasha Levin <sasha.levin@oracle.com>,
	Dan Carpenter <dan.carpenter@oracle.com>,
	H Hartley Sweeten <hsweeten@visionengravers.com>,
	Adam Buchbinder <adam.buchbinder@gmail.com>,
	Jiri Kosina <jkosina@suse.cz>, Eric Paris <eparis@redhat.com>
Subject: [PATCH 9/9] fsnotify: remove fsnotify_init()
Date: Sat, 16 Mar 2013 00:50:57 +0800	[thread overview]
Message-ID: <1363366257-4886-10-git-send-email-laijs@cn.fujitsu.com> (raw)
In-Reply-To: <1363366257-4886-1-git-send-email-laijs@cn.fujitsu.com>

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


      parent reply	other threads:[~2013-03-15 16:53 UTC|newest]

Thread overview: 14+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-03-15 16:50 [PATCH 0/9 for-3.10] srcu: use-site fix and cleanups Lai Jiangshan
2013-03-15 16:50 ` [PATCH 1/9] powerpc,kvm: fix imbalance srcu_read_[un]lock() Lai Jiangshan
2013-03-17 21:26   ` Paul Mackerras
2013-04-11 21:51     ` Paul E. McKenney
2013-03-15 16:50 ` [PATCH 2/9] events: use DEFINE_STATIC_SRCU() to define pmus_srcu Lai Jiangshan
2013-03-15 16:50 ` [PATCH 3/9] mmu_notifier: use DEFINE_STATIC_SRCU() to define srcu struct Lai Jiangshan
2013-03-15 16:50 ` [PATCH 4/9] netpoll: use DEFINE_STATIC_SRCU() to define netpoll_srcu Lai Jiangshan
2013-03-17 16:43   ` David Miller
2013-03-15 16:50 ` [PATCH 5/9] tomoyo: use DEFINE_SRCU() to define tomoyo_ss Lai Jiangshan
2013-03-15 16:50 ` [PATCH 6/9] fsnotify: use DEFINE_SRCU() for srcu_struct Lai Jiangshan
2013-03-15 16:50 ` [PATCH 7/9] fsnotify: use existed call_srcu() Lai Jiangshan
2013-04-05  7:34   ` Lai Jiangshan
2013-03-15 16:50 ` [PATCH 8/9] fsnotify: use BUILD_BUG_ON() to test the weight of ALL_FSNOTIFY_EVENTS Lai Jiangshan
2013-03-15 16:50 ` Lai Jiangshan [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1363366257-4886-10-git-send-email-laijs@cn.fujitsu.com \
    --to=laijs@cn.fujitsu.com \
    --cc=adam.buchbinder@gmail.com \
    --cc=akpm@linux-foundation.org \
    --cc=dan.carpenter@oracle.com \
    --cc=eparis@parisplace.org \
    --cc=eparis@redhat.com \
    --cc=hsweeten@visionengravers.com \
    --cc=jkosina@suse.cz \
    --cc=linux-kernel@vger.kernel.org \
    --cc=paulmck@linux.vnet.ibm.com \
    --cc=sasha.levin@oracle.com \
    --cc=viro@zeniv.linux.org.uk \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®