We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 55b1804 commit 25aa4efCopy full SHA for 25aa4ef
net/x25/af_x25.c
@@ -507,14 +507,14 @@ static int x25_listen(struct socket *sock, int backlog)
507
struct sock *sk = sock->sk;
508
int rc = -EOPNOTSUPP;
509
510
- lock_kernel();
+ lock_sock(sk);
511
if (sk->sk_state != TCP_LISTEN) {
512
memset(&x25_sk(sk)->dest_addr, 0, X25_ADDR_LEN);
513
sk->sk_max_ack_backlog = backlog;
514
sk->sk_state = TCP_LISTEN;
515
rc = 0;
516
}
517
- unlock_kernel();
+ release_sock(sk);
518
519
return rc;
520
0 commit comments