Re: [U-Boot] [PATCH V4, 1/6] dm: gpio: add a default gpio xlate routine

2016-04-27 Thread Simon Glass
On 24 April 2016 at 17:32, Eric Nelson  wrote:
> Many drivers use a common form of offset + flags for device
> tree nodes. e.g.:
> <&gpio1 2 GPIO_ACTIVE_LOW>
>
> This patch adds a common implementation of this type of parsing
> and calls it when a gpio driver doesn't supply its' own xlate
> routine.
>
> This will allow removal of the driver-specific versions in a
> handful of drivers and simplify the addition of new drivers.
>
> Signed-off-by: Eric Nelson 
> Reviewed-by: Stephen Warren 
> ---
>   V2 removes parsing of offset from the gpio_find_and_xlate routine,
>   and only parses the offset and GPIO_ACTIVE_LOW flag when a
>   driver-specific xlate is unavailable.
>
>   V3 re-works tests of the argument count as suggested by Stephen Warren
>   and will allow parsing of nodes with no flags field:
> <&gpio1 2>
>
>   V4 fixes an indent with spaces instead of tabs
>
>  drivers/gpio/gpio-uclass.c | 30 +++---
>  include/asm-generic/gpio.h | 19 ++-
>  2 files changed, 37 insertions(+), 12 deletions(-)

Acked-by: Simon Glass 
___
U-Boot mailing list
U-Boot@lists.denx.de
http://lists.denx.de/mailman/listinfo/u-boot


Re: [U-Boot] [PATCH V4, 1/6] dm: gpio: add a default gpio xlate routine

2016-05-07 Thread Simon Glass
On 27 April 2016 at 09:12, Simon Glass  wrote:
> On 24 April 2016 at 17:32, Eric Nelson  wrote:
>> Many drivers use a common form of offset + flags for device
>> tree nodes. e.g.:
>> <&gpio1 2 GPIO_ACTIVE_LOW>
>>
>> This patch adds a common implementation of this type of parsing
>> and calls it when a gpio driver doesn't supply its' own xlate
>> routine.
>>
>> This will allow removal of the driver-specific versions in a
>> handful of drivers and simplify the addition of new drivers.
>>
>> Signed-off-by: Eric Nelson 
>> Reviewed-by: Stephen Warren 
>> ---
>>   V2 removes parsing of offset from the gpio_find_and_xlate routine,
>>   and only parses the offset and GPIO_ACTIVE_LOW flag when a
>>   driver-specific xlate is unavailable.
>>
>>   V3 re-works tests of the argument count as suggested by Stephen Warren
>>   and will allow parsing of nodes with no flags field:
>> <&gpio1 2>
>>
>>   V4 fixes an indent with spaces instead of tabs
>>
>>  drivers/gpio/gpio-uclass.c | 30 +++---
>>  include/asm-generic/gpio.h | 19 ++-
>>  2 files changed, 37 insertions(+), 12 deletions(-)
>
> Acked-by: Simon Glass 

Applied to u-boot-dm, thanks!
___
U-Boot mailing list
U-Boot@lists.denx.de
http://lists.denx.de/mailman/listinfo/u-boot