summaryrefslogtreecommitdiff
path: root/net/qrtr
diff options
context:
space:
mode:
authorTim Schumacher <timschumi@gmx.de>2019-03-18 22:05:57 +0300
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2019-07-26 10:13:58 +0300
commit42dcbf20e182329f88e681f3c2870898151ec80d (patch)
treed30e8ead6df6e2e7693dc3ba2f0cfad5ab282cfb /net/qrtr
parent7e19e658e535d19f3e038a52606e10d5442b936a (diff)
downloadlinux-42dcbf20e182329f88e681f3c2870898151ec80d.tar.xz
ath9k: Check for errors when reading SREV register
[ Upstream commit 2f90c7e5d09437a4d8d5546feaae9f1cf48cfbe1 ] Right now, if an error is encountered during the SREV register read (i.e. an EIO in ath9k_regread()), that error code gets passed all the way to __ath9k_hw_init(), where it is visible during the "Chip rev not supported" message. ath9k_htc 1-1.4:1.0: ath9k_htc: HTC initialized with 33 credits ath: phy2: Mac Chip Rev 0x0f.3 is not supported by this driver ath: phy2: Unable to initialize hardware; initialization status: -95 ath: phy2: Unable to initialize hardware; initialization status: -95 ath9k_htc: Failed to initialize the device Check for -EIO explicitly in ath9k_hw_read_revisions() and return a boolean based on the success of the operation. Check for that in __ath9k_hw_init() and abort with a more debugging-friendly message if reading the revisions wasn't successful. ath9k_htc 1-1.4:1.0: ath9k_htc: HTC initialized with 33 credits ath: phy2: Failed to read SREV register ath: phy2: Could not read hardware revision ath: phy2: Unable to initialize hardware; initialization status: -95 ath: phy2: Unable to initialize hardware; initialization status: -95 ath9k_htc: Failed to initialize the device This helps when debugging by directly showing the first point of failure and it could prevent possible errors if a 0x0f.3 revision is ever supported. Signed-off-by: Tim Schumacher <timschumi@gmx.de> Signed-off-by: Kalle Valo <kvalo@codeaurora.org> Signed-off-by: Sasha Levin <sashal@kernel.org>
Diffstat (limited to 'net/qrtr')
0 files changed, 0 insertions, 0 deletions