diff options
Diffstat (limited to 'net/x25')
-rw-r--r-- | net/x25/af_x25.c | 14 |
1 files changed, 5 insertions, 9 deletions
diff --git a/net/x25/af_x25.c b/net/x25/af_x25.c index 020d73cc84..72b6ff3299 100644 --- a/net/x25/af_x25.c +++ b/net/x25/af_x25.c | |||
@@ -37,6 +37,7 @@ | |||
37 | 37 | ||
38 | #include <linux/config.h> | 38 | #include <linux/config.h> |
39 | #include <linux/module.h> | 39 | #include <linux/module.h> |
40 | #include <linux/capability.h> | ||
40 | #include <linux/errno.h> | 41 | #include <linux/errno.h> |
41 | #include <linux/kernel.h> | 42 | #include <linux/kernel.h> |
42 | #include <linux/sched.h> | 43 | #include <linux/sched.h> |
@@ -64,7 +65,7 @@ int sysctl_x25_ack_holdback_timeout = X25_DEFAULT_T2; | |||
64 | HLIST_HEAD(x25_list); | 65 | HLIST_HEAD(x25_list); |
65 | DEFINE_RWLOCK(x25_list_lock); | 66 | DEFINE_RWLOCK(x25_list_lock); |
66 | 67 | ||
67 | static struct proto_ops x25_proto_ops; | 68 | static const struct proto_ops x25_proto_ops; |
68 | 69 | ||
69 | static struct x25_address null_x25_address = {" "}; | 70 | static struct x25_address null_x25_address = {" "}; |
70 | 71 | ||
@@ -540,12 +541,7 @@ static struct sock *x25_make_new(struct sock *osk) | |||
540 | sk->sk_state = TCP_ESTABLISHED; | 541 | sk->sk_state = TCP_ESTABLISHED; |
541 | sk->sk_sleep = osk->sk_sleep; | 542 | sk->sk_sleep = osk->sk_sleep; |
542 | sk->sk_backlog_rcv = osk->sk_backlog_rcv; | 543 | sk->sk_backlog_rcv = osk->sk_backlog_rcv; |
543 | 544 | sock_copy_flags(sk, osk); | |
544 | if (sock_flag(osk, SOCK_ZAPPED)) | ||
545 | sock_set_flag(sk, SOCK_ZAPPED); | ||
546 | |||
547 | if (sock_flag(osk, SOCK_DBG)) | ||
548 | sock_set_flag(sk, SOCK_DBG); | ||
549 | 545 | ||
550 | ox25 = x25_sk(osk); | 546 | ox25 = x25_sk(osk); |
551 | x25->t21 = ox25->t21; | 547 | x25->t21 = ox25->t21; |
@@ -1378,7 +1374,7 @@ static int x25_ioctl(struct socket *sock, unsigned int cmd, unsigned long arg) | |||
1378 | } | 1374 | } |
1379 | 1375 | ||
1380 | default: | 1376 | default: |
1381 | rc = dev_ioctl(cmd, argp); | 1377 | rc = -ENOIOCTLCMD; |
1382 | break; | 1378 | break; |
1383 | } | 1379 | } |
1384 | 1380 | ||
@@ -1391,7 +1387,7 @@ static struct net_proto_family x25_family_ops = { | |||
1391 | .owner = THIS_MODULE, | 1387 | .owner = THIS_MODULE, |
1392 | }; | 1388 | }; |
1393 | 1389 | ||
1394 | static struct proto_ops SOCKOPS_WRAPPED(x25_proto_ops) = { | 1390 | static const struct proto_ops SOCKOPS_WRAPPED(x25_proto_ops) = { |
1395 | .family = AF_X25, | 1391 | .family = AF_X25, |
1396 | .owner = THIS_MODULE, | 1392 | .owner = THIS_MODULE, |
1397 | .release = x25_release, | 1393 | .release = x25_release, |