Commit 9490e40a authored by Christoph Hellwig's avatar Christoph Hellwig

net/caif: convert to ->poll_mask

Signed-off-by: default avatarChristoph Hellwig <hch@lst.de>
parent 17112d80
...@@ -934,15 +934,11 @@ static int caif_release(struct socket *sock) ...@@ -934,15 +934,11 @@ static int caif_release(struct socket *sock)
} }
/* Copied from af_unix.c:unix_poll(), added CAIF tx_flow handling */ /* Copied from af_unix.c:unix_poll(), added CAIF tx_flow handling */
static __poll_t caif_poll(struct file *file, static __poll_t caif_poll_mask(struct socket *sock, __poll_t events)
struct socket *sock, poll_table *wait)
{ {
struct sock *sk = sock->sk; struct sock *sk = sock->sk;
__poll_t mask;
struct caifsock *cf_sk = container_of(sk, struct caifsock, sk); struct caifsock *cf_sk = container_of(sk, struct caifsock, sk);
__poll_t mask = 0;
sock_poll_wait(file, sk_sleep(sk), wait);
mask = 0;
/* exceptional events? */ /* exceptional events? */
if (sk->sk_err) if (sk->sk_err)
...@@ -976,7 +972,7 @@ static const struct proto_ops caif_seqpacket_ops = { ...@@ -976,7 +972,7 @@ static const struct proto_ops caif_seqpacket_ops = {
.socketpair = sock_no_socketpair, .socketpair = sock_no_socketpair,
.accept = sock_no_accept, .accept = sock_no_accept,
.getname = sock_no_getname, .getname = sock_no_getname,
.poll = caif_poll, .poll_mask = caif_poll_mask,
.ioctl = sock_no_ioctl, .ioctl = sock_no_ioctl,
.listen = sock_no_listen, .listen = sock_no_listen,
.shutdown = sock_no_shutdown, .shutdown = sock_no_shutdown,
...@@ -997,7 +993,7 @@ static const struct proto_ops caif_stream_ops = { ...@@ -997,7 +993,7 @@ static const struct proto_ops caif_stream_ops = {
.socketpair = sock_no_socketpair, .socketpair = sock_no_socketpair,
.accept = sock_no_accept, .accept = sock_no_accept,
.getname = sock_no_getname, .getname = sock_no_getname,
.poll = caif_poll, .poll_mask = caif_poll_mask,
.ioctl = sock_no_ioctl, .ioctl = sock_no_ioctl,
.listen = sock_no_listen, .listen = sock_no_listen,
.shutdown = sock_no_shutdown, .shutdown = sock_no_shutdown,
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment