summaryrefslogtreecommitdiff
path: root/drivers/net/wireless/ath/ath6kl
diff options
context:
space:
mode:
authorJia-Ju Bai <baijiaju1990@gmail.com>2018-07-27 11:43:18 +0300
committerKalle Valo <kvalo@codeaurora.org>2018-07-31 10:48:45 +0300
commitbfc55fe65987743e534808a18217ccd5783e00bb (patch)
treedb1030e2f54586d0d002f067bbf443fa5a42ae1a /drivers/net/wireless/ath/ath6kl
parent3f259111583801013cb605bb4414aa529adccf1c (diff)
downloadlinux-bfc55fe65987743e534808a18217ccd5783e00bb.tar.xz
ath6kl: replace GFP_ATOMIC with GFP_KERNEL in ath6kl_bmi_init()
ath6kl_bmi_init() is never called in atomic context. It calls kzalloc() with GFP_ATOMIC, which is not necessary. GFP_ATOMIC can be replaced with GFP_KERNEL. This is found by a static analysis tool named DCNS written by myself. Signed-off-by: Jia-Ju Bai <baijiaju1990@gmail.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
Diffstat (limited to 'drivers/net/wireless/ath/ath6kl')
-rw-r--r--drivers/net/wireless/ath/ath6kl/bmi.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/net/wireless/ath/ath6kl/bmi.c b/drivers/net/wireless/ath/ath6kl/bmi.c
index 334dbd834b3a..bde5a10d470c 100644
--- a/drivers/net/wireless/ath/ath6kl/bmi.c
+++ b/drivers/net/wireless/ath/ath6kl/bmi.c
@@ -534,7 +534,7 @@ int ath6kl_bmi_init(struct ath6kl *ar)
/* cmd + addr + len + data_size */
ar->bmi.max_cmd_size = ar->bmi.max_data_size + (sizeof(u32) * 3);
- ar->bmi.cmd_buf = kzalloc(ar->bmi.max_cmd_size, GFP_ATOMIC);
+ ar->bmi.cmd_buf = kzalloc(ar->bmi.max_cmd_size, GFP_KERNEL);
if (!ar->bmi.cmd_buf)
return -ENOMEM;