aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--drivers/net/wireless/ipw2200.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/drivers/net/wireless/ipw2200.c b/drivers/net/wireless/ipw2200.c
index c692d01a76ca..b2e144b7f4a0 100644
--- a/drivers/net/wireless/ipw2200.c
+++ b/drivers/net/wireless/ipw2200.c
@@ -11129,14 +11129,13 @@ static int ipw_up(struct ipw_priv *priv)
11129 return -EIO; 11129 return -EIO;
11130 11130
11131 if (cmdlog && !priv->cmdlog) { 11131 if (cmdlog && !priv->cmdlog) {
11132 priv->cmdlog = kmalloc(sizeof(*priv->cmdlog) * cmdlog, 11132 priv->cmdlog = kcalloc(cmdlog, sizeof(*priv->cmdlog),
11133 GFP_KERNEL); 11133 GFP_KERNEL);
11134 if (priv->cmdlog == NULL) { 11134 if (priv->cmdlog == NULL) {
11135 IPW_ERROR("Error allocating %d command log entries.\n", 11135 IPW_ERROR("Error allocating %d command log entries.\n",
11136 cmdlog); 11136 cmdlog);
11137 return -ENOMEM; 11137 return -ENOMEM;
11138 } else { 11138 } else {
11139 memset(priv->cmdlog, 0, sizeof(*priv->cmdlog) * cmdlog);
11140 priv->cmdlog_len = cmdlog; 11139 priv->cmdlog_len = cmdlog;
11141 } 11140 }
11142 } 11141 }