Skip to content

Commit 728c1e2

Browse files
NavidemKalle Valo
authored and
Kalle Valo
committed
ath9k: release allocated buffer if timed out
In ath9k_wmi_cmd, the allocated network buffer needs to be released if timeout happens. Otherwise memory will be leaked. Signed-off-by: Navid Emamdoost <navid.emamdoost@gmail.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
1 parent 853acf7 commit 728c1e2

File tree

1 file changed

+1
-0
lines changed
  • drivers/net/wireless/ath/ath9k

1 file changed

+1
-0
lines changed

Diff for: drivers/net/wireless/ath/ath9k/wmi.c

+1
Original file line numberDiff line numberDiff line change
@@ -336,6 +336,7 @@ int ath9k_wmi_cmd(struct wmi *wmi, enum wmi_cmd_id cmd_id,
336336
ath_dbg(common, WMI, "Timeout waiting for WMI command: %s\n",
337337
wmi_cmd_to_name(cmd_id));
338338
mutex_unlock(&wmi->op_mutex);
339+
kfree_skb(skb);
339340
return -ETIMEDOUT;
340341
}
341342

0 commit comments

Comments
 (0)