Re: [PATCH][RFT] au1000: convert to gpiolib

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hello Florian,

On Sat, Aug 23, 2008 at 11:49:27PM +0200, Florian Fainelli wrote:
> This patch converts Au1000 to use gpiolib. Testers
> welcome !
> 
> Manuel, Kevin, could you test this on your boards ? Thanks

No problems on my end.

 
> diff --git a/arch/mips/au1000/common/gpio.c b/arch/mips/au1000/common/gpio.c
> index b485d94..67b3a6b 100644
> --- a/arch/mips/au1000/common/gpio.c
> +++ b/arch/mips/au1000/common/gpio.c
> @@ -1,5 +1,5 @@
  
> -int au1xxx_gpio_direction_output(unsigned gpio, int value)
> +int __init au1000_gpio_init(void)

make that one static please.


>  {
> -	if (gpio >= AU1XXX_GPIO_BASE)
> -#if defined(CONFIG_SOC_AU1000)
> -		return -ENODEV;
> -#else
> -		return au1xxx_gpio2_direction_output(gpio, value);
> -#endif
> -
> -	return au1xxx_gpio1_direction_output(gpio, value);
> +	gpiochip_add(&au1000_gpio_chip[0].chip);
> +#if !defined(CONFIG_SOC_AU1000)
> +	gpiochip_add(&au1000_gpio_chip[1].chip);
> +#endif	
> +	return 0;
>  }
> -EXPORT_SYMBOL(au1xxx_gpio_direction_output);
> +arch_initcall(au1000_gpio_init);


Thanks,
	Manuel Lauss


[Index of Archives]     [Linux MIPS Home]     [LKML Archive]     [Linux ARM Kernel]     [Linux ARM]     [Linux]     [Git]     [Yosemite News]     [Linux SCSI]     [Linux Hams]

  Powered by Linux