Skip to contentSkip to conversation

gpio: moxart: Drop redundant code to set already initialized gpio_chip fields

PATCH In review Axel Lin 2 participants 4 messages Feb 26, 2016 – Mar 7, 2016 GPIO

lore
Share & tools
lore

Axel Lin

author
#0 lore raw

PATCH 1/2 gpio: moxart: Drop redundant code to set already initialized gpio_chip fields

These fields are initialized by bgpio_init() with exactly the same settings so remove the redundant code.

---
 drivers/gpio/gpio-moxart.c | 3 ---
 1 file changed, 3 deletions(-)
drivers/gpio/gpio-moxart.c +0 -3
index ca60453..f7cf593 100644
@@ -57,10 +57,7 @@ static int moxart_gpio_probe(struct platform_device *pdev)
 	gc->label = "moxart-gpio";
 	gc->request = gpiochip_generic_request;
 	gc->free = gpiochip_generic_free;
-	gc->bgpio_data = gc->read_reg(gc->reg_set);
 	gc->base = 0;
-	gc->ngpio = 32;
-	gc->parent = dev;
 	gc->owner = THIS_MODULE;
 
 	ret = gpiochip_add_data(gc, NULL);
Signature · 1 line
2.1.4
author
#1 lore raw

PATCH 2/2 gpio: moxart: Allow compile test build

There is no build dependency for this driver, so enable COMPILE_TEST to get better build coverage.

---
 drivers/gpio/Kconfig | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/gpio/Kconfig +1 -1
index 1118fef..f8d6035ea 100644
@@ -280,7 +280,7 @@ config GPIO_MM_LANTIQ
 
 config GPIO_MOXART
 	bool "MOXART GPIO support"
-	depends on ARCH_MOXART
+	depends on ARCH_MOXART || COMPILE_TEST
 	select GPIO_GENERIC
 	help
 	  Select this option to enable GPIO driver for
Signature · 1 line
2.1.4
#2 lore raw

Re: [PATCH 2/2] gpio: moxart: Allow compile test build

Quoted 4 lines · Axel Lin

There is no build dependency for this driver, so enable COMPILE_TEST to get better build coverage.

Patch applied.

Yours,
Linus Walleij