diff mbox

spi: pxa2xx: Fix build error because of missing header

Message ID 20160929064520.184224-1-mika.westerberg@linux.intel.com (mailing list archive)
State Accepted
Commit 089bd46d8bc1fe5a28351e82e4adcaa5a40121b5
Headers show

Commit Message

Mika Westerberg Sept. 29, 2016, 6:45 a.m. UTC
Kbuild test robot reports:

  drivers/spi/spi-pxa2xx.c: In function ‘setup_cs’:
  drivers/spi/spi-pxa2xx.c:1190:20: error: implicit declaration of function ‘desc_to_gpio’
  ...

Reason for this is the fact that those functions are declared in
linux/gpio/consumer.h which is not included in the driver. Fix this by
including it.

Reported-by: kbuild test robot <fengguang.wu@intel.com>
Signed-off-by: Mika Westerberg <mika.westerberg@linux.intel.com>
---
 drivers/spi/spi-pxa2xx.c | 1 +
 1 file changed, 1 insertion(+)
diff mbox

Patch

diff --git a/drivers/spi/spi-pxa2xx.c b/drivers/spi/spi-pxa2xx.c
index 9e54345467dc..49cd7ac2e9eb 100644
--- a/drivers/spi/spi-pxa2xx.c
+++ b/drivers/spi/spi-pxa2xx.c
@@ -28,6 +28,7 @@ 
 #include <linux/spi/spi.h>
 #include <linux/delay.h>
 #include <linux/gpio.h>
+#include <linux/gpio/consumer.h>
 #include <linux/slab.h>
 #include <linux/clk.h>
 #include <linux/pm_runtime.h>