diff options
author | Rémi Denis-Courmont <remi.denis-courmont@nokia.com> | 2008-12-17 15:48:31 -0800 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2008-12-17 15:48:31 -0800 |
commit | be677730a0ccb6bedced6f65f2ba8f57a3c607ba (patch) | |
tree | 3885b6ed60b72696a8b0102f7f1b85d0dd27617e /net/phonet/socket.c | |
parent | 57c81fffc863fb4c1804bc963bcbfb82d736c6df (diff) | |
download | kernel_samsung_espresso10-be677730a0ccb6bedced6f65f2ba8f57a3c607ba.zip kernel_samsung_espresso10-be677730a0ccb6bedced6f65f2ba8f57a3c607ba.tar.gz kernel_samsung_espresso10-be677730a0ccb6bedced6f65f2ba8f57a3c607ba.tar.bz2 |
Phonet: use atomic for packet TX window
GPRS TX flow control won't need to lock the underlying socket anymore.
Signed-off-by: Rémi Denis-Courmont <remi.denis-courmont@nokia.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net/phonet/socket.c')
-rw-r--r-- | net/phonet/socket.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/net/phonet/socket.c b/net/phonet/socket.c index c75aa5c..ada2a35 100644 --- a/net/phonet/socket.c +++ b/net/phonet/socket.c @@ -227,7 +227,7 @@ static unsigned int pn_socket_poll(struct file *file, struct socket *sock, if (!mask && sk->sk_state == TCP_CLOSE_WAIT) return POLLHUP; - if (sk->sk_state == TCP_ESTABLISHED && pn->tx_credits) + if (sk->sk_state == TCP_ESTABLISHED && atomic_read(&pn->tx_credits)) mask |= POLLOUT | POLLWRNORM | POLLWRBAND; return mask; |