diff mbox

ASoC: wm5100: match wait_for_completion_timeout return type

Message ID 1425812227-24172-1-git-send-email-hofrat@osadl.org (mailing list archive)
State Accepted
Commit 905a808664402dec0ac11376833e79da4ae7b2fd
Headers show

Commit Message

Nicholas Mc Guire March 8, 2015, 10:57 a.m. UTC
return type of wait_for_completion_timeout is unsigned long not int. An
appropriately named unsigned long is added and the assignment fixed up.

Signed-off-by: Nicholas Mc Guire <hofrat@osadl.org>
---

This was only compile tested for exynos_defconfig + CONFIG_COMPILE_TEST=y,
SND_SOC_ALL_CODECS=m (implies CONFIG_SND_SOC_WM5100=m)

Patch is against 4.0-rc2 linux-next (localversion-next is -next-20150306)

 sound/soc/codecs/wm5100.c |    7 ++++---
 1 file changed, 4 insertions(+), 3 deletions(-)

Comments

Mark Brown March 8, 2015, 6:49 p.m. UTC | #1
On Sun, Mar 08, 2015 at 06:57:07AM -0400, Nicholas Mc Guire wrote:
> return type of wait_for_completion_timeout is unsigned long not int. An
> appropriately named unsigned long is added and the assignment fixed up.

You are sending these to a very large CC list many of whom have no
obvious connection to the driver - please take care to ensure that the
people you are sending patches to are likely to want to review the code,
this helps keep people's mailboxes less noisy.
Nicholas Mc Guire March 9, 2015, 6:22 a.m. UTC | #2
On Sun, 08 Mar 2015, Mark Brown wrote:

> On Sun, Mar 08, 2015 at 06:57:07AM -0400, Nicholas Mc Guire wrote:
> > return type of wait_for_completion_timeout is unsigned long not int. An
> > appropriately named unsigned long is added and the assignment fixed up.
> 
> You are sending these to a very large CC list many of whom have no
> obvious connection to the driver - please take care to ensure that the
> people you are sending patches to are likely to want to review the code,
> this helps keep people's mailboxes less noisy.

sorry if I messed that up - my understanding was that
it should go out to all that scripts/get_mainteiner.pl shows
for the espective file. Should some of those listed
not be put on the CC list - or only maintainers+mailinglists ?

thx!
hofrat
Mark Brown March 9, 2015, 11:26 a.m. UTC | #3
On Mon, Mar 09, 2015 at 07:22:26AM +0100, Nicholas Mc Guire wrote:
> On Sun, 08 Mar 2015, Mark Brown wrote:

> > You are sending these to a very large CC list many of whom have no
> > obvious connection to the driver - please take care to ensure that the
> > people you are sending patches to are likely to want to review the code,
> > this helps keep people's mailboxes less noisy.

> sorry if I messed that up - my understanding was that
> it should go out to all that scripts/get_mainteiner.pl shows
> for the espective file. Should some of those listed
> not be put on the CC list - or only maintainers+mailinglists ?

No, if you're doing that based on the --git option it'll typically get a
lot of false positives for people doing coe cleanups for things.
Without git it's a bit more reliable but may miss people who work on the
code but aren't in MAINTAINERS.
Charles Keepax March 9, 2015, 2:29 p.m. UTC | #4
On Sun, Mar 08, 2015 at 06:57:07AM -0400, Nicholas Mc Guire wrote:
> return type of wait_for_completion_timeout is unsigned long not int. An
> appropriately named unsigned long is added and the assignment fixed up.
> 
> Signed-off-by: Nicholas Mc Guire <hofrat@osadl.org>
> ---

Acked-by: Charles Keepax <ckeepax@opensource.wolfsonmicro.com>

Thanks,
Charles
Mark Brown March 9, 2015, 6:16 p.m. UTC | #5
On Sun, Mar 08, 2015 at 06:57:07AM -0400, Nicholas Mc Guire wrote:
> return type of wait_for_completion_timeout is unsigned long not int. An
> appropriately named unsigned long is added and the assignment fixed up.

Applied, thanks.
diff mbox

Patch

diff --git a/sound/soc/codecs/wm5100.c b/sound/soc/codecs/wm5100.c
index ea09db5..9674037 100644
--- a/sound/soc/codecs/wm5100.c
+++ b/sound/soc/codecs/wm5100.c
@@ -1762,6 +1762,7 @@  static int wm5100_set_fll(struct snd_soc_codec *codec, int fll_id, int source,
 	struct _fll_div factors;
 	struct wm5100_fll *fll;
 	int ret, base, lock, i, timeout;
+	unsigned long time_left;
 
 	switch (fll_id) {
 	case WM5100_FLL1:
@@ -1842,9 +1843,9 @@  static int wm5100_set_fll(struct snd_soc_codec *codec, int fll_id, int source,
 	/* Poll for the lock; will use interrupt when we can test */
 	for (i = 0; i < timeout; i++) {
 		if (i2c->irq) {
-			ret = wait_for_completion_timeout(&fll->lock,
-							  msecs_to_jiffies(25));
-			if (ret > 0)
+			time_left = wait_for_completion_timeout(&fll->lock,
+							msecs_to_jiffies(25));
+			if (time_left > 0)
 				break;
 		} else {
 			msleep(1);