]> git.baikalelectronics.ru Git - kernel.git/commit
rsi: Fix possible leak when loading firmware
authorChristian Engelmayer <cengelma@gmx.at>
Fri, 21 Aug 2015 21:14:26 +0000 (23:14 +0200)
committerKalle Valo <kvalo@codeaurora.org>
Tue, 25 Aug 2015 12:37:41 +0000 (15:37 +0300)
commita9beac786b4ea065d4346aa6338422cadaddf6d3
tree2fccddabbf5c2babf4565acc3141bf85182e9c8d
parent97e6420b6c82ae713ee50427cc1daf09f5d907b4
rsi: Fix possible leak when loading firmware

Commit 6c1855c1f57c ("rsi: Fix failure to load firmware after memory
leak fix and fix the leak") also added a check on the allocation of
DMA-accessible memory that may directly return. In that case the
already allocated firmware data is leaked. Make sure the data is
always freed correctly. Detected by Coverity CID 1316519.

Fixes: 6c1855c1f57c ("rsi: Fix failure to load firmware after memory leak fix and fix the leak")
Signed-off-by: Christian Engelmayer <cengelma@gmx.at>
Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
drivers/net/wireless/rsi/rsi_91x_sdio_ops.c
drivers/net/wireless/rsi/rsi_91x_usb_ops.c