1
0
mirror of https://xff.cz/git/u-boot/ synced 2025-11-01 19:05:51 +01:00

gpio: sifive: add support for DM based gpio driver for FU540-SoC

This patch adds a DM based driver model for gpio controller present in
FU540-C000 SoC on HiFive Unleashed A00 board. This SoC has one GPIO
bank and 16 GPIO lines in total, out of which GPIO0 to GPIO9 and
GPIO15 are routed to the J1 header on the board.

This implementation is ported from linux based gpio driver submitted
for review by Wesley W. Terpstra <wesley@sifive.com> and/or Atish Patra
<atish.patra@wdc.com> (many thanks !!). The linux driver can be referred
here [1]

[1]: https://lkml.org/lkml/2018/10/9/1103

Signed-off-by: Sagar Shrikant Kadam <sagar.kadam@sifive.com>
Reviewed-by: Bin Meng <bmeng.cn@gmail.com>
This commit is contained in:
Sagar Shrikant Kadam
2019-10-01 10:00:46 -07:00
committed by Andes
parent a2fce50455
commit d26b40450b
5 changed files with 226 additions and 0 deletions

View File

@@ -0,0 +1,6 @@
/* SPDX-License-Identifier: GPL-2.0+ */
/*
* Copyright 2018 SiFive, Inc.
*/
#include <asm-generic/gpio.h>