diff options
| author | Marek Szyprowski <m.szyprowski@samsung.com> | 2026-02-03 11:21:33 +0100 |
|---|---|---|
| committer | Sasha Levin <sashal@kernel.org> | 2026-03-04 07:20:46 -0500 |
| commit | 64ccb0aac41c5055780c2a58bbe2c1b362ceccde (patch) | |
| tree | 87cce55775a5b03661533dbfce335d1fa58eb043 /lib/Kconfig.debug | |
| parent | 3c87b7e64735c0f6211e06b0febb468da7819ec6 (diff) | |
wifi: brcmfmac: Fix potential kernel oops when probe fails
[ Upstream commit 243307a0d1b0d01538e202c00454c28b21d4432e ]
When probe of the sdio brcmfmac device fails for some reasons (i.e.
missing firmware), the sdiodev->bus is set to error instead of NULL, thus
the cleanup later in brcmf_sdio_remove() tries to free resources via
invalid bus pointer. This happens because sdiodev->bus is set 2 times:
first in brcmf_sdio_probe() and second time in brcmf_sdiod_probe(). Fix
this by chaning the brcmf_sdio_probe() function to return the error code
and set sdio->bus only there.
Fixes: 0ff0843310b7 ("wifi: brcmfmac: Add optional lpo clock enable support")
Signed-off-by: Marek Szyprowski <m.szyprowski@samsung.com>
Acked-by: Arend van Spriel<arend.vanspriel@broadcom.com>
Link: https://patch.msgid.link/20260203102133.1478331-1-m.szyprowski@samsung.com
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Signed-off-by: Sasha Levin <sashal@kernel.org>
Diffstat (limited to 'lib/Kconfig.debug')
0 files changed, 0 insertions, 0 deletions
