Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.kernel > #1414112 > unrolled thread

[PATCH 1/1 linux-next] ASoC: cs53l30: include gpio/consumer.h

Started byFabian Frederick <fabf@skynet.be>
First post2016-06-05 15:20 +0200
Last post2016-06-06 07:10 +0200
Articles 2 — 2 participants

Back to article view | Back to linux.kernel


Contents

  [PATCH 1/1 linux-next] ASoC: cs53l30: include gpio/consumer.h Fabian Frederick <fabf@skynet.be> - 2016-06-05 15:20 +0200
    Re: [PATCH 1/1 linux-next] ASoC: cs53l30: include gpio/consumer.h Nicolin Chen <nicoleotsuka@gmail.com> - 2016-06-06 07:10 +0200

#1414112 — [PATCH 1/1 linux-next] ASoC: cs53l30: include gpio/consumer.h

FromFabian Frederick <fabf@skynet.be>
Date2016-06-05 15:20 +0200
Subject[PATCH 1/1 linux-next] ASoC: cs53l30: include gpio/consumer.h
Message-ID<rGG8a-7k9-1@gated-at.bofh.it>
cs53l30 breaks kernel compilation when CONFIG_GPIOLIB is disabled.

sound/soc/codecs/cs53l30.c:931:2: error: implicit declaration of
function devm_gpiod_get_optional [-Werror=implicit-function-declaration]
  cs53l30->reset_gpio = devm_gpiod_get_optional(dev, "reset",
  ^
sound/soc/codecs/cs53l30.c:932:13: error: GPIOD_OUT_LOW undeclared
(first use in this function)

Including gpio/consumer.h declares minimal functions in that case.

Signed-off-by: Fabian Frederick <fabf@skynet.be>
---
 sound/soc/codecs/cs53l30.c | 1 +
 1 file changed, 1 insertion(+)

diff --git a/sound/soc/codecs/cs53l30.c b/sound/soc/codecs/cs53l30.c
index ac90dd7..4818324 100644
--- a/sound/soc/codecs/cs53l30.c
+++ b/sound/soc/codecs/cs53l30.c
@@ -15,6 +15,7 @@
 #include <linux/clk.h>
 #include <linux/delay.h>
 #include <linux/i2c.h>
+#include <linux/gpio/consumer.h>
 #include <linux/module.h>
 #include <linux/of_gpio.h>
 #include <linux/regulator/consumer.h>
-- 
2.1.4

[toc] | [next] | [standalone]


#1414644

FromNicolin Chen <nicoleotsuka@gmail.com>
Date2016-06-06 07:10 +0200
Message-ID<rGUXw-u6-11@gated-at.bofh.it>
In reply to#1414112
On Sun, Jun 05, 2016 at 03:11:00PM +0200, Fabian Frederick wrote:
> cs53l30 breaks kernel compilation when CONFIG_GPIOLIB is disabled.
> 
> sound/soc/codecs/cs53l30.c:931:2: error: implicit declaration of
> function devm_gpiod_get_optional [-Werror=implicit-function-declaration]
>   cs53l30->reset_gpio = devm_gpiod_get_optional(dev, "reset",
>   ^
> sound/soc/codecs/cs53l30.c:932:13: error: GPIOD_OUT_LOW undeclared
> (first use in this function)
> 
> Including gpio/consumer.h declares minimal functions in that case.
> 
> Signed-off-by: Fabian Frederick <fabf@skynet.be>
> ---
>  sound/soc/codecs/cs53l30.c | 1 +
>  1 file changed, 1 insertion(+)
> 
> diff --git a/sound/soc/codecs/cs53l30.c b/sound/soc/codecs/cs53l30.c
> index ac90dd7..4818324 100644
> --- a/sound/soc/codecs/cs53l30.c
> +++ b/sound/soc/codecs/cs53l30.c
> @@ -15,6 +15,7 @@
>  #include <linux/clk.h>
>  #include <linux/delay.h>
>  #include <linux/i2c.h>
> +#include <linux/gpio/consumer.h>

Could you put it before i2c.h to order them alphabetically?

Thank you

>  #include <linux/module.h>
>  #include <linux/of_gpio.h>
>  #include <linux/regulator/consumer.h>
> -- 
> 2.1.4
> 

[toc] | [prev] | [standalone]


Back to top | Article view | linux.kernel


csiph-web