diff mbox

gpio: add COMPILE_TEST to several drivers

Message ID 1499140313-31592-1-git-send-email-yamada.masahiro@socionext.com
State New
Headers show

Commit Message

Masahiro Yamada July 4, 2017, 3:51 a.m. UTC
These drivers are actually platform-agnostic.  Add COMPILE_TEST for
the compilation test coverage.

Signed-off-by: Masahiro Yamada <yamada.masahiro@socionext.com>
---

 drivers/gpio/Kconfig | 22 +++++++++++-----------
 1 file changed, 11 insertions(+), 11 deletions(-)

Comments

kernel test robot July 6, 2017, 5:06 a.m. UTC | #1
Hi Masahiro,

[auto build test ERROR on gpio/for-next]
[cannot apply to v4.12]
[if your patch is applied to the wrong git tree, please drop us a note to help improve the system]

url:    https://github.com/0day-ci/linux/commits/Masahiro-Yamada/gpio-add-COMPILE_TEST-to-several-drivers/20170706-070538
base:   https://git.kernel.org/pub/scm/linux/kernel/git/linusw/linux-gpio.git for-next
config: xtensa-allyesconfig (attached as .config)
compiler: xtensa-linux-gcc (GCC) 4.9.0
reproduce:
        wget https://raw.githubusercontent.com/01org/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross
        chmod +x ~/bin/make.cross
        # save the attached .config to linux build tree
        make.cross ARCH=xtensa 

All errors (new ones prefixed by >>):

   drivers//gpio/gpio-vf610.c: In function 'vf610_gpio_direction_input':
>> drivers//gpio/gpio-vf610.c:99:2: error: implicit declaration of function 'pinctrl_gpio_direction_input' [-Werror=implicit-function-declaration]
     return pinctrl_gpio_direction_input(chip->base + gpio);
     ^
   drivers//gpio/gpio-vf610.c: In function 'vf610_gpio_direction_output':
>> drivers//gpio/gpio-vf610.c:107:2: error: implicit declaration of function 'pinctrl_gpio_direction_output' [-Werror=implicit-function-declaration]
     return pinctrl_gpio_direction_output(chip->base + gpio);
     ^
   cc1: some warnings being treated as errors

vim +/pinctrl_gpio_direction_input +99 drivers//gpio/gpio-vf610.c

7f2691a1 Stefan Agner    2014-10-16   93  	else
7f2691a1 Stefan Agner    2014-10-16   94  		vf610_gpio_writel(mask, port->gpio_base + GPIO_PCOR);
7f2691a1 Stefan Agner    2014-10-16   95  }
7f2691a1 Stefan Agner    2014-10-16   96  
7f2691a1 Stefan Agner    2014-10-16   97  static int vf610_gpio_direction_input(struct gpio_chip *chip, unsigned gpio)
7f2691a1 Stefan Agner    2014-10-16   98  {
7f2691a1 Stefan Agner    2014-10-16  @99  	return pinctrl_gpio_direction_input(chip->base + gpio);
7f2691a1 Stefan Agner    2014-10-16  100  }
7f2691a1 Stefan Agner    2014-10-16  101  
7f2691a1 Stefan Agner    2014-10-16  102  static int vf610_gpio_direction_output(struct gpio_chip *chip, unsigned gpio,
7f2691a1 Stefan Agner    2014-10-16  103  				       int value)
7f2691a1 Stefan Agner    2014-10-16  104  {
7f2691a1 Stefan Agner    2014-10-16  105  	vf610_gpio_set(chip, gpio, value);
7f2691a1 Stefan Agner    2014-10-16  106  
7f2691a1 Stefan Agner    2014-10-16 @107  	return pinctrl_gpio_direction_output(chip->base + gpio);
7f2691a1 Stefan Agner    2014-10-16  108  }
7f2691a1 Stefan Agner    2014-10-16  109  
bd0b9ac4 Thomas Gleixner 2015-09-14  110  static void vf610_gpio_irq_handler(struct irq_desc *desc)

:::::: The code at line 99 was first introduced by commit
:::::: 7f2691a19627a8d7723909b6e82468fd4437e445 gpio: vf610: add gpiolib/IRQ chip driver for Vybrid

:::::: TO: Stefan Agner <stefan@agner.ch>
:::::: CC: Linus Walleij <linus.walleij@linaro.org>

---
0-DAY kernel test infrastructure                Open Source Technology Center
https://lists.01.org/pipermail/kbuild-all                   Intel Corporation
Linus Walleij July 6, 2017, 9:52 p.m. UTC | #2
On Tue, Jul 4, 2017 at 5:51 AM, Masahiro Yamada
<yamada.masahiro@socionext.com> wrote:

> These drivers are actually platform-agnostic.  Add COMPILE_TEST for
> the compilation test coverage.
>
> Signed-off-by: Masahiro Yamada <yamada.masahiro@socionext.com>

