[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20230815023426.15076-6-jiansheng.wu@unisoc.com>
Date: Tue, 15 Aug 2023 10:34:24 +0800
From: Jiansheng Wu <jiansheng.wu@...soc.com>
To: Mark Brown <broonie@...nel.org>, Orson Zhai <orsonzhai@...il.com>,
Baolin Wang <baolin.wang@...ux.alibaba.com>,
Chunyan Zhang <zhang.lyra@...il.com>
CC: <linux-spi@...r.kernel.org>, <linux-kernel@...r.kernel.org>,
<yongzhi.chen@...soc.com>, <xiaoqing.wu@...soc.com>,
<jianshengwu16@...il.com>
Subject: [PATCH 6/8] Spi: sprd-adi: Supported adi controller on UMS9620
Added ADI-controller on UMS9620 and reset regs on UMP9620, that is
a PMIC SoC integrated in UMS9620.
Signed-off-by: XiaoQing Wu <xiaoqing.wu@...soc.com>
Signed-off-by: Jiansheng Wu <jiansheng.wu@...soc.com>
---
drivers/spi/spi-sprd-adi.c | 15 +++++++++++++++
1 file changed, 15 insertions(+)
diff --git a/drivers/spi/spi-sprd-adi.c b/drivers/spi/spi-sprd-adi.c
index c31035fffe4c..0b20c228e119 100644
--- a/drivers/spi/spi-sprd-adi.c
+++ b/drivers/spi/spi-sprd-adi.c
@@ -111,6 +111,9 @@
#define SC2730_CLK_EN 0x1810
#define SC2730_WDG_BASE 0x40
#define SC2730_RST_STATUS 0x1bac
+#define UMP9620_RST_STATUS 0x23ac
+#define UMP9620_SWRST_CTRL0 0x23f8
+#define UMP9620_SOFT_RST_HW 0x2024
#define SC2730_SWRST_CTRL0 0x1bf8
#define SC2730_SOFT_RST_HW 0x1824
#define REG_RST_EN BIT(4)
@@ -687,6 +690,14 @@ static struct sprd_adi_data ums512_data = {
.softrst_base = SC2730_SOFT_RST_HW,
};
+static struct sprd_adi_data ums9620_data = {
+ .slave_offset = ADI_15BIT_SLAVE_OFFSET,
+ .slave_addr_size = ADI_15BIT_SLAVE_ADDR_SIZE,
+ .rst_sts = UMP9620_RST_STATUS,
+ .swrst_base = UMP9620_SWRST_CTRL0,
+ .softrst_base = UMP9620_SOFT_RST_HW,
+};
+
static const struct of_device_id sprd_adi_of_match[] = {
{
.compatible = "sprd,sc9860-adi",
@@ -700,6 +711,10 @@ static const struct of_device_id sprd_adi_of_match[] = {
.compatible = "sprd,ums512-adi",
.data = &ums512_data,
},
+ {
+ .compatible = "sprd,ums9620-adi",
+ .data = &ums9620_data,
+ },
{ },
};
MODULE_DEVICE_TABLE(of, sprd_adi_of_match);
--
2.17.1
Powered by blists - more mailing lists