diff options
author | Geert Uytterhoeven <[email protected]> | 2020-05-11 16:52:54 +0200 |
---|---|---|
committer | Linus Walleij <[email protected]> | 2020-05-18 10:12:42 +0200 |
commit | 4c033b549912bc301c5e2adfb7b6ca007c11bf31 (patch) | |
tree | 82a28f20edfb2d106fcb6062bb8114e27a9d5416 /scripts/gdb/vmlinux-gdb.py | |
parent | 7b67b836625d9b8350aaec7ecd8347b0336f3f92 (diff) |
gpiolib: Add support for GPIO lookup by line name
Currently a GPIO lookup table can only refer to a specific GPIO by a
tuple, consisting of a GPIO controller label and a GPIO offset inside
the controller.
However, a GPIO may also carry a line name, defined by DT or ACPI.
If present, the line name is the most use-centric way to refer to a
GPIO. Hence add support for looking up GPIOs by line name.
Note that there is no guarantee that GPIO line names are globally
unique, so this will use the first match found.
Implement this by reusing the existing gpiod_lookup infrastructure.
Rename gpiod_lookup.chip_label to gpiod_lookup.key, to make it clear
that this field can have two meanings, and update the kerneldoc and
GPIO_LOOKUP*() macros.
Signed-off-by: Geert Uytterhoeven <[email protected]>
Tested-by: Eugeniu Rosca <[email protected]>
Reviewed-by: Ulrich Hecht <[email protected]>
Reviewed-by: Eugeniu Rosca <[email protected]>
Link: https://lore.kernel.org/r/[email protected]
Signed-off-by: Linus Walleij <[email protected]>
Diffstat (limited to 'scripts/gdb/vmlinux-gdb.py')
0 files changed, 0 insertions, 0 deletions