projects
/
deliverable
/
linux.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
fs: scale mntget/mntput
[deliverable/linux.git]
/
net
/
socket.c
diff --git
a/net/socket.c
b/net/socket.c
index 0ee74c325320700f5b2bde733c6869804d486fd5..815bba3d2fe09c352d6a85f138fae7c4dcd83745 100644
(file)
--- a/
net/socket.c
+++ b/
net/socket.c
@@
-2390,6
+2390,8
@@
EXPORT_SYMBOL(sock_unregister);
static int __init sock_init(void)
{
static int __init sock_init(void)
{
+ int err;
+
/*
* Initialize sock SLAB cache.
*/
/*
* Initialize sock SLAB cache.
*/
@@
-2406,8
+2408,15
@@
static int __init sock_init(void)
*/
init_inodecache();
*/
init_inodecache();
- register_filesystem(&sock_fs_type);
+
+ err = register_filesystem(&sock_fs_type);
+ if (err)
+ goto out_fs;
sock_mnt = kern_mount(&sock_fs_type);
sock_mnt = kern_mount(&sock_fs_type);
+ if (IS_ERR(sock_mnt)) {
+ err = PTR_ERR(sock_mnt);
+ goto out_mount;
+ }
/* The real protocol initialization is performed in later initcalls.
*/
/* The real protocol initialization is performed in later initcalls.
*/
@@
-2420,7
+2429,13
@@
static int __init sock_init(void)
skb_timestamping_init();
#endif
skb_timestamping_init();
#endif
- return 0;
+out:
+ return err;
+
+out_mount:
+ unregister_filesystem(&sock_fs_type);
+out_fs:
+ goto out;
}
core_initcall(sock_init); /* early initcall */
}
core_initcall(sock_init); /* early initcall */
This page took
0.024822 seconds
and
5
git commands to generate.