2015-05-03 15:16:46

by Yoshinori Sato

[permalink] [raw]
Subject: spi-bcm2835 depends GPIOLIB

I got following error on CONFIG_GPIOLIB=n.

drivers/spi/spi-bcm2835.c: In function 'chip_match_name':
drivers/spi/spi-bcm2835.c:356:21: error: dereferencing pointer to incomplete type 'struct gpio_chip'
return !strcmp(chip->label, data);
^
drivers/spi/spi-bcm2835.c: In function 'bcm2835_spi_setup':
drivers/spi/spi-bcm2835.c:382:9: error: implicit declaration of function 'gpiochip_find' [-Werror=implicit-function-declaration]
chip = gpiochip_find("pinctrl-bcm2835", chip_match_name);
^
drivers/spi/spi-bcm2835.c:382:7: warning: assignment makes pointer from integer without a cast [-Wint-conversion]
chip = gpiochip_find("pinctrl-bcm2835", chip_match_name);
^
drivers/spi/spi-bcm2835.c: In function 'chip_match_name':
drivers/spi/spi-bcm2835.c:357:1: warning: control reaches end of non-void function [-Wreturn-type]
}
^

Signed-off-by: Yoshinori Sato <[email protected]>

diff --git a/drivers/spi/Kconfig b/drivers/spi/Kconfig
index 198f96b..d5ed2a0 100644
--- a/drivers/spi/Kconfig
+++ b/drivers/spi/Kconfig
@@ -77,6 +77,7 @@ config SPI_ATMEL

config SPI_BCM2835
tristate "BCM2835 SPI controller"
+ depends on GPIOLIB
depends on ARCH_BCM2835 || COMPILE_TEST
help
This selects a driver for the Broadcom BCM2835 SPI master.

--
Yoshinori Sato
<[email protected]>


2015-05-04 13:15:07

by Mark Brown

[permalink] [raw]
Subject: Re: spi-bcm2835 depends GPIOLIB

On Mon, May 04, 2015 at 12:16:36AM +0900, Yoshinori Sato wrote:
> I got following error on CONFIG_GPIOLIB=n.

Applied, thanks, but please use subject lines reflecting the style for
the subsystem.


Attachments:
(No filename) (196.00 B)
signature.asc (473.00 B)
Digital signature
Download all attachments

2015-05-07 04:55:52

by Yoshinori Sato

[permalink] [raw]
Subject: Re: spi-bcm2835 depends GPIOLIB

At Mon, 4 May 2015 13:00:46 +0100,
Mark Brown wrote:
>
> On Mon, May 04, 2015 at 12:16:36AM +0900, Yoshinori Sato wrote:
> > I got following error on CONFIG_GPIOLIB=n.
>
> Applied, thanks, but please use subject lines reflecting the style for
> the subsystem.

Oh. I'm sorry.
Thanks applied.

--
Yoshinori Sato
<[email protected]>