diff options
author | Vivek Natarajan <nataraja@qca.qualcomm.com> | 2012-03-28 19:21:25 +0530 |
---|---|---|
committer | Kalle Valo <kvalo@qca.qualcomm.com> | 2012-04-03 21:26:01 +0300 |
commit | 8437754c83351d6213c1a47ff029c1126d6042a7 (patch) | |
tree | 5b9f184f7f5ac450feaf68d15a0f4cb9e07a2a03 /drivers/net/wireless/ath/ath6kl/init.c | |
parent | f599359cb97425b034b41e8d4a1a86eaa151972c (diff) | |
download | linux-8437754c83351d6213c1a47ff029c1126d6042a7.tar.bz2 |
ath6kl: Use vmalloc instead of kmalloc for fw
Sometimes it has been observed that allocating a contiguous memory
of more than 100K fails with kmalloc. This has been modified to
use vmalloc instead.
Signed-off-by: PingYang Zhang <pingzhan@qca.qualcomm.com>
Signed-off-by: Vivek Natarajan <nataraja@qca.qualcomm.com>
Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com>
Diffstat (limited to 'drivers/net/wireless/ath/ath6kl/init.c')
-rw-r--r-- | drivers/net/wireless/ath/ath6kl/init.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/drivers/net/wireless/ath/ath6kl/init.c b/drivers/net/wireless/ath/ath6kl/init.c index 092e4cddfed3..5949ab5357fd 100644 --- a/drivers/net/wireless/ath/ath6kl/init.c +++ b/drivers/net/wireless/ath/ath6kl/init.c @@ -21,6 +21,7 @@ #include <linux/export.h> #include <linux/of.h> #include <linux/mmc/sdio_func.h> +#include <linux/vmalloc.h> #include "core.h" #include "cfg80211.h" @@ -928,13 +929,14 @@ static int ath6kl_fetch_fw_apin(struct ath6kl *ar, const char *name) if (ar->fw != NULL) break; - ar->fw = kmemdup(data, ie_len, GFP_KERNEL); + ar->fw = vmalloc(ie_len); if (ar->fw == NULL) { ret = -ENOMEM; goto out; } + memcpy(ar->fw, data, ie_len); ar->fw_len = ie_len; break; case ATH6KL_FW_IE_PATCH_IMAGE: |