[PATCH 4/9] gpio: regmap: add the .get_direction() callback
Linus Walleij
linus.walleij at linaro.org
Fri Jul 11 10:43:13 PDT 2025
On Wed, Jul 9, 2025 at 5:09 PM Andrew Lunn <andrew at lunn.ch> wrote:
> This is not my area, so i will deffer to the GPIO
> Maintainers. However, it is not clear to me what get_direction()
> should return.
This callback should return the current direction as set up
in the hardware.
A major usecase is that this is called when the gpiochip is
registered to read out all the current directions of the GPIO
lines, so the kernel has a clear idea of the state of the
hardware.
Calling this should ideally result in a read of the status from
a hardware register.
Yours,
Linus Walleij
More information about the linux-arm-kernel
mailing list