hc
2023-12-09 b22da3d8526a935aa31e086e63f60ff3246cb61c
kernel/include/linux/mfd/rn5t618.h
....@@ -1,14 +1,8 @@
1
+/* SPDX-License-Identifier: GPL-2.0-only */
12 /*
23 * MFD core driver for Ricoh RN5T618 PMIC
34 *
45 * Copyright (C) 2014 Beniamino Galvani <b.galvani@gmail.com>
5
- *
6
- * This program is free software; you can redistribute it and/or
7
- * modify it under the terms of the GNU General Public License
8
- * version 2 as published by the Free Software Foundation.
9
- *
10
- * You should have received a copy of the GNU General Public License
11
- * along with this program. If not, see <http://www.gnu.org/licenses/>.
126 */
137
148 #ifndef __LINUX_MFD_RN5T618_H
....@@ -145,6 +139,17 @@
145139 #define RN5T618_INTPOL 0x9c
146140 #define RN5T618_INTEN 0x9d
147141 #define RN5T618_INTMON 0x9e
142
+
143
+#define RN5T618_RTC_SECONDS 0xA0
144
+#define RN5T618_RTC_MDAY 0xA4
145
+#define RN5T618_RTC_MONTH 0xA5
146
+#define RN5T618_RTC_YEAR 0xA6
147
+#define RN5T618_RTC_ADJUST 0xA7
148
+#define RN5T618_RTC_ALARM_Y_SEC 0xA8
149
+#define RN5T618_RTC_DAL_MONTH 0xAC
150
+#define RN5T618_RTC_CTRL1 0xAE
151
+#define RN5T618_RTC_CTRL2 0xAF
152
+
148153 #define RN5T618_PREVINDAC 0xb0
149154 #define RN5T618_BATDAC 0xb1
150155 #define RN5T618_CHGCTL1 0xb3
....@@ -248,9 +253,24 @@
248253 RC5T619,
249254 };
250255
256
+/* RN5T618 IRQ definitions */
257
+enum {
258
+ RN5T618_IRQ_SYS = 0,
259
+ RN5T618_IRQ_DCDC,
260
+ RN5T618_IRQ_RTC,
261
+ RN5T618_IRQ_ADC,
262
+ RN5T618_IRQ_GPIO,
263
+ RN5T618_IRQ_CHG,
264
+ RN5T618_NR_IRQS,
265
+};
266
+
251267 struct rn5t618 {
252268 struct regmap *regmap;
269
+ struct device *dev;
253270 long variant;
271
+
272
+ int irq;
273
+ struct regmap_irq_chip_data *irq_data;
254274 };
255275
256276 #endif /* __LINUX_MFD_RN5T618_H */