Re: [PATCH] wan-cosa: Use memdup_user() rather than duplicating its implementation

2016-08-24 Thread Jan Kasprzak
Hello, SF Markus Elfring wrote: : From: Markus Elfring : Date: Sat, 20 Aug 2016 10:10:12 +0200 : : Reuse existing functionality from memdup_user() instead of keeping : duplicate source code. : : This issue was detected by using the Coccinelle software. What about the GFP_DMA at

Re: [PATCH] wan-cosa: Use memdup_user() rather than duplicating its implementation

2016-08-20 Thread David Miller
From: Christophe JAILLET Date: Sat, 20 Aug 2016 10:42:54 +0200 > Le 20/08/2016 à 10:25, SF Markus Elfring a écrit : >> @@ -875,16 +875,10 @@ static ssize_t cosa_write(struct file *file, >> if (count > COSA_MTU) >> count = COSA_MTU; >> >> -/* Allocate the buffer */ >> -

Re: [PATCH] wan-cosa: Use memdup_user() rather than duplicating its implementation

2016-08-20 Thread Christophe JAILLET
Le 20/08/2016 à 10:25, SF Markus Elfring a écrit : From: Markus Elfring Date: Sat, 20 Aug 2016 10:10:12 +0200 Reuse existing functionality from memdup_user() instead of keeping duplicate source code. This issue was detected by using the Coccinelle software. Signed-off-by: Markus Elfring ---

[PATCH] wan-cosa: Use memdup_user() rather than duplicating its implementation

2016-08-20 Thread SF Markus Elfring
From: Markus Elfring Date: Sat, 20 Aug 2016 10:10:12 +0200 Reuse existing functionality from memdup_user() instead of keeping duplicate source code. This issue was detected by using the Coccinelle software. Signed-off-by: Markus Elfring --- drivers/net/wan/cosa.c | 12 +++- 1 file cha

Re: [PATCH] wan: cosa: use memdup_user().

2016-05-23 Thread David Miller
From: Muhammad Falak R Wani Date: Fri, 20 May 2016 17:50:06 +0530 > Use memdup_user to duplicate a memory region from user-space to > kernel-space, instead of open coding using kmalloc & copy_from_user. > > Signed-off-by: Muhammad Falak R Wani > --- > drivers/net/wan/cosa.c | 11 +++ >

[PATCH] wan: cosa: use memdup_user().

2016-05-20 Thread Muhammad Falak R Wani
Use memdup_user to duplicate a memory region from user-space to kernel-space, instead of open coding using kmalloc & copy_from_user. Signed-off-by: Muhammad Falak R Wani --- drivers/net/wan/cosa.c | 11 +++ 1 file changed, 3 insertions(+), 8 deletions(-) diff --git a/drivers/net/wan/cos