diff options
Diffstat (limited to 'net/rose/af_rose.c')
-rw-r--r-- | net/rose/af_rose.c | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/net/rose/af_rose.c b/net/rose/af_rose.c index 502cce76621d..8feb9e5d6623 100644 --- a/net/rose/af_rose.c +++ b/net/rose/af_rose.c | |||
@@ -512,12 +512,13 @@ static struct proto rose_proto = { | |||
512 | .obj_size = sizeof(struct rose_sock), | 512 | .obj_size = sizeof(struct rose_sock), |
513 | }; | 513 | }; |
514 | 514 | ||
515 | static int rose_create(struct net *net, struct socket *sock, int protocol) | 515 | static int rose_create(struct net *net, struct socket *sock, int protocol, |
516 | int kern) | ||
516 | { | 517 | { |
517 | struct sock *sk; | 518 | struct sock *sk; |
518 | struct rose_sock *rose; | 519 | struct rose_sock *rose; |
519 | 520 | ||
520 | if (net != &init_net) | 521 | if (!net_eq(net, &init_net)) |
521 | return -EAFNOSUPPORT; | 522 | return -EAFNOSUPPORT; |
522 | 523 | ||
523 | if (sock->type != SOCK_SEQPACKET || protocol != 0) | 524 | if (sock->type != SOCK_SEQPACKET || protocol != 0) |
@@ -1509,7 +1510,7 @@ static const struct file_operations rose_info_fops = { | |||
1509 | }; | 1510 | }; |
1510 | #endif /* CONFIG_PROC_FS */ | 1511 | #endif /* CONFIG_PROC_FS */ |
1511 | 1512 | ||
1512 | static struct net_proto_family rose_family_ops = { | 1513 | static const struct net_proto_family rose_family_ops = { |
1513 | .family = PF_ROSE, | 1514 | .family = PF_ROSE, |
1514 | .create = rose_create, | 1515 | .create = rose_create, |
1515 | .owner = THIS_MODULE, | 1516 | .owner = THIS_MODULE, |