diff options
author | Nicholas Mc Guire <der.herr@hofr.at> | 2015-01-08 13:27:34 +0100 |
---|---|---|
committer | Kalle Valo <kvalo@qca.qualcomm.com> | 2015-01-13 16:19:59 +0200 |
commit | 38e2a644174e74f948ec4415ae5b5c76f1412b0e (patch) | |
tree | 250fa81bc6fd1c503b2c5aafddc527fe163a11fd /drivers/net/wireless/ath/ath10k/htc.c | |
parent | 49274332a43a70b3a3f40ba6db14d9c0677e8e02 (diff) |
ath10k: fixup wait_for_completion_timeout return handling
wait_for_completion_timeout does not return negative values so the tests
for <= 0 are not needed and the case differentiation in the error handling
path unnecessary.
Signed-off-by: Nicholas Mc Guire <der.herr@hofr.at>
Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com>
Diffstat (limited to 'drivers/net/wireless/ath/ath10k/htc.c')
-rw-r--r-- | drivers/net/wireless/ath/ath10k/htc.c | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/drivers/net/wireless/ath/ath10k/htc.c b/drivers/net/wireless/ath/ath10k/htc.c index f1946a6be442..2fd9e180272b 100644 --- a/drivers/net/wireless/ath/ath10k/htc.c +++ b/drivers/net/wireless/ath/ath10k/htc.c @@ -703,11 +703,9 @@ int ath10k_htc_connect_service(struct ath10k_htc *htc, /* wait for response */ status = wait_for_completion_timeout(&htc->ctl_resp, ATH10K_HTC_CONN_SVC_TIMEOUT_HZ); - if (status <= 0) { - if (status == 0) - status = -ETIMEDOUT; + if (status == 0) { ath10k_err(ar, "Service connect timeout: %d\n", status); - return status; + return -ETIMEDOUT; } /* we controlled the buffer creation, it's aligned */ |