netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH RFC] tun, macvtap: higher order allocations for skbs
@ 2015-06-18 10:20 Michael S. Tsirkin
  2015-06-18 10:54 ` Christian Borntraeger
  2015-06-29  4:50 ` Jason Wang
  0 siblings, 2 replies; 5+ messages in thread
From: Michael S. Tsirkin @ 2015-06-18 10:20 UTC (permalink / raw)
  To: linux-kernel; +Cc: David S. Miller, Jason Wang, netdev

Needs more testing. Anyone see anything wrong with this?

Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
---
 drivers/net/macvtap.c | 2 +-
 drivers/net/tun.c     | 2 +-
 2 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/drivers/net/macvtap.c b/drivers/net/macvtap.c
index 928f3f4..80e87e4 100644
--- a/drivers/net/macvtap.c
+++ b/drivers/net/macvtap.c
@@ -610,7 +610,7 @@ static inline struct sk_buff *macvtap_alloc_skb(struct sock *sk, size_t prepad,
 		linear = len;
 
 	skb = sock_alloc_send_pskb(sk, prepad + linear, len - linear, noblock,
-				   err, 0);
+				   err, 1);
 	if (!skb)
 		return NULL;
 
diff --git a/drivers/net/tun.c b/drivers/net/tun.c
index cb376b2d..8f2f1e5 100644
--- a/drivers/net/tun.c
+++ b/drivers/net/tun.c
@@ -1069,7 +1069,7 @@ static struct sk_buff *tun_alloc_skb(struct tun_file *tfile,
 		linear = len;
 
 	skb = sock_alloc_send_pskb(sk, prepad + linear, len - linear, noblock,
-				   &err, 0);
+				   &err, 1);
 	if (!skb)
 		return ERR_PTR(err);
 
-- 
MST

^ permalink raw reply related	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2015-06-29 10:30 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2015-06-18 10:20 [PATCH RFC] tun, macvtap: higher order allocations for skbs Michael S. Tsirkin
2015-06-18 10:54 ` Christian Borntraeger
2015-06-18 11:13   ` Michael S. Tsirkin
2015-06-29  4:50 ` Jason Wang
2015-06-29 10:30   ` Jason Wang

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).