Julia Lawall 99bf236612 drivers/net/usb: Use kmemdup
Use kmemdup when some other buffer is immediately copied into the
allocated region.

A simplified version of the semantic patch that makes this change is as
follows: (http://coccinelle.lip6.fr/)

// <smpl>
@@
expression from,to,size,flag;
statement S;
@@

-  to = \(kmalloc\|kzalloc\)(size,flag);
+  to = kmemdup(from,size,flag);
   if (to==NULL || ...) S
-  memcpy(to, from, size);
// </smpl>

Signed-off-by: Julia Lawall <julia@diku.dk>
Signed-off-by: David S. Miller <davem@davemloft.net>
2010-05-17 17:44:47 -07:00
..
2010-04-24 11:31:26 -07:00
2010-05-17 17:44:47 -07:00
2010-04-28 01:07:29 -06:00
2010-04-30 09:25:12 -07:00
2010-04-24 11:31:25 -07:00
2010-05-07 14:01:17 -07:00