Received: by 10.223.148.5 with SMTP id 5csp6276943wrq; Wed, 17 Jan 2018 11:37:23 -0800 (PST) X-Google-Smtp-Source: ACJfBovqGWSO4cKMzCmFhdM5ZefXnNvAj/LwsaFEuv6Pb3SxR+1gGjWVwlTJgIQGAFTKjrtRmL+3 X-Received: by 10.99.110.78 with SMTP id j75mr33421724pgc.96.1516217843107; Wed, 17 Jan 2018 11:37:23 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1516217843; cv=none; d=google.com; s=arc-20160816; b=M9xvJQNE4lUmWKpawM2VnxNWqVkVPXi++Jy4B67U7Wry62A0f1WSEWBL6Xsubm3T13 IdXh0c1Xw9BShsUr37x+SoQZ+ddyCKLZqW615nQoFDvHQ57NgoPVFB5iHfq2dGoeLR2j I3sYpfQ/UJ/EA47u7K0ydCrMhFhc35usTUVSDX5TFUUL7CDOwAFgUBKVKhPeP+EOy5Sd NThJ559A17PhsJGijn6Uowcuxc/cFVNgOfi2ISlgPZQmku9NG8lCHuCoKxcEhY2F+2oQ rihH8IPctQb5KPRlhwn2ohaFIlTSjdP4b/TaTOnMlJRQOcwLi9r7Yc0r0z6aW2XwPLC0 FBCQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:references:in-reply-to:message-id:date :subject:cc:to:from:dkim-signature:arc-authentication-results; bh=MqcnWC+oKvChrPoG0D2aK+fEMIWN2CkFDqjMkzX65I0=; b=deysYDRlsfCWSKHogFUDo4qpG3Fr12Kj4BeiqXXik0tHVlcSViUNG6ALdJoO1ibfRB scqA+OEGF3kBvNP7RCgmE1F0ZfqRDdllb+Lauf3/BkUP/0eBlbDUWKtbrXPaQNtFNcB5 F+Ff+qewAccItjWI6CmURjgwr7D5Dq6mkAPkOIVOJw8J0GnBUcaXLCkWXE2lkXPhNYF7 TWYU7KRSM+ftW+Q4F8e1+3XFtncB/L+hP39rGsyNl7QKOEeNVOqdKExPEJpGJiGB7xZ1 Fny9Tby3KSKrojYNdq20LHShaOtDoRGjnqWbQe1cg55OraM3Xi+l9c2B/op0NNx+4fNv VOyA== ARC-Authentication-Results: i=1; mx.google.com; dkim=fail header.i=@infradead.org header.s=bombadil.20170209 header.b=H4rt8VtU; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id q7si4288421pgt.517.2018.01.17.11.37.08; Wed, 17 Jan 2018 11:37:23 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=fail header.i=@infradead.org header.s=bombadil.20170209 header.b=H4rt8VtU; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752769AbeAQT3F (ORCPT + 99 others); Wed, 17 Jan 2018 14:29:05 -0500 Received: from bombadil.infradead.org ([65.50.211.133]:60273 "EHLO bombadil.infradead.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1753764AbeAQT3B (ORCPT ); Wed, 17 Jan 2018 14:29:01 -0500 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=infradead.org; s=bombadil.20170209; h=References:In-Reply-To:Message-Id: Date:Subject:Cc:To:From:Sender:Reply-To:MIME-Version:Content-Type: Content-Transfer-Encoding:Content-ID:Content-Description:Resent-Date: Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:List-Id: List-Help:List-Unsubscribe:List-Subscribe:List-Post:List-Owner:List-Archive; bh=MqcnWC+oKvChrPoG0D2aK+fEMIWN2CkFDqjMkzX65I0=; b=H4rt8VtUY9an516h9tqw2Y4mw AGP1h3QHG00N3jJrq5GnxxcmZ4zILtZ8ZgN82ZTB1PZtm0Te0NG1BbB78l3wT8JFRzDB78QWc9yDj Cxmb8Mv+NGWMbVGwmZuXGSp3kx0JT+rY7XnE7t/0QXsmQwW8nHhfdfG440ic7j2ZdMhonyyRi7o92 VywJwbppdRU37t+rfquZNyZIFcKvm3vzwkUjTBHTij6j6dpzSVVj87u9gAnQfuUGpXMijcliesPA7 GLQUua7JInhiq1bYu5EpaElXrmwafOQymlpzKrZTrlWTf/oAJBz+8luAFspdsBUzmeriyodL0St1K DOf0OxGFw==; Received: from 77.117.185.35.wireless.dyn.drei.com ([77.117.185.35] helo=localhost) by bombadil.infradead.org with esmtpsa (Exim 4.89 #1 (Red Hat Linux)) id 1ebtON-0003Bf-HA; Wed, 17 Jan 2018 19:29:00 +0000 From: Christoph Hellwig To: viro@zeniv.linux.org.uk Cc: Avi Kivity , linux-aio@kvack.org, linux-fsdevel@vger.kernel.org, netdev@vger.kernel.org, linux-api@vger.kernel.org, linux-kernel@vger.kernel.org Subject: [PATCH 21/36] net/dccp: convert to ->poll_mask Date: Wed, 17 Jan 2018 20:27:27 +0100 Message-Id: <20180117192742.710-22-hch@lst.de> X-Mailer: git-send-email 2.14.2 In-Reply-To: <20180117192742.710-1-hch@lst.de> References: <20180117192742.710-1-hch@lst.de> X-SRS-Rewrite: SMTP reverse-path rewritten from by bombadil.infradead.org. See http://www.infradead.org/rpr.html Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Signed-off-by: Christoph Hellwig --- net/dccp/dccp.h | 3 +-- net/dccp/ipv4.c | 2 +- net/dccp/ipv6.c | 2 +- net/dccp/proto.c | 13 ++----------- 4 files changed, 5 insertions(+), 15 deletions(-) diff --git a/net/dccp/dccp.h b/net/dccp/dccp.h index f91e3816806b..0ea2ee56ac1b 100644 --- a/net/dccp/dccp.h +++ b/net/dccp/dccp.h @@ -316,8 +316,7 @@ int dccp_recvmsg(struct sock *sk, struct msghdr *msg, size_t len, int nonblock, int flags, int *addr_len); void dccp_shutdown(struct sock *sk, int how); int inet_dccp_listen(struct socket *sock, int backlog); -__poll_t dccp_poll(struct file *file, struct socket *sock, - poll_table *wait); +__poll_t dccp_poll_mask(struct socket *sock, __poll_t events); int dccp_v4_connect(struct sock *sk, struct sockaddr *uaddr, int addr_len); void dccp_req_err(struct sock *sk, u64 seq); diff --git a/net/dccp/ipv4.c b/net/dccp/ipv4.c index e65fcb45c3f6..e8476f319efd 100644 --- a/net/dccp/ipv4.c +++ b/net/dccp/ipv4.c @@ -983,7 +983,7 @@ static const struct proto_ops inet_dccp_ops = { .accept = inet_accept, .getname = inet_getname, /* FIXME: work on tcp_poll to rename it to inet_csk_poll */ - .poll = dccp_poll, + .poll_mask = dccp_poll_mask, .ioctl = inet_ioctl, /* FIXME: work on inet_listen to rename it to sock_common_listen */ .listen = inet_dccp_listen, diff --git a/net/dccp/ipv6.c b/net/dccp/ipv6.c index 5df7857fc0f3..f0aac8e4b888 100644 --- a/net/dccp/ipv6.c +++ b/net/dccp/ipv6.c @@ -1069,7 +1069,7 @@ static const struct proto_ops inet6_dccp_ops = { .socketpair = sock_no_socketpair, .accept = inet_accept, .getname = inet6_getname, - .poll = dccp_poll, + .poll_mask = dccp_poll_mask, .ioctl = inet6_ioctl, .listen = inet_dccp_listen, .shutdown = inet_shutdown, diff --git a/net/dccp/proto.c b/net/dccp/proto.c index 8b8db3d481bd..11f91fbe7359 100644 --- a/net/dccp/proto.c +++ b/net/dccp/proto.c @@ -311,20 +311,11 @@ int dccp_disconnect(struct sock *sk, int flags) EXPORT_SYMBOL_GPL(dccp_disconnect); -/* - * Wait for a DCCP event. - * - * Note that we don't need to lock the socket, as the upper poll layers - * take care of normal races (between the test and the event) and we don't - * go look at any of the socket buffers directly. - */ -__poll_t dccp_poll(struct file *file, struct socket *sock, - poll_table *wait) +__poll_t dccp_poll_mask(struct socket *sock, __poll_t events) { __poll_t mask; struct sock *sk = sock->sk; - sock_poll_wait(file, sk_sleep(sk), wait); if (sk->sk_state == DCCP_LISTEN) return inet_csk_listen_poll(sk); @@ -366,7 +357,7 @@ __poll_t dccp_poll(struct file *file, struct socket *sock, return mask; } -EXPORT_SYMBOL_GPL(dccp_poll); +EXPORT_SYMBOL_GPL(dccp_poll_mask); int dccp_ioctl(struct sock *sk, int cmd, unsigned long arg) { -- 2.14.2