]> git.baikalelectronics.ru Git - kernel.git/commit
rtlwifi: Remove redundant assignments to ul_enc_algo
authorYang Li <yang.lee@linux.alibaba.com>
Tue, 18 May 2021 01:59:59 +0000 (09:59 +0800)
committerKalle Valo <kvalo@codeaurora.org>
Tue, 15 Jun 2021 13:39:55 +0000 (16:39 +0300)
commit74b83eba9479e65ed83908d2f78ba8a643832545
tree46488fcedc3a013712e95122bd869b7e4248b664
parentb6cbefc03e8b28c2409cdf6fdc3ea3cef924d27b
rtlwifi: Remove redundant assignments to ul_enc_algo

Variable ul_enc_algo is being initialized with a value that is never
read, it is being set again in the following switch statements in
all of the case and default paths. Hence the unitialization is
redundant and can be removed.

Clean up clang warning:

drivers/net/wireless/realtek/rtlwifi/cam.c:170:6: warning: Value stored
to 'ul_enc_algo' during its initialization is never read
[clang-analyzer-deadcode.DeadStores]

Reported-by: Abaci Robot <abaci@linux.alibaba.com>
Signed-off-by: Yang Li <yang.lee@linux.alibaba.com>
Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
Link: https://lore.kernel.org/r/1621303199-1542-1-git-send-email-yang.lee@linux.alibaba.com
drivers/net/wireless/realtek/rtlwifi/cam.c