diff options
author | Toke Høiland-Jørgensen <toke@redhat.com> | 2021-03-26 19:08:19 +0100 |
---|---|---|
committer | Kalle Valo <kvalo@codeaurora.org> | 2021-04-22 16:37:54 +0300 |
commit | 7dd9a40fd6e0d0f1fd8e1931c007e080801dfdce (patch) | |
tree | 50f6a8344e19eb8b5aefa1a523caf737c2e5e828 /tools/perf/scripts/python/stackcollapse.py | |
parent | afda33499bea154dc792338c5c51a2038a206785 (diff) |
ath9k: Fix error check in ath9k_hw_read_revisions() for PCI devices
When the error check in ath9k_hw_read_revisions() was added, it checked for
-EIO which is what ath9k_regread() in the ath9k_htc driver uses. However,
for plain ath9k, the register read function uses ioread32(), which just
returns -1 on error. So if such a read fails, it still gets passed through
and ends up as a weird mac revision in the log output.
Fix this by changing ath9k_regread() to return -1 on error like ioread32()
does, and fix the error check to look for that instead of -EIO.
Fixes: 2f90c7e5d094 ("ath9k: Check for errors when reading SREV register")
Signed-off-by: Toke Høiland-Jørgensen <toke@redhat.com>
Reviewed-by: Lorenzo Bianconi <lorenzo@kernel.org>
Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
Link: https://lore.kernel.org/r/20210326180819.142480-1-toke@redhat.com
Diffstat (limited to 'tools/perf/scripts/python/stackcollapse.py')
0 files changed, 0 insertions, 0 deletions