aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/net/wireless/ipw2100.c
diff options
context:
space:
mode:
authorEric Sesterhenn <snakebyte@gmx.de>2006-10-23 16:20:15 -0400
committerJeff Garzik <jeff@garzik.org>2006-12-02 00:12:01 -0500
commitc3a9392e4f3b9d97803b067871d66bc143369dbf (patch)
tree1558190c7a9c0325f5be90f4b9dd375cd74e5b51 /drivers/net/wireless/ipw2100.c
parentbf793295e1090af84972750898bf8470df5e5419 (diff)
[PATCH] kmemdup() cleanup in drivers/net
hi, replace open coded kmemdup() to save some screen space, and allow inlining/not inlining to be triggered by gcc. Signed-off-by: Eric Sesterhenn <snakebyte@gmx.de> Signed-off-by: Jeff Garzik <jeff@garzik.org>
Diffstat (limited to 'drivers/net/wireless/ipw2100.c')
-rw-r--r--drivers/net/wireless/ipw2100.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/drivers/net/wireless/ipw2100.c b/drivers/net/wireless/ipw2100.c
index 4e4eaa2a99ca..5bf4d4119c3d 100644
--- a/drivers/net/wireless/ipw2100.c
+++ b/drivers/net/wireless/ipw2100.c
@@ -7568,11 +7568,10 @@ static int ipw2100_wx_set_genie(struct net_device *dev,
7568 return -EINVAL; 7568 return -EINVAL;
7569 7569
7570 if (wrqu->data.length) { 7570 if (wrqu->data.length) {
7571 buf = kmalloc(wrqu->data.length, GFP_KERNEL); 7571 buf = kmemdup(extra, wrqu->data.length, GFP_KERNEL);
7572 if (buf == NULL) 7572 if (buf == NULL)
7573 return -ENOMEM; 7573 return -ENOMEM;
7574 7574
7575 memcpy(buf, extra, wrqu->data.length);
7576 kfree(ieee->wpa_ie); 7575 kfree(ieee->wpa_ie);
7577 ieee->wpa_ie = buf; 7576 ieee->wpa_ie = buf;
7578 ieee->wpa_ie_len = wrqu->data.length; 7577 ieee->wpa_ie_len = wrqu->data.length;