linux-rtc.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [RFC PATCH 1/2] mfd: 88pm886: add the RTC cell and relevant definitions
@ 2024-09-20 16:12 Karel Balej
  2024-09-20 16:12 ` [RFC PATCH 2/2] rtc: add driver for Marvell 88PM886 PMIC RTC Karel Balej
  2024-10-09 10:06 ` (subset) [RFC PATCH 1/2] mfd: 88pm886: add the RTC cell and relevant definitions Lee Jones
  0 siblings, 2 replies; 9+ messages in thread
From: Karel Balej @ 2024-09-20 16:12 UTC (permalink / raw)
  To: Lee Jones, Alexandre Belloni, linux-kernel, linux-rtc
  Cc: duje.mihanovic, phone-devel, ~postmarketos/upstreaming

RTC lives on the base register page of the chip. Add definitions of the
registers needed for a basic set/read time functionality.

Signed-off-by: Karel Balej <balejk@matfyz.cz>
---
 drivers/mfd/88pm886.c       | 1 +
 include/linux/mfd/88pm886.h | 9 +++++++++
 2 files changed, 10 insertions(+)

diff --git a/drivers/mfd/88pm886.c b/drivers/mfd/88pm886.c
index dbe9efc027d2..891fdce5d8c1 100644
--- a/drivers/mfd/88pm886.c
+++ b/drivers/mfd/88pm886.c
@@ -37,6 +37,7 @@ static struct resource pm886_onkey_resources[] = {
 static struct mfd_cell pm886_devs[] = {
 	MFD_CELL_RES("88pm886-onkey", pm886_onkey_resources),
 	MFD_CELL_NAME("88pm886-regulator"),
+	MFD_CELL_NAME("88pm886-rtc"),
 };
 
 static int pm886_power_off_handler(struct sys_off_data *sys_off_data)
diff --git a/include/linux/mfd/88pm886.h b/include/linux/mfd/88pm886.h
index 133aa302e492..85eca44f39ab 100644
--- a/include/linux/mfd/88pm886.h
+++ b/include/linux/mfd/88pm886.h
@@ -31,6 +31,15 @@
 #define PM886_INT_WC			BIT(1)
 #define PM886_INT_MASK_MODE		BIT(2)
 
+#define PM886_REG_RTC_CNT1		0xd1
+#define PM886_REG_RTC_CNT2		0xd2
+#define PM886_REG_RTC_CNT3		0xd3
+#define PM886_REG_RTC_CNT4		0xd4
+#define PM886_REG_RTC_SPARE1		0xea
+#define PM886_REG_RTC_SPARE2		0xeb
+#define PM886_REG_RTC_SPARE3		0xec
+#define PM886_REG_RTC_SPARE4		0xed
+#define PM886_REG_RTC_SPARE5		0xee
 #define PM886_REG_RTC_SPARE6		0xef
 
 #define PM886_REG_BUCK_EN		0x08
-- 
2.46.0


^ permalink raw reply related	[flat|nested] 9+ messages in thread

end of thread, other threads:[~2024-10-11  7:40 UTC | newest]

Thread overview: 9+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2024-09-20 16:12 [RFC PATCH 1/2] mfd: 88pm886: add the RTC cell and relevant definitions Karel Balej
2024-09-20 16:12 ` [RFC PATCH 2/2] rtc: add driver for Marvell 88PM886 PMIC RTC Karel Balej
2024-10-09 10:06 ` (subset) [RFC PATCH 1/2] mfd: 88pm886: add the RTC cell and relevant definitions Lee Jones
2024-10-09 19:03   ` Karel Balej
2024-10-10  8:31     ` Lee Jones
2024-10-10  8:35       ` Lee Jones
2024-10-10 16:40         ` Karel Balej
2024-10-11  7:40           ` Lee Jones
2024-10-10  8:35   ` Lee Jones

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).