wifi: rtw89: free unused skb to prevent memory leak
This avoid potential memory leak under power saving mode. Signed-off-by: Po-Hao Huang <phhuang@realtek.com> Signed-off-by: Ping-Ke Shih <pkshih@realtek.com> Signed-off-by: Kalle Valo <kvalo@kernel.org> Link: https://lore.kernel.org/r/20220916033811.13862-6-pkshih@realtek.com
This commit is contained in:
parent
a63ae6736d
commit
eae672f386
|
@ -847,6 +847,7 @@ int rtw89_h2c_tx(struct rtw89_dev *rtwdev,
|
||||||
rtw89_debug(rtwdev, RTW89_DBG_FW,
|
rtw89_debug(rtwdev, RTW89_DBG_FW,
|
||||||
"ignore h2c due to power is off with firmware state=%d\n",
|
"ignore h2c due to power is off with firmware state=%d\n",
|
||||||
test_bit(RTW89_FLAG_FW_RDY, rtwdev->flags));
|
test_bit(RTW89_FLAG_FW_RDY, rtwdev->flags));
|
||||||
|
dev_kfree_skb(skb);
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue