[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <20200616153107.606632227@linuxfoundation.org>
Date: Tue, 16 Jun 2020 17:33:09 +0200
From: Greg Kroah-Hartman <gregkh@...uxfoundation.org>
To: linux-kernel@...r.kernel.org
Cc: Greg Kroah-Hartman <gregkh@...uxfoundation.org>,
stable@...r.kernel.org,
Jérôme Pouiller
<jerome.pouiller@...abs.com>,
Michał Mirosław <mirq-linux@...e.qmqm.pl>,
Sasha Levin <sashal@...nel.org>
Subject: [PATCH 5.7 015/163] staging: wfx: fix double free
From: Jérôme Pouiller <jerome.pouiller@...abs.com>
[ Upstream commit 832cc98141b4b93acbb9231ca9e36f7fbe347f47 ]
In case of error in wfx_probe(), wdev->hw is freed. Since an error
occurred, wfx_free_common() is called, then wdev->hw is freed again.
Signed-off-by: Jérôme Pouiller <jerome.pouiller@...abs.com>
Reviewed-by: Michał Mirosław <mirq-linux@...e.qmqm.pl>
Fixes: 4033714d6cbe ("staging: wfx: fix init/remove vs IRQ race")
Link: https://lore.kernel.org/r/20200505123757.39506-4-Jerome.Pouiller@silabs.com
Signed-off-by: Greg Kroah-Hartman <gregkh@...uxfoundation.org>
Signed-off-by: Sasha Levin <sashal@...nel.org>
---
drivers/staging/wfx/main.c | 1 -
1 file changed, 1 deletion(-)
diff --git a/drivers/staging/wfx/main.c b/drivers/staging/wfx/main.c
index 3c4c240229ad..8f19bd0fd2a1 100644
--- a/drivers/staging/wfx/main.c
+++ b/drivers/staging/wfx/main.c
@@ -466,7 +466,6 @@ int wfx_probe(struct wfx_dev *wdev)
err2:
ieee80211_unregister_hw(wdev->hw);
- ieee80211_free_hw(wdev->hw);
err1:
wfx_bh_unregister(wdev);
return err;
--
2.25.1
Powered by blists - more mailing lists