Re: [PATCH] pinctrl/amd: add get_direction handler

2018-02-22 Thread Linus Walleij
On Fri, Feb 16, 2018 at 8:12 PM, Daniel Kurtz wrote: > On boot, gpiochip_add_data() initializes the FLAG_IS_OUT bit in > desc->flags iff its gpio_chip does not have ->direction_input() handler, > else it is initialized to 0, which implies the GPIO is an "input". > > Later,

Re: [PATCH] pinctrl/amd: add get_direction handler

2018-02-22 Thread Linus Walleij
On Fri, Feb 16, 2018 at 8:12 PM, Daniel Kurtz wrote: > On boot, gpiochip_add_data() initializes the FLAG_IS_OUT bit in > desc->flags iff its gpio_chip does not have ->direction_input() handler, > else it is initialized to 0, which implies the GPIO is an "input". > > Later, the sysfs "direction"

[PATCH] pinctrl/amd: add get_direction handler

2018-02-16 Thread Daniel Kurtz
On boot, gpiochip_add_data() initializes the FLAG_IS_OUT bit in desc->flags iff its gpio_chip does not have ->direction_input() handler, else it is initialized to 0, which implies the GPIO is an "input". Later, the sysfs "direction" handler will use gpiod_get_direction() to get the current

[PATCH] pinctrl/amd: add get_direction handler

2018-02-16 Thread Daniel Kurtz
On boot, gpiochip_add_data() initializes the FLAG_IS_OUT bit in desc->flags iff its gpio_chip does not have ->direction_input() handler, else it is initialized to 0, which implies the GPIO is an "input". Later, the sysfs "direction" handler will use gpiod_get_direction() to get the current