]> git.baikalelectronics.ru Git - kernel.git/commit
mt76: mt76x02u: fix possible memory leak in __mt76x02u_mcu_send_msg
authorLorenzo Bianconi <lorenzo@kernel.org>
Tue, 17 May 2022 16:37:07 +0000 (18:37 +0200)
committerFelix Fietkau <nbd@nbd.name>
Mon, 11 Jul 2022 11:40:00 +0000 (13:40 +0200)
commit9e0e000dd32d566e42d5379ac4322bc3f8aecd33
tree687664407569db175d57334904041d2fe374dd47
parent2b5cc8e4439377a5f0a1f10d56540712bfc229b8
mt76: mt76x02u: fix possible memory leak in __mt76x02u_mcu_send_msg

Free the skb if mt76u_bulk_msg fails in __mt76x02u_mcu_send_msg routine.

Fixes: 2c1cdd43f780e ("mt76: split __mt76u_mcu_send_msg and mt76u_mcu_send_msg routines")
Co-developed-by: Gergo Koteles <soyer@irl.hu>
Signed-off-by: Gergo Koteles <soyer@irl.hu>
Signed-off-by: Lorenzo Bianconi <lorenzo@kernel.org>
Signed-off-by: Felix Fietkau <nbd@nbd.name>
drivers/net/wireless/mediatek/mt76/mt76x02_usb_mcu.c