]> www.infradead.org Git - users/dwmw2/linux.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)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Sun, 21 Aug 2022 13:15:46 +0000 (15:15 +0200)
commit3ad958bc488e3ecb0207d31621c00efb86f17482
tree58d955a6dec25d490d22ce9e27cc0de44e3cd0e2
parentb1812f6500ddaf5e707af0ce6fdcd956481e8958
mt76: mt76x02u: fix possible memory leak in __mt76x02u_mcu_send_msg

[ Upstream commit cffd93411575afd987788e2ec3cb8eaff70f0215 ]

Free the skb if mt76u_bulk_msg fails in __mt76x02u_mcu_send_msg routine.

Fixes: 4c89ff2c74e39 ("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>
Signed-off-by: Sasha Levin <sashal@kernel.org>
drivers/net/wireless/mediatek/mt76/mt76x02_usb_mcu.c