summaryrefslogtreecommitdiff
path: root/include/sbi_utils/gpio/gpio.h
AgeCommit message (Collapse)AuthorFilesLines
2024-11-28lib: utils/gpio: Use fdt_driver for initializationSamuel Holland1-1/+1
FDT gpio drivers have an extra .xlate operation, so they need to embed the `struct fdt_driver` inside the subsystem-specific type. The gpio subsystem always initializes the driver for a specific DT node. Signed-off-by: Samuel Holland <samuel.holland@sifive.com> Reviewed-by: Anup Patel <anup@brainfault.org>
2021-11-03lib: utils/gpio: use list for driversNikita Shubin1-0/+8
Convert static array to sbi_list. This removes size limitation, makes add/remove more efficient and saves space. Signed-off-by: Nikita Shubin <n.shubin@yadro.com> Reviewed-by: Anup Patel <anup.patel@wdc.com>
2021-07-17lib: utils/gpio: Add generic GPIO configuration libraryAnup Patel1-0/+99
We add generic GPIO configuration library which is independent of hardware description format (FDT or ACPI). The OpenSBI platform support or GPIO drivers can register GPIO chip instances which can be discovered and used by different GPIO clients. Each GPIO chip instance has a unique ID which can be used by GPIO clients to lookup GPIO chip instance. Signed-off-by: Anup Patel <anup.patel@wdc.com> Reviewed-by: Atish Patra <atish.patra@wdc.com>