From 9094f961856babe154a53da7b7dcd680bd8c9305 Mon Sep 17 00:00:00 2001
From: Dave Stevenson <dave.stevenson@raspberrypi.com>
Date: Thu, 23 Apr 2026 17:41:55 +0100
Subject: [PATCH] regulator: rpi-panel-v2: Cache regmap values

Not all implementations of the V2 regulator support reading back
the value of registers, which makes the GPIO control fail.
Enable the regmap caching to avoid this.

Signed-off-by: Dave Stevenson <dave.stevenson@raspberrypi.com>
---
 drivers/regulator/rpi-panel-v2-regulator.c | 1 +
 1 file changed, 1 insertion(+)

--- a/drivers/regulator/rpi-panel-v2-regulator.c
+++ b/drivers/regulator/rpi-panel-v2-regulator.c
@@ -33,6 +33,7 @@ static const struct regmap_config rpi_pa
 	.val_bits = 8,
 	.max_register = REG_PWM,
 	.can_sleep = true,
+	.cache_type = REGCACHE_MAPLE,
 };
 
 static int rpi_panel_v2_pwm_apply(struct pwm_chip *chip, struct pwm_device *pwm,