I had such patches in the past.

It breaks everything to the left and right.

What I need is someone who turns this on PER DRIVER (in their tree)
fixes all the fallout (I don't know how, maybe using 0day builds?), then
sends a patch fixing the fallout and as the last patch turns on
COMPILE_TEST when it doesn't break anything.

And we want to use it for new drivers, ideally.

The arch that always breaks everything us UM Linux.

Yours,
Linus Walleij
--
To unsubscribe from this list: send the line "unsubscribe linux-gpio" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
diff mbox

Patch

diff --git a/drivers/gpio/Kconfig b/drivers/gpio/Kconfig
index f235eae04c16..da82cee24980 100644
--- a/drivers/gpio/Kconfig
+++ b/drivers/gpio/Kconfig
@@ -153,7 +153,7 @@  config GPIO_CLPS711X
 config GPIO_DAVINCI
 	bool "TI Davinci/Keystone GPIO support"
 	default y if ARCH_DAVINCI
-	depends on ARM && (ARCH_DAVINCI || ARCH_KEYSTONE)
+	depends on ARM && (ARCH_DAVINCI || ARCH_KEYSTONE || COMPILE_TEST)
 	help
 	  Say yes here to enable GPIO support for TI Davinci/Keystone SoCs.
 
@@ -279,7 +279,7 @@  config GPIO_LPC18XX
 
 config GPIO_LYNXPOINT
 	tristate "Intel Lynxpoint GPIO support"
-	depends on ACPI && X86
+	depends on ACPI && (X86 || COMPILE_TEST)
 	select GPIOLIB_IRQCHIP
 	help
 	  driver for GPIO functionality on Intel Lynxpoint PCH chipset
@@ -337,20 +337,20 @@  config GPIO_MPC8XXX
 
 config GPIO_MVEBU
 	def_bool y
-	depends on PLAT_ORION || ARCH_MVEBU
+	depends on PLAT_ORION || ARCH_MVEBU || COMPILE_TEST
 	depends on OF_GPIO
 	select GENERIC_IRQ_CHIP
 	select REGMAP_MMIO
 
 config GPIO_MXC
 	def_bool y
-	depends on ARCH_MXC
+	depends on ARCH_MXC || COMPILE_TEST
 	select GPIO_GENERIC
 	select GENERIC_IRQ_CHIP
 
 config GPIO_MXS
 	def_bool y
-	depends on ARCH_MXS
+	depends on ARCH_MXS || COMPILE_TEST
 	select GPIO_GENERIC
 	select GENERIC_IRQ_CHIP
 
@@ -381,7 +381,7 @@  config GPIO_PL061
 
 config GPIO_PXA
 	bool "PXA GPIO support"
-	depends on ARCH_PXA || ARCH_MMP
+	depends on ARCH_PXA || ARCH_MMP || COMPILE_TEST
 	help
 	  Say yes here to support the PXA GPIO device
 
@@ -467,7 +467,7 @@  config GPIO_TZ1090_PDC
 
 config GPIO_VF610
 	def_bool y
-	depends on ARCH_MXC && SOC_VF610
+	depends on (ARCH_MXC && SOC_VF610) || COMPILE_TEST
 	select GPIOLIB_IRQCHIP
 	help
 	  Say yes here to support Vybrid vf610 GPIOs.
@@ -492,7 +492,7 @@  config GPIO_VX855
 
 config GPIO_XGENE
 	bool "APM X-Gene GPIO controller support"
-	depends on ARM64 && OF_GPIO
+	depends on (ARM64 || COMPILE_TEST) && OF_GPIO
 	help
 	  This driver is to support the GPIO block within the APM X-Gene SoC
 	  platform's generic flash controller. The GPIO pins are muxed with
@@ -543,7 +543,7 @@  config GPIO_ZEVIO
 
 config GPIO_ZYNQ
 	tristate "Xilinx Zynq GPIO support"
-	depends on ARCH_ZYNQ || ARCH_ZYNQMP
+	depends on ARCH_ZYNQ || ARCH_ZYNQMP || COMPILE_TEST
 	select GPIOLIB_IRQCHIP
 	help
 	  Say yes here to support Xilinx Zynq GPIO controller.
@@ -1154,14 +1154,14 @@  config GPIO_BT8XX
 
 config GPIO_INTEL_MID
 	bool "Intel MID GPIO support"
-	depends on X86_INTEL_MID
+	depends on X86_INTEL_MID || COMPILE_TEST
 	select GPIOLIB_IRQCHIP
 	help
 	  Say Y here to support Intel MID GPIO.
 
 config GPIO_MERRIFIELD
 	tristate "Intel Merrifield GPIO support"
-	depends on X86_INTEL_MID
+	depends on X86_INTEL_MID || COMPILE_TEST
 	select GPIOLIB_IRQCHIP
 	help
 	  Say Y here to support Intel Merrifield GPIO.