From: Mark Brown Date: Thu, 15 Aug 2013 10:53:28 +0000 (+0100) Subject: ASoC: pcm3008: Use gpio_set_value_cansleep() X-Git-Tag: accepted/tizen/common/20141203.182822~1038^2~176^2~28^2~2 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=ea67afc3fdbe9196d76ee79503a3809a54300b5a;p=platform%2Fkernel%2Flinux-arm64.git ASoC: pcm3008: Use gpio_set_value_cansleep() We don't set the GPIO values from atomic context so support GPIOs that can't be controlled from atomic context. Signed-off-by: Mark Brown --- diff --git a/sound/soc/codecs/pcm3008.c b/sound/soc/codecs/pcm3008.c index b883f99..8b9b378 100644 --- a/sound/soc/codecs/pcm3008.c +++ b/sound/soc/codecs/pcm3008.c @@ -54,8 +54,8 @@ static int pcm3008_soc_suspend(struct snd_soc_codec *codec) { struct pcm3008_setup_data *setup = codec->dev->platform_data; - gpio_set_value(setup->pdad_pin, 0); - gpio_set_value(setup->pdda_pin, 0); + gpio_set_value_cansleep(setup->pdad_pin, 0); + gpio_set_value_cansleep(setup->pdda_pin, 0); return 0; } @@ -64,8 +64,8 @@ static int pcm3008_soc_resume(struct snd_soc_codec *codec) { struct pcm3008_setup_data *setup = codec->dev->platform_data; - gpio_set_value(setup->pdad_pin, 1); - gpio_set_value(setup->pdda_pin, 1); + gpio_set_value_cansleep(setup->pdad_pin, 1); + gpio_set_value_cansleep(setup->pdda_pin, 1); return 0; }