]> git.ipfire.org Git - thirdparty/kernel/stable.git/commit
wifi: airo: avoid uninitialized warning in airo_get_rate()
authorRandy Dunlap <rdunlap@infradead.org>
Sun, 9 Jul 2023 13:31:54 +0000 (06:31 -0700)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Fri, 11 Aug 2023 09:33:44 +0000 (11:33 +0200)
commit3d1d9e75df181a7ffa9fc122693469424cd50afd
tree5d51158b93daa0ea3d7faae67d6d0b4cbf803321
parentc6395e32935d35e6f935e7caf1c2dac5a95943b4
wifi: airo: avoid uninitialized warning in airo_get_rate()

[ Upstream commit 9373771aaed17f5c2c38485f785568abe3a9f8c1 ]

Quieten a gcc (11.3.0) build error or warning by checking the function
call status and returning -EBUSY if the function call failed.
This is similar to what several other wireless drivers do for the
SIOCGIWRATE ioctl call when there is a locking problem.

drivers/net/wireless/cisco/airo.c: error: 'status_rid.currentXmitRate' is used uninitialized [-Werror=uninitialized]

Fixes: 1da177e4c3f4 ("Linux-2.6.12-rc2")
Signed-off-by: Randy Dunlap <rdunlap@infradead.org>
Reported-by: Geert Uytterhoeven <geert@linux-m68k.org>
Link: https://lore.kernel.org/r/39abf2c7-24a-f167-91da-ed4c5435d1c4@linux-m68k.org
Link: https://lore.kernel.org/r/20230709133154.26206-1-rdunlap@infradead.org
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
Signed-off-by: Sasha Levin <sashal@kernel.org>
drivers/net/wireless/cisco/airo.c