Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.kernel > #1484221 > unrolled thread

[PATCH v1 2/3] usb: gadget: NCM: link socket buffers to the device for received packets

Started byHarish Jenny K N <harish_kandiga@mentor.com>
First post2016-09-15 16:30 +0200
Last post2016-09-16 12:00 +0200
Articles 3 — 2 participants

Back to article view | Back to linux.kernel

This discussion starts older than the indexed window; earlier articles aren't shown. The article labeled Started by below is the oldest one visible, not the original post.


Contents

  [PATCH v1 2/3] usb: gadget: NCM: link socket buffers to the device for received packets Harish Jenny K N <harish_kandiga@mentor.com> - 2016-09-15 16:30 +0200
    Re: [PATCH v1 2/3] usb: gadget: NCM: link socket buffers to the device for received packets Yauheni Kaliuta <yauheni.kaliuta@redhat.com> - 2016-09-15 20:40 +0200
      Re: [PATCH v1 2/3] usb: gadget: NCM: link socket buffers to the  device for received packets Harish Jenny K N <harish_kandiga@mentor.com> - 2016-09-16 12:00 +0200

#1484221 — [PATCH v1 2/3] usb: gadget: NCM: link socket buffers to the device for received packets

FromHarish Jenny K N <harish_kandiga@mentor.com>
Date2016-09-15 16:30 +0200
Subject[PATCH v1 2/3] usb: gadget: NCM: link socket buffers to the device for received packets
Message-ID<shFPQ-88Q-9@gated-at.bofh.it>
From: Torsten Polle <tpolle@de.adit-jv.com>

Socket buffers should be linked to the (network) device that allocated
the buffers. __netdev_alloc_skb performs this task.

Signed-off-by: Torsten Polle <tpolle@de.adit-jv.com>
Signed-off-by: Jim Baxter <jim_baxter@mentor.com>
Signed-off-by: Harish Jenny K N <harish_kandiga@mentor.com>
---
 drivers/usb/gadget/function/u_ether.c |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/usb/gadget/function/u_ether.c b/drivers/usb/gadget/function/u_ether.c
index 8cb0803..d8593c7 100644
--- a/drivers/usb/gadget/function/u_ether.c
+++ b/drivers/usb/gadget/function/u_ether.c
@@ -224,7 +224,7 @@ static void defer_kevent(struct eth_dev *dev, int flag)
 	if (dev->port_usb->is_fixed)
 		size = max_t(size_t, size, dev->port_usb->fixed_out_len);
 
-	skb = alloc_skb(size + NET_IP_ALIGN, gfp_flags);
+	skb = __netdev_alloc_skb(dev->net, size + NET_IP_ALIGN, gfp_flags);
 	if (skb == NULL) {
 		DBG(dev, "no rx skb\n");
 		goto enomem;
-- 
1.7.9.5

[toc] | [next] | [standalone]


#1484457

FromYauheni Kaliuta <yauheni.kaliuta@redhat.com>
Date2016-09-15 20:40 +0200
Message-ID<shJJL-28Z-23@gated-at.bofh.it>
In reply to#1484221
Hi, Harish!

>>>>> On Thu, 15 Sep 2016 16:22:57 +0200, Harish Jenny K N  wrote:

 > diff --git a/drivers/usb/gadget/function/u_ether.c b/drivers/usb/gadget/function/u_ether.c
                                           ^^^^^^^
Is subject a bit misleading, it's more generic, then NCM?

-- 
WBR,
Yauheni Kaliuta

[toc] | [prev] | [next] | [standalone]


#1484850 — Re: [PATCH v1 2/3] usb: gadget: NCM: link socket buffers to the device for received packets

FromHarish Jenny K N <harish_kandiga@mentor.com>
Date2016-09-16 12:00 +0200
SubjectRe: [PATCH v1 2/3] usb: gadget: NCM: link socket buffers to the device for received packets
Message-ID<shY65-2Wu-1@gated-at.bofh.it>
In reply to#1484457
>>>>> On Thursday 15 September 2016 08:35 PM, Yauheni Kaliuta wrote:

>Is subject a bit misleading, it's more generic, then NCM?

Agreed. I will submit v2 patchset.

WBR,
Harish Jenny K N

[toc] | [prev] | [standalone]


Back to top | Article view | linux.kernel


csiph-web