[PATCH v2 4/7] mfd: qcom-pm8008: Drop GPIO support

From: Jishnu Prakash

Date: Wed Oct 14 2026 - 06:35:14 EST


GPIOs used on PM8008 and also the upcoming PM8010 have fixed
functions (reset and interrupt input functionality) so it is
not useful to expose them for general-purpose usage. Drop the
GPIO MFD cell and associated peripheral definitions.

Signed-off-by: Jishnu Prakash <jishnu.prakash@xxxxxxxxxxxxxxxx>
---
drivers/mfd/qcom-pm8008.c | 16 ----------------
1 file changed, 16 deletions(-)

diff --git a/drivers/mfd/qcom-pm8008.c b/drivers/mfd/qcom-pm8008.c
index 60204cc9a2dc..2d6c01cf54f3 100644
--- a/drivers/mfd/qcom-pm8008.c
+++ b/drivers/mfd/qcom-pm8008.c
@@ -31,19 +31,13 @@
enum {
PM8008_MISC,
PM8008_TEMP_ALARM,
- PM8008_GPIO1,
- PM8008_GPIO2,
PM8008_NUM_PERIPHS,
};

#define PM8008_PERIPH_0_BASE 0x900
#define PM8008_PERIPH_1_BASE 0x2400
-#define PM8008_PERIPH_2_BASE 0xc000
-#define PM8008_PERIPH_3_BASE 0xc100

#define PM8008_TEMP_ALARM_ADDR PM8008_PERIPH_1_BASE
-#define PM8008_GPIO1_ADDR PM8008_PERIPH_2_BASE
-#define PM8008_GPIO2_ADDR PM8008_PERIPH_3_BASE

/* PM8008 IRQ numbers */
#define PM8008_IRQ_MISC_UVLO 0
@@ -52,8 +46,6 @@ enum {
#define PM8008_IRQ_MISC_OTST3 3
#define PM8008_IRQ_MISC_LDO_OCP 4
#define PM8008_IRQ_TEMP_ALARM 5
-#define PM8008_IRQ_GPIO1 6
-#define PM8008_IRQ_GPIO2 7

enum {
SET_TYPE_INDEX,
@@ -84,15 +76,11 @@ static const struct regmap_irq pm8008_irqs[] = {
_IRQ(PM8008_IRQ_MISC_OTST3, PM8008_MISC, BIT(3), IRQ_TYPE_EDGE_RISING),
_IRQ(PM8008_IRQ_MISC_LDO_OCP, PM8008_MISC, BIT(4), IRQ_TYPE_EDGE_RISING),
_IRQ(PM8008_IRQ_TEMP_ALARM, PM8008_TEMP_ALARM,BIT(0), IRQ_TYPE_SENSE_MASK),
- _IRQ(PM8008_IRQ_GPIO1, PM8008_GPIO1, BIT(0), IRQ_TYPE_SENSE_MASK),
- _IRQ(PM8008_IRQ_GPIO2, PM8008_GPIO2, BIT(0), IRQ_TYPE_SENSE_MASK),
};

static const unsigned int pm8008_periph_base[] = {
PM8008_PERIPH_0_BASE,
PM8008_PERIPH_1_BASE,
- PM8008_PERIPH_2_BASE,
- PM8008_PERIPH_3_BASE,
};

static unsigned int pm8008_get_irq_reg(struct regmap_irq_chip_data *data,
@@ -180,7 +168,6 @@ static const struct resource pm8008_temp_res[] = {
static const struct mfd_cell pm8008_cells[] = {
MFD_CELL_NAME("pm8008-regulator"),
MFD_CELL_RES("qpnp-temp-alarm", pm8008_temp_res),
- MFD_CELL_NAME("pm8008-gpio"),
};

static void devm_irq_domain_fwnode_release(void *data)
@@ -252,9 +239,6 @@ static int pm8008_probe(struct i2c_client *client)
return ret;
}

- /* Needed by GPIO driver. */
- dev_set_drvdata(dev, regmap_irq_get_domain(irq_data));
-
return devm_mfd_add_devices(dev, PLATFORM_DEVID_AUTO, pm8008_cells,
ARRAY_SIZE(pm8008_cells), NULL, 0,
regmap_irq_get_domain(irq_data));

--
2.43.0