summaryrefslogtreecommitdiff
path: root/include
diff options
context:
space:
mode:
authorSvyatoslav Ryhel <[email protected]>2023-07-15 22:25:03 +0300
committerSvyatoslav Ryhel <[email protected]>2023-12-19 20:53:53 +0200
commit6b24c372c1e59e461e2f00e09dd1f8da29263450 (patch)
treedca65430d56c7557b1e636ed52495e46ca116e96 /include
parent936d0f9dd713a913fe952eae576c893e1d5ecbd1 (diff)
drivers: gpio: implement MAX77663 GPIO cell
MAXIM Semiconductor's PMIC, MAX77663 has 8 GPIO pins and 3 GPIO-like pins. It also supports interrupts from these pins. Add GPIO driver for these pins to control via GPIO APIs. Signed-off-by: Svyatoslav Ryhel <[email protected]>
Diffstat (limited to 'include')
-rw-r--r--include/dt-bindings/pmic/max77663.h18
-rw-r--r--include/power/max77663.h1
2 files changed, 19 insertions, 0 deletions
diff --git a/include/dt-bindings/pmic/max77663.h b/include/dt-bindings/pmic/max77663.h
new file mode 100644
index 00000000000..ee169a83e3b
--- /dev/null
+++ b/include/dt-bindings/pmic/max77663.h
@@ -0,0 +1,18 @@
+/* SPDX-License-Identifier: GPL-2.0+ */
+/*
+ * Copyright(C) 2023 Svyatoslav Ryhel <[email protected]>
+ */
+
+#ifndef _DT_BINDINGS_MAX77663_H_
+#define _DT_BINDINGS_MAX77663_H_
+
+/*
+ * MAX77663 has 8 GPIO (0 to 7) and 3 KEYS
+ * KEYS are appended after GPIOs
+ */
+
+#define EN0 10
+#define ACOK 9
+#define LID 8
+
+#endif
diff --git a/include/power/max77663.h b/include/power/max77663.h
index b3ae3dabf46..fcb5916f27e 100644
--- a/include/power/max77663.h
+++ b/include/power/max77663.h
@@ -13,6 +13,7 @@
#define MAX77663_LDO_DRIVER "max77663_ldo"
#define MAX77663_SD_DRIVER "max77663_sd"
#define MAX77663_RST_DRIVER "max77663_rst"
+#define MAX77663_GPIO_DRIVER "max77663_gpio"
/* Step-Down (SD) Regulator calculations */
#define SD_STATUS_MASK 0x30