linux/drivers/net/wireless/intel/iwlegacy
Bolarinwa Olayemi Saheed 9018fd7f2a iwlegacy: Check the return value of pcie_capability_read_*()
On failure pcie_capability_read_dword() sets it's last parameter, val
to 0. However, with Patch 14/14, it is possible that val is set to ~0 on
failure. This would introduce a bug because (x & x) == (~0 & x).

This bug can be avoided without changing the function's behaviour if the
return value of pcie_capability_read_dword is checked to confirm success.

Check the return value of pcie_capability_read_dword() to ensure success.

Suggested-by: Bjorn Helgaas <bjorn@helgaas.com>
Signed-off-by: Bolarinwa Olayemi Saheed <refactormyself@gmail.com>
Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
Link: https://lore.kernel.org/r/20200713175529.29715-3-refactormyself@gmail.com
2020-07-15 19:47:32 +03:00
..
3945-debug.c
3945-mac.c iwlegacy: Remove unneeded variable ret 2020-03-12 15:41:22 +02:00
3945-rs.c mac80211: populate debugfs only after cfg80211 init 2020-04-24 11:30:13 +02:00
3945.c
3945.h
4965-calib.c
4965-debug.c
4965-mac.c net: wireless: intel: fix wiki website url 2020-06-10 15:25:42 +03:00
4965-rs.c iwlegacy: remove redundant initialization of variable tid 2020-07-15 13:39:58 +03:00
4965.c iwlegacy: Remove unneeded variable ret 2020-03-12 15:41:22 +02:00
4965.h
commands.h iwlegacy: Replace zero-length array with flexible-array 2020-05-12 11:54:47 +03:00
common.c iwlegacy: Check the return value of pcie_capability_read_*() 2020-07-15 19:47:32 +03:00
common.h
csr.h
debug.c
iwl-spectrum.h iwlegacy: Replace zero-length array with flexible-array 2020-05-12 11:54:47 +03:00
Kconfig treewide: replace '---help---' in Kconfig files with 'help' 2020-06-14 01:57:21 +09:00
Makefile
prph.h