diff options
Diffstat (limited to 'net/bluetooth/af_bluetooth.c')
-rw-r--r-- | net/bluetooth/af_bluetooth.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/net/bluetooth/af_bluetooth.c b/net/bluetooth/af_bluetooth.c index 6fb68a9743af..46e7f86acfc9 100644 --- a/net/bluetooth/af_bluetooth.c +++ b/net/bluetooth/af_bluetooth.c | |||
@@ -210,7 +210,7 @@ struct sock *bt_accept_dequeue(struct sock *parent, struct socket *newsock) | |||
210 | } | 210 | } |
211 | 211 | ||
212 | if (sk->sk_state == BT_CONNECTED || !newsock || | 212 | if (sk->sk_state == BT_CONNECTED || !newsock || |
213 | bt_sk(parent)->defer_setup) { | 213 | test_bit(BT_DEFER_SETUP, &bt_sk(parent)->flags)) { |
214 | bt_accept_unlink(sk); | 214 | bt_accept_unlink(sk); |
215 | if (newsock) | 215 | if (newsock) |
216 | sock_graft(sk, newsock); | 216 | sock_graft(sk, newsock); |
@@ -410,8 +410,8 @@ static inline unsigned int bt_accept_poll(struct sock *parent) | |||
410 | list_for_each_safe(p, n, &bt_sk(parent)->accept_q) { | 410 | list_for_each_safe(p, n, &bt_sk(parent)->accept_q) { |
411 | sk = (struct sock *) list_entry(p, struct bt_sock, accept_q); | 411 | sk = (struct sock *) list_entry(p, struct bt_sock, accept_q); |
412 | if (sk->sk_state == BT_CONNECTED || | 412 | if (sk->sk_state == BT_CONNECTED || |
413 | (bt_sk(parent)->defer_setup && | 413 | (test_bit(BT_SK_DEFER_SETUP, &bt_sk(parent)->flags) && |
414 | sk->sk_state == BT_CONNECT2)) | 414 | sk->sk_state == BT_CONNECT2)) |
415 | return POLLIN | POLLRDNORM; | 415 | return POLLIN | POLLRDNORM; |
416 | } | 416 | } |
417 | 417 | ||
@@ -450,7 +450,7 @@ unsigned int bt_sock_poll(struct file *file, struct socket *sock, poll_table *wa | |||
450 | sk->sk_state == BT_CONFIG) | 450 | sk->sk_state == BT_CONFIG) |
451 | return mask; | 451 | return mask; |
452 | 452 | ||
453 | if (!bt_sk(sk)->suspended && sock_writeable(sk)) | 453 | if (!test_bit(BT_SK_SUSPEND, &bt_sk(sk)->flags) && sock_writeable(sk)) |
454 | mask |= POLLOUT | POLLWRNORM | POLLWRBAND; | 454 | mask |= POLLOUT | POLLWRNORM | POLLWRBAND; |
455 | else | 455 | else |
456 | set_bit(SOCK_ASYNC_NOSPACE, &sk->sk_socket->flags); | 456 | set_bit(SOCK_ASYNC_NOSPACE, &sk->sk_socket->flags); |