summaryrefslogtreecommitdiffstats
path: root/include/linux/debugobjects.h
diff options
context:
space:
mode:
authorBolarinwa Olayemi Saheed <refactormyself@gmail.com>2020-07-13 19:55:27 +0200
committerKalle Valo <kvalo@codeaurora.org>2020-07-15 19:47:32 +0300
commit9018fd7f2a73e9b290f48a56b421558fa31e8b75 (patch)
treedf4389713689b2368019a96d4d284dc3ac5fc8a3 /include/linux/debugobjects.h
parent0db5bc7b344736731a3982885402914b34dd252b (diff)
downloadcachepc-linux-9018fd7f2a73e9b290f48a56b421558fa31e8b75.tar.gz
cachepc-linux-9018fd7f2a73e9b290f48a56b421558fa31e8b75.zip
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
Diffstat (limited to 'include/linux/debugobjects.h')
0 files changed, 0 insertions, 0 deletions