Re: [PATCH] net: usb: ch9200: use kmemdup

2016-05-20 Thread David Miller
From: Muhammad Falak R Wani Date: Thu, 19 May 2016 19:26:50 +0530 > Use kmemdup when some other buffer is immediately copied into allocated > region. It replaces call to allocation followed by memcpy, by a single > call to kmemdup. > > Signed-off-by: Muhammad Falak R Wani Applied.

[PATCH] net: usb: ch9200: use kmemdup

2016-05-19 Thread Muhammad Falak R Wani
Use kmemdup when some other buffer is immediately copied into allocated region. It replaces call to allocation followed by memcpy, by a single call to kmemdup. Signed-off-by: Muhammad Falak R Wani --- drivers/net/usb/ch9200.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/

Re: [PATCH] net: usb: ch9200: use kmemdup instead of kmalloc + memcpy

2015-11-29 Thread David Miller
From: Anup Limbu Date: Wed, 25 Nov 2015 15:37:21 +0530 > replace kmalloc + memset with kmemdup > > Signed-off-by: Anup Limbu I agree with Bjorn that this microturfing cleanup misses the real higher level opportunity to use the usbnet_read_cmd() and usbnet_write_cmd() helpers that already exist

Re: [PATCH] net: usb: ch9200: use kmemdup instead of kmalloc + memcpy

2015-11-25 Thread Bjørn Mork
Anup Limbu writes: > replace kmalloc + memset with kmemdup > > Signed-off-by: Anup Limbu > --- > drivers/net/usb/ch9200.c | 3 +-- > 1 file changed, 1 insertion(+), 2 deletions(-) > > diff --git a/drivers/net/usb/ch9200.c b/drivers/net/usb/ch9200.c > index 5e151e6..8a40202 100644 > --- a/driver

[PATCH] net: usb: ch9200: use kmemdup instead of kmalloc + memcpy

2015-11-25 Thread Anup Limbu
replace kmalloc + memset with kmemdup Signed-off-by: Anup Limbu --- drivers/net/usb/ch9200.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/drivers/net/usb/ch9200.c b/drivers/net/usb/ch9200.c index 5e151e6..8a40202 100644 --- a/drivers/net/usb/ch9200.c +++ b/drivers/net/us