aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/net/pppox.c
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/net/pppox.c')
-rw-r--r--drivers/net/pppox.c11
1 files changed, 4 insertions, 7 deletions
diff --git a/drivers/net/pppox.c b/drivers/net/pppox.c
index f3e47d0c2b3c..25c52b55c38f 100644
--- a/drivers/net/pppox.c
+++ b/drivers/net/pppox.c
@@ -73,7 +73,7 @@ int pppox_ioctl(struct socket *sock, unsigned int cmd, unsigned long arg)
73{ 73{
74 struct sock *sk = sock->sk; 74 struct sock *sk = sock->sk;
75 struct pppox_sock *po = pppox_sk(sk); 75 struct pppox_sock *po = pppox_sk(sk);
76 int rc = 0; 76 int rc;
77 77
78 lock_sock(sk); 78 lock_sock(sk);
79 79
@@ -94,12 +94,9 @@ int pppox_ioctl(struct socket *sock, unsigned int cmd, unsigned long arg)
94 break; 94 break;
95 } 95 }
96 default: 96 default:
97 if (pppox_protos[sk->sk_protocol]->ioctl) 97 rc = pppox_protos[sk->sk_protocol]->ioctl ?
98 rc = pppox_protos[sk->sk_protocol]->ioctl(sock, cmd, 98 pppox_protos[sk->sk_protocol]->ioctl(sock, cmd, arg) : -ENOTTY;
99 arg); 99 }
100
101 break;
102 };
103 100
104 release_sock(sk); 101 release_sock(sk);
105 return rc; 102 return rc;