* [PATCH] ath10k: core: match wait_for_completion_timeout return type
@ 2015-03-14 9:37 Nicholas Mc Guire
2015-04-01 17:18 ` Kalle Valo
2015-04-01 17:19 ` Kalle Valo
0 siblings, 2 replies; 3+ messages in thread
From: Nicholas Mc Guire @ 2015-03-14 9:37 UTC (permalink / raw)
To: Kalle Valo
Cc: ath10k, linux-wireless, netdev, linux-kernel, Nicholas Mc Guire
Return type of wait_for_completion_timeout is unsigned long not int.
An appropriately named unsigned long is added and the assignments fixed up.
Signed-off-by: Nicholas Mc Guire <hofrat@osadl.org>
---
Patch was only compile tested with x86_64_defconfig + CONFIG_ATH_CARDS=m,
CONFIG_ATH10K=m
Patch is against 4.0-rc3 (localversion-next is -next-20150313)
drivers/net/wireless/ath/ath10k/core.c | 5 +++--
1 file changed, 3 insertions(+), 2 deletions(-)
diff --git a/drivers/net/wireless/ath/ath10k/core.c b/drivers/net/wireless/ath/ath10k/core.c
index c0e454b..5fd833e 100644
--- a/drivers/net/wireless/ath/ath10k/core.c
+++ b/drivers/net/wireless/ath/ath10k/core.c
@@ -1151,6 +1151,7 @@ EXPORT_SYMBOL(ath10k_core_start);
int ath10k_wait_for_suspend(struct ath10k *ar, u32 suspend_opt)
{
int ret;
+ unsigned long time_left;
reinit_completion(&ar->target_suspend);
@@ -1160,9 +1161,9 @@ int ath10k_wait_for_suspend(struct ath10k *ar, u32 suspend_opt)
return ret;
}
- ret = wait_for_completion_timeout(&ar->target_suspend, 1 * HZ);
+ time_left = wait_for_completion_timeout(&ar->target_suspend, 1 * HZ);
- if (ret == 0) {
+ if (!time_left) {
ath10k_warn(ar, "suspend timed out - target pause event never came\n");
return -ETIMEDOUT;
}
--
1.7.10.4
^ permalink raw reply related [flat|nested] 3+ messages in thread
* Re: [PATCH] ath10k: core: match wait_for_completion_timeout return type
2015-03-14 9:37 [PATCH] ath10k: core: match wait_for_completion_timeout return type Nicholas Mc Guire
@ 2015-04-01 17:18 ` Kalle Valo
2015-04-01 17:19 ` Kalle Valo
1 sibling, 0 replies; 3+ messages in thread
From: Kalle Valo @ 2015-04-01 17:18 UTC (permalink / raw)
To: Nicholas Mc Guire; +Cc: netdev, linux-wireless, linux-kernel, ath10k
Nicholas Mc Guire <hofrat@osadl.org> writes:
> Return type of wait_for_completion_timeout is unsigned long not int.
> An appropriately named unsigned long is added and the assignments fixed up.
>
> Signed-off-by: Nicholas Mc Guire <hofrat@osadl.org>
Thanks, applied.
--
Kalle Valo
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: [PATCH] ath10k: core: match wait_for_completion_timeout return type
2015-03-14 9:37 [PATCH] ath10k: core: match wait_for_completion_timeout return type Nicholas Mc Guire
2015-04-01 17:18 ` Kalle Valo
@ 2015-04-01 17:19 ` Kalle Valo
1 sibling, 0 replies; 3+ messages in thread
From: Kalle Valo @ 2015-04-01 17:19 UTC (permalink / raw)
To: Nicholas Mc Guire; +Cc: netdev, linux-wireless, linux-kernel, ath10k
Nicholas Mc Guire <hofrat@osadl.org> writes:
> Return type of wait_for_completion_timeout is unsigned long not int.
> An appropriately named unsigned long is added and the assignments fixed up.
>
> Signed-off-by: Nicholas Mc Guire <hofrat@osadl.org>
Thanks, applied.
--
Kalle Valo
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2015-04-01 17:19 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2015-03-14 9:37 [PATCH] ath10k: core: match wait_for_completion_timeout return type Nicholas Mc Guire
2015-04-01 17:18 ` Kalle Valo
2015-04-01 17:19 ` Kalle Valo
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).