All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] ASoC: delay the initial jack detect by debounce_time
@ 2014-02-23  6:44 xiangxiao
  2014-02-24  1:28 ` Mark Brown
  0 siblings, 1 reply; 2+ messages in thread
From: xiangxiao @ 2014-02-23  6:44 UTC (permalink / raw)
  To: broonie, lgirdwood; +Cc: alsa-devel, xiaoxiang

so the hardware could get time to initialize and debounce

Change-Id: Iebeffa9bac6c4012ee8f9645771c13b28fe5ae80
Signed-off-by: xiangxiao <xiaoxiang@xiaomi.com>
---
 sound/soc/soc-jack.c | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/sound/soc/soc-jack.c b/sound/soc/soc-jack.c
index 23d43da..b12fce6 100644
--- a/sound/soc/soc-jack.c
+++ b/sound/soc/soc-jack.c
@@ -342,7 +342,8 @@ int snd_soc_jack_add_gpios(struct snd_soc_jack *jack, int count,
 		gpio_export(gpios[i].gpio, false);
 
 		/* Update initial jack status */
-		snd_soc_jack_gpio_detect(&gpios[i]);
+		schedule_delayed_work(&gpios[i].work,
+				      msecs_to_jiffies(gpios[i].debounce_time));
 	}
 
 	return 0;
-- 
1.8.1.2

^ permalink raw reply related	[flat|nested] 2+ messages in thread

* Re: [PATCH] ASoC: delay the initial jack detect by debounce_time
  2014-02-23  6:44 [PATCH] ASoC: delay the initial jack detect by debounce_time xiangxiao
@ 2014-02-24  1:28 ` Mark Brown
  0 siblings, 0 replies; 2+ messages in thread
From: Mark Brown @ 2014-02-24  1:28 UTC (permalink / raw)
  To: xiangxiao; +Cc: alsa-devel, lgirdwood


[-- Attachment #1.1: Type: text/plain, Size: 137 bytes --]

On Sun, Feb 23, 2014 at 02:44:52PM +0800, xiangxiao wrote:
> so the hardware could get time to initialize and debounce

Applied, thanks.

[-- Attachment #1.2: Digital signature --]
[-- Type: application/pgp-signature, Size: 836 bytes --]

[-- Attachment #2: Type: text/plain, Size: 0 bytes --]



^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2014-02-24  5:34 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2014-02-23  6:44 [PATCH] ASoC: delay the initial jack detect by debounce_time xiangxiao
2014-02-24  1:28 ` Mark Brown

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.