]> git.baikalelectronics.ru Git - kernel.git/commit
wifi: orinoco: check return value of hermes_write_wordrec()
authorAlexey Kodanev <aleksei.kodanev@bell-sw.com>
Tue, 27 Dec 2022 13:33:06 +0000 (16:33 +0300)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Sat, 11 Mar 2023 15:43:38 +0000 (16:43 +0100)
commit291ba9ed84b29ab8f1cf68ad913efda667a1af32
tree797a304b0c736e689c34155255ae271e3cdc4efd
parentdc4e25f8f60c2fb56e5f77dde46e4dabc3354d23
wifi: orinoco: check return value of hermes_write_wordrec()

[ Upstream commit 1e346cbb096a5351a637ec1992beffbf330547f0 ]

There is currently no return check for writing an authentication
type (HERMES_AUTH_SHARED_KEY or HERMES_AUTH_OPEN). It looks like
it was accidentally skipped.

This patch adds a return check similar to the other checks in
__orinoco_hw_setup_enc() for hermes_write_wordrec().

Detected using the static analysis tool - Svace.

Fixes: 1da177e4c3f4 ("Linux-2.6.12-rc2")
Signed-off-by: Alexey Kodanev <aleksei.kodanev@bell-sw.com>
Signed-off-by: Kalle Valo <kvalo@kernel.org>
Link: https://lore.kernel.org/r/20221227133306.201356-1-aleksei.kodanev@bell-sw.com
Signed-off-by: Sasha Levin <sashal@kernel.org>
drivers/net/wireless/intersil/orinoco/hw.c