From: Jason Wang <jasowang@redhat.com>
To: davem@davemloft.net, mst@redhat.com, netdev@vger.kernel.org,
linux-kernel@vger.kernel.org
Cc: Jason Wang <jasowang@redhat.com>
Subject: [PATCH net-next 2/6] tuntap: socket rx busy polling support
Date: Thu, 31 Mar 2016 13:50:35 +0800 [thread overview]
Message-ID: <1459403439-6011-3-git-send-email-jasowang@redhat.com> (raw)
In-Reply-To: <1459403439-6011-1-git-send-email-jasowang@redhat.com>
Signed-off-by: Jason Wang <jasowang@redhat.com>
---
drivers/net/tun.c | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/drivers/net/tun.c b/drivers/net/tun.c
index afdf950..950faf5 100644
--- a/drivers/net/tun.c
+++ b/drivers/net/tun.c
@@ -69,6 +69,7 @@
#include <net/netns/generic.h>
#include <net/rtnetlink.h>
#include <net/sock.h>
+#include <net/busy_poll.h>
#include <linux/seq_file.h>
#include <linux/uio.h>
@@ -871,6 +872,7 @@ static netdev_tx_t tun_net_xmit(struct sk_buff *skb, struct net_device *dev)
nf_reset(skb);
+ sk_mark_napi_id(tfile->socket.sk, skb);
/* Enqueue packet */
skb_queue_tail(&tfile->socket.sk->sk_receive_queue, skb);
@@ -878,7 +880,6 @@ static netdev_tx_t tun_net_xmit(struct sk_buff *skb, struct net_device *dev)
if (tfile->flags & TUN_FASYNC)
kill_fasync(&tfile->fasync, SIGIO, POLL_IN);
tfile->socket.sk->sk_data_ready(tfile->socket.sk);
-
rcu_read_unlock();
return NETDEV_TX_OK;
--
2.5.0
next prev parent reply other threads:[~2016-03-31 5:50 UTC|newest]
Thread overview: 16+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-03-31 5:50 [PATCH net-next 0/6] net device rx busy polling support in vhost_net Jason Wang
2016-03-31 5:50 ` [PATCH net-next 1/6] net: skbuff: don't use union for napi_id and sender_cpu Jason Wang
2016-03-31 10:32 ` Eric Dumazet
2016-03-31 20:01 ` David Miller
2016-04-01 2:46 ` Jason Wang
2016-04-01 2:13 ` Jason Wang
2016-04-01 2:55 ` Eric Dumazet
2016-04-01 4:49 ` Jason Wang
2016-04-01 13:04 ` Eric Dumazet
2016-04-05 15:05 ` Michael S. Tsirkin
2016-04-06 6:22 ` Jason Wang
2016-03-31 5:50 ` Jason Wang [this message]
2016-03-31 5:50 ` [PATCH net-next 3/6] macvtap: socket rx busy polling support Jason Wang
2016-03-31 5:50 ` [PATCH net-next 4/6] net: core: factor out core busy polling logic to sk_busy_loop_once() Jason Wang
2016-03-31 5:50 ` [PATCH net-next 5/6] net: export napi_by_id() Jason Wang
2016-03-31 5:50 ` [PATCH net-next 6/6] vhost_net: net device rx busy polling support Jason Wang
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1459403439-6011-3-git-send-email-jasowang@redhat.com \
--to=jasowang@redhat.com \
--cc=davem@davemloft.net \
--cc=linux-kernel@vger.kernel.org \
--cc=mst@redhat.com \
--cc=netdev@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).