[PATCH v2 0/3] Usb gadget ncm code cleanup

2016-09-19 Thread Harish Jenny K N
This patchset consists of some code cleanup in usb gadget ncm code. Note: Testing has only been done on an ARM i.MX6 based platform. --- Change from v1 to v2 Subject line changed on Patch 2. Torsten Polle (3): usb: gadget: NCM: link socket buffers to the device for tx packets usb: gadget:

[PATCH v2 3/3] usb: gadget: NCM: differentiate consumed packets from dropped packets

2016-09-19 Thread Harish Jenny K N
e used for such consumed packets. This separation helps to identify dropped packets. Signed-off-by: Torsten Polle <tpo...@de.adit-jv.com> Signed-off-by: Harish Jenny K N <harish_kand...@mentor.com> --- drivers/usb/gadget/function/f_ncm.c |8 drivers/usb/gadget/function/u_ether.c |

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

2016-09-19 Thread Harish Jenny K N
ned-off-by: Harish Jenny K N <harish_kand...@mentor.com> --- Change from v1 to v2 Subject line changed 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

[PATCH v2 1/3] usb: gadget: NCM: link socket buffers to the device for tx packets

2016-09-19 Thread Harish Jenny K N
From: Torsten Polle <tpo...@de.adit-jv.com> Socket buffers should be linked to the (network) device that allocated the buffers. Signed-off-by: Torsten Polle <tpo...@de.adit-jv.com> Signed-off-by: Harish Jenny K N <harish_kand...@mentor.com> --- drivers/usb/gadget/function/f_n

Re: Gadget regression with u_ether in Linux next

2016-09-18 Thread Harish Jenny K N
> On Saturday 17 September 2016 12:03 AM, Tony Lindgren wrote: > Hi, > > Looks like commit c9ffc78745f8 ("usb: gadget: NCM: Protect dev->port_usb > using dev->lock") causes hangs for me with Linux next. > > Reverting c9ffc78745f8 makes the issues go away, some more info below. > > Regards, >

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

2016-09-16 Thread Harish Jenny K N
>>>>> 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 -- To unsubscribe from this list: send the line "unsubscribe linux-usb" in the

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

2016-09-15 Thread Harish Jenny K N
ned-off-by: Harish Jenny K N <harish_kand...@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/g

[PATCH v1 3/3] usb: gadget: NCM: differentiate consumed packets from dropped packets

2016-09-15 Thread Harish Jenny K N
e used for such consumed packets. This separation helps to identify dropped packets. Signed-off-by: Torsten Polle <tpo...@de.adit-jv.com> Signed-off-by: Harish Jenny K N <harish_kand...@mentor.com> --- drivers/usb/gadget/function/f_ncm.c |8 drivers/usb/gadget/function/u_ether.c |

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

2016-09-15 Thread Harish Jenny K N
From: Torsten Polle <tpo...@de.adit-jv.com> Socket buffers should be linked to the (network) device that allocated the buffers. Signed-off-by: Torsten Polle <tpo...@de.adit-jv.com> Signed-off-by: Harish Jenny K N <harish_kand...@mentor.com> --- drivers/usb/gadget/function/f_n

[PATCH v1 0/3] Usb gadget ncm code cleanup

2016-09-15 Thread Harish Jenny K N
This patchset consists of some code cleanup in usb gadget ncm code. Note: Testing has only been done on an ARM i.MX6 based platform. Torsten Polle (3): usb: gadget: NCM: link socket buffers to the device for tx packets usb: gadget: NCM: link socket buffers to the device for received

[PATCH v1 2/2] usb: gadget: NCM: Protect dev->port_usb using dev->lock

2016-09-09 Thread Harish Jenny K N
This commit incorporates findings from https://lkml.org/lkml/2016/4/25/594 The function has been modified to make sure we hold the dev lock when accessing the net device pointer. Acked-by: Jim Baxter <jim_bax...@mentor.com> Signed-off-by: Harish Jenny K N <harish_kand...@mentor.com>

[PATCH v1 0/2] usb: gadget: NCM: NULL pointer dereference in eth_start_xmit

2016-09-09 Thread Harish Jenny K N
by another commit 88c09eacf560c3303d0ee8cf91b8b7ff7f000350. Hence this patchset only adds the remaining findings. Harish Jenny K N (2): usb: gadget: u_ether: fix another dereference after null check usb: gadget: NCM: Protect dev->port_usb using dev->lock drivers/usb/gadget/fu

[PATCH v1 1/2] usb: gadget: u_ether: fix another dereference after null check

2016-09-09 Thread Harish Jenny K N
dev->port_usb is checked for null pointer previously, so dev->port_usb might be null during no zlp check, fix it by adding null pointer check. Acked-by: Jim Baxter <jim_bax...@mentor.com> Signed-off-by: Harish Jenny K N <harish_kand...@mentor.com> --- drivers/usb/gadget/functio

[PATCH v1 0/1] usb: gadget: f_fs: Stop ffs_closed NULL pointers

2016-09-08 Thread Harish Jenny K N
This patchset fixes the crash in ffs_closed during a disconnect of a USB composite FFS session. The issue was caused by the use of an outdated pointer in ffs_closed which had been deleted and not Nulled. Note: Testing has only been done on an ARM i.MX6 based platform. Jim Baxter (1): usb:

[PATCH v1 1/1] usb: gadget: f_fs: Stop ffs_closed NULL pointers.

2016-09-08 Thread Harish Jenny K N
ULL pointer dereference" error when using the data in ffs_data::private_data. This clears this pointer during the ffs_free_dev clean up function. Signed-off-by: Jim Baxter <jim_bax...@mentor.com> Signed-off-by: Jiada Wang <jiada_w...@mentor.com> Signed-off-by: Harish Jenny K