diff options
author | Kees Cook <keescook@chromium.org> | 2018-10-18 21:17:42 +0300 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2019-05-22 08:37:45 +0300 |
commit | f4bf101be366d1075767f21a10b1bf587ce2a52f (patch) | |
tree | d7c70041cd6da78df131796143ba8b66e234ce82 /fs/pstore/inode.c | |
parent | 627bb2d93b4d48f89e2087b3149c0a8444e5a1d4 (diff) | |
download | linux-f4bf101be366d1075767f21a10b1bf587ce2a52f.tar.xz |
pstore: Centralize init/exit routines
commit cb095afd44768bf495894b9ad063bd078e4bb201 upstream.
In preparation for having additional actions during init/exit, this moves
the init/exit into platform.c, centralizing the logic to make call outs
to the fs init/exit.
Signed-off-by: Kees Cook <keescook@chromium.org>
Tested-by: Guenter Roeck <groeck@chromium.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'fs/pstore/inode.c')
-rw-r--r-- | fs/pstore/inode.c | 11 |
1 files changed, 2 insertions, 9 deletions
diff --git a/fs/pstore/inode.c b/fs/pstore/inode.c index 5fcb845b9fec..8cf2218b46a7 100644 --- a/fs/pstore/inode.c +++ b/fs/pstore/inode.c @@ -482,12 +482,10 @@ static struct file_system_type pstore_fs_type = { .kill_sb = pstore_kill_sb, }; -static int __init init_pstore_fs(void) +int __init pstore_init_fs(void) { int err; - pstore_choose_compression(); - /* Create a convenient mount point for people to access pstore */ err = sysfs_create_mount_point(fs_kobj, "pstore"); if (err) @@ -500,14 +498,9 @@ static int __init init_pstore_fs(void) out: return err; } -module_init(init_pstore_fs) -static void __exit exit_pstore_fs(void) +void __exit pstore_exit_fs(void) { unregister_filesystem(&pstore_fs_type); sysfs_remove_mount_point(fs_kobj, "pstore"); } -module_exit(exit_pstore_fs) - -MODULE_AUTHOR("Tony Luck <tony.luck@intel.com>"); -MODULE_LICENSE("GPL"); |