diff options
| author | Rusty Russell <rusty@rustcorp.com.au> | 2003-04-29 17:17:42 -0700 |
|---|---|---|
| committer | Christoph Hellwig <hch@lst.de> | 2003-04-29 17:17:42 -0700 |
| commit | fbf7eda6f4f1e3d5b9a26d82a6884755d34923b7 (patch) | |
| tree | 288b6fc4de89a142f68c249dbdd286042916034a /fs/filesystems.c | |
| parent | 67ac5b866bda838d9838faedad0435e3e84fb2bd (diff) | |
[PATCH] __module_get
Introduces __module_get for places where we know we already hold
a reference and ignoring the fact that the module is being "rmmod --wait"ed
is simpler.
Diffstat (limited to 'fs/filesystems.c')
| -rw-r--r-- | fs/filesystems.c | 12 |
1 files changed, 1 insertions, 11 deletions
diff --git a/fs/filesystems.c b/fs/filesystems.c index a87d637e168a..c4b467fb67dd 100644 --- a/fs/filesystems.c +++ b/fs/filesystems.c @@ -32,17 +32,7 @@ static rwlock_t file_systems_lock = RW_LOCK_UNLOCKED; /* WARNING: This can be used only if we _already_ own a reference */ void get_filesystem(struct file_system_type *fs) { - if (!try_module_get(fs->owner)) { -#ifdef CONFIG_MODULE_UNLOAD - unsigned int cpu = get_cpu(); - local_inc(&fs->owner->ref[cpu].count); - put_cpu(); -#else - /* Getting filesystem while it's starting up? We're - already supposed to have a reference. */ - BUG(); -#endif - } + __module_get(fs->owner); } void put_filesystem(struct file_system_type *fs) |
