mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
* [PATCH v3 0/5] Pixel 3 display fixes
@ 2026-11-25 13:08 David Heidelberg via B4 Relay
  2026-11-25 13:08 ` [PATCH v3 1/5] drm/panel: lg-sw43408: use the full DCS brightness range David Heidelberg via B4 Relay
                   ` (4 more replies)
  0 siblings, 5 replies; 9+ messages in thread
From: David Heidelberg via B4 Relay @ 2026-11-25 13:08 UTC (permalink / raw)
  To: Abel Vesa, Bjorn Andersson, Casey Connolly, Conor Dooley,
	David Airlie, Dmitry Baryshkov, Jessica Zhang, Konrad Dybcio,
	Krzysztof Kozlowski, Maarten Lankhorst, Marijn Suijten,
	Maxime Ripard, Neil Armstrong, Rob Herring, Simona Vetter,
	Sumit Semwal, Thomas Zimmermann, Vinod Koul
  Cc: devicetree, dri-devel, linux-arm-msm, linux-kernel, phone-devel,
	David Heidelberg

1. Update backlight intensity up to what vendor use for production
   phones.

2. Keep panel power supplies in sync so panel can recover from blanking.

Signed-off-by: David Heidelberg <david@ixit.cz>
---
Changes in v3:
- Properly fix the panel driver power-on/off cycle.
- Vendor in later downstream kernel commits increased BL limit to 900.
- Link to v2: https://patch.msgid.link/20260810-fix-blueline-panel-v2-0-9344dfdbc3f9@ixit.cz

Changes in v2:
- Unintended change 255 -> 256 for default brigtness. Drop it.
- Added R-bs.
- Link to v1: https://patch.msgid.link/20260809-fix-blueline-panel-v1-0-e7f3a6beb1fa@ixit.cz

---
David Heidelberg (5):
      drm/panel: lg-sw43408: use the full DCS brightness range
      drm/panel: lg-sw43408: skip backlight updates when unprepared
      drm/panel: lg-sw43408: split enable/disable from prepare/unprepare
      drm/panel: lg-sw43408: keep VPNL paired with VDDI and reset deasserted
      arm64: dts: qcom: sdm845-google: drop panel regulator-always-on

 .../arm64/boot/dts/qcom/sdm845-google-blueline.dts |   2 +
 arch/arm64/boot/dts/qcom/sdm845-google-common.dtsi |  10 --
 .../boot/dts/qcom/sdm845-google-crosshatch.dts     |   3 +
 drivers/gpu/drm/panel/panel-lg-sw43408.c           | 153 ++++++++++++++++++---
 4 files changed, 138 insertions(+), 30 deletions(-)
---
base-commit: 909ef7a9a30fa139e69e555e3606680f5cca7726
change-id: 20260809-fix-blueline-panel-af2b7c967f2d

Best regards,
--  
David Heidelberg <david@ixit.cz>



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

* [PATCH v3 1/5] drm/panel: lg-sw43408: use the full DCS brightness range
  2026-11-25 13:08 [PATCH v3 0/5] Pixel 3 display fixes David Heidelberg via B4 Relay
@ 2026-11-25 13:08 ` David Heidelberg via B4 Relay
  2026-11-25 15:39   ` Neil Armstrong
  2026-11-25 13:08 ` [PATCH v3 2/5] drm/panel: lg-sw43408: skip backlight updates when unprepared David Heidelberg via B4 Relay
                   ` (3 subsequent siblings)
  4 siblings, 1 reply; 9+ messages in thread
From: David Heidelberg via B4 Relay @ 2026-11-25 13:08 UTC (permalink / raw)
  To: Abel Vesa, Bjorn Andersson, Casey Connolly, Conor Dooley,
	David Airlie, Dmitry Baryshkov, Jessica Zhang, Konrad Dybcio,
	Krzysztof Kozlowski, Maarten Lankhorst, Marijn Suijten,
	Maxime Ripard, Neil Armstrong, Rob Herring, Simona Vetter,
	Sumit Semwal, Thomas Zimmermann, Vinod Koul
  Cc: devicetree, dri-devel, linux-arm-msm, linux-kernel, phone-devel,
	David Heidelberg

From: David Heidelberg <david@ixit.cz>

The vendor changed the value multiple times. Last value for production
devices was 900. HBM can go up to 1023, but keep value safe for now.

Fixes: 069a6c0e94f9 ("drm: panel: Add LG sw43408 panel driver")
Signed-off-by: David Heidelberg <david@ixit.cz>
---
 drivers/gpu/drm/panel/panel-lg-sw43408.c | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/drivers/gpu/drm/panel/panel-lg-sw43408.c b/drivers/gpu/drm/panel/panel-lg-sw43408.c
index 822318f546ef3..92cab6478ea61 100644
--- a/drivers/gpu/drm/panel/panel-lg-sw43408.c
+++ b/drivers/gpu/drm/panel/panel-lg-sw43408.c
@@ -197,17 +197,18 @@ static const struct backlight_ops sw43408_backlight_ops = {
 };
 
 static int sw43408_backlight_init(struct sw43408_panel *ctx)
 {
 	struct device *dev = &ctx->link->dev;
 	const struct backlight_properties props = {
 		.type = BACKLIGHT_PLATFORM,
 		.brightness = 255,
-		.max_brightness = 255,
+		/* HBM can go up to 1023, stay safe for now */
+		.max_brightness = 900,
 	};
 
 	ctx->base.backlight = devm_backlight_device_register(dev, dev_name(dev), dev,
 							     ctx->link,
 							     &sw43408_backlight_ops,
 							     &props);
 
 	if (IS_ERR(ctx->base.backlight))

-- 
2.55.0



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

* [PATCH v3 2/5] drm/panel: lg-sw43408: skip backlight updates when unprepared
  2026-11-25 13:08 [PATCH v3 0/5] Pixel 3 display fixes David Heidelberg via B4 Relay
  2026-11-25 13:08 ` [PATCH v3 1/5] drm/panel: lg-sw43408: use the full DCS brightness range David Heidelberg via B4 Relay
@ 2026-11-25 13:08 ` David Heidelberg via B4 Relay
  2026-11-25 18:49   ` Neil Armstrong
  2026-11-25 13:08 ` [PATCH v3 3/5] drm/panel: lg-sw43408: split enable/disable from prepare/unprepare David Heidelberg via B4 Relay
                   ` (2 subsequent siblings)
  4 siblings, 1 reply; 9+ messages in thread
From: David Heidelberg via B4 Relay @ 2026-11-25 13:08 UTC (permalink / raw)
  To: Abel Vesa, Bjorn Andersson, Casey Connolly, Conor Dooley,
	David Airlie, Dmitry Baryshkov, Jessica Zhang, Konrad Dybcio,
	Krzysztof Kozlowski, Maarten Lankhorst, Marijn Suijten,
	Maxime Ripard, Neil Armstrong, Rob Herring, Simona Vetter,
	Sumit Semwal, Thomas Zimmermann, Vinod Koul
  Cc: devicetree, dri-devel, linux-arm-msm, linux-kernel, phone-devel,
	David Heidelberg

From: David Heidelberg <david@ixit.cz>

sw43408_backlight_update_status() unconditionally sends a MIPI DSI DCS
brightness command even when the panel is unprepared and the DSI host is
powered down, causing sysfs brightness writes while blanked to fail with
-EIO.

Pass struct sw43408_panel as the backlight device private data and return
early when !ctx->base.prepared, matching other mainline MIPI DSI panel
drivers.

Fixes: 069a6c0e94f9 ("drm: panel: Add LG sw43408 panel driver")
Signed-off-by: David Heidelberg <david@ixit.cz>
---
 drivers/gpu/drm/panel/panel-lg-sw43408.c | 9 ++++++---
 1 file changed, 6 insertions(+), 3 deletions(-)

diff --git a/drivers/gpu/drm/panel/panel-lg-sw43408.c b/drivers/gpu/drm/panel/panel-lg-sw43408.c
index 92cab6478ea61..7f7d7b6b17f61 100644
--- a/drivers/gpu/drm/panel/panel-lg-sw43408.c
+++ b/drivers/gpu/drm/panel/panel-lg-sw43408.c
@@ -181,20 +181,23 @@ static const struct drm_display_mode lh546wf1_ed01_mode = {
 static int sw43408_get_modes(struct drm_panel *panel,
 			     struct drm_connector *connector)
 {
 	return drm_connector_helper_get_modes_fixed(connector, &lh546wf1_ed01_mode);
 }
 
 static int sw43408_backlight_update_status(struct backlight_device *bl)
 {
-	struct mipi_dsi_device *dsi = bl_get_data(bl);
+	struct sw43408_panel *ctx = bl_get_data(bl);
 	u16 brightness = backlight_get_brightness(bl);
 
-	return mipi_dsi_dcs_set_display_brightness_large(dsi, brightness);
+	if (!ctx->base.prepared)
+		return 0;
+
+	return mipi_dsi_dcs_set_display_brightness_large(ctx->link, brightness);
 }
 
 static const struct backlight_ops sw43408_backlight_ops = {
 	.update_status = sw43408_backlight_update_status,
 };
 
 static int sw43408_backlight_init(struct sw43408_panel *ctx)
 {
@@ -202,17 +205,17 @@ static int sw43408_backlight_init(struct sw43408_panel *ctx)
 	const struct backlight_properties props = {
 		.type = BACKLIGHT_PLATFORM,
 		.brightness = 255,
 		/* HBM can go up to 1023, stay safe for now */
 		.max_brightness = 900,
 	};
 
 	ctx->base.backlight = devm_backlight_device_register(dev, dev_name(dev), dev,
-							     ctx->link,
+							     ctx,
 							     &sw43408_backlight_ops,
 							     &props);
 
 	if (IS_ERR(ctx->base.backlight))
 		return dev_err_probe(dev, PTR_ERR(ctx->base.backlight),
 				     "Failed to create backlight\n");
 
 	return 0;

-- 
2.55.0



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

* [PATCH v3 3/5] drm/panel: lg-sw43408: split enable/disable from prepare/unprepare
  2026-11-25 13:08 [PATCH v3 0/5] Pixel 3 display fixes David Heidelberg via B4 Relay
  2026-11-25 13:08 ` [PATCH v3 1/5] drm/panel: lg-sw43408: use the full DCS brightness range David Heidelberg via B4 Relay
  2026-11-25 13:08 ` [PATCH v3 2/5] drm/panel: lg-sw43408: skip backlight updates when unprepared David Heidelberg via B4 Relay
@ 2026-11-25 13:08 ` David Heidelberg via B4 Relay
  2026-12-03 10:35   ` Neil Armstrong
  2026-11-25 13:08 ` [PATCH v3 4/5] drm/panel: lg-sw43408: keep VPNL paired with VDDI and reset deasserted David Heidelberg via B4 Relay
  2026-11-25 13:08 ` [PATCH v3 5/5] arm64: dts: qcom: sdm845-google: drop panel regulator-always-on David Heidelberg via B4 Relay
  4 siblings, 1 reply; 9+ messages in thread
From: David Heidelberg via B4 Relay @ 2026-11-25 13:08 UTC (permalink / raw)
  To: Abel Vesa, Bjorn Andersson, Casey Connolly, Conor Dooley,
	David Airlie, Dmitry Baryshkov, Jessica Zhang, Konrad Dybcio,
	Krzysztof Kozlowski, Maarten Lankhorst, Marijn Suijten,
	Maxime Ripard, Neil Armstrong, Rob Herring, Simona Vetter,
	Sumit Semwal, Thomas Zimmermann, Vinod Koul
  Cc: devicetree, dri-devel, linux-arm-msm, linux-kernel, phone-devel,
	David Heidelberg

From: David Heidelberg <david@ixit.cz>

Separate display blanking (enable/disable) from panel power sequencing
(prepare/unprepare), matching DRM panel conventions and other SDM845
AMOLED panel drivers:

- Move MIPI_DCS_SET_DISPLAY_OFF, MIPI_DCS_ENTER_SLEEP_MODE, and the
  100 ms sleep into sw43408_disable(), leaving sw43408_unprepare() to
  handle panel power-down.
- Move MIPI_DCS_SET_DISPLAY_ON and the 50 ms delay into sw43408_enable().

Signed-off-by: David Heidelberg <david@ixit.cz>
---
 drivers/gpu/drm/panel/panel-lg-sw43408.c | 32 +++++++++++++++++++++++---------
 1 file changed, 23 insertions(+), 9 deletions(-)

diff --git a/drivers/gpu/drm/panel/panel-lg-sw43408.c b/drivers/gpu/drm/panel/panel-lg-sw43408.c
index 7f7d7b6b17f61..7123ad18744cf 100644
--- a/drivers/gpu/drm/panel/panel-lg-sw43408.c
+++ b/drivers/gpu/drm/panel/panel-lg-sw43408.c
@@ -38,33 +38,38 @@ struct sw43408_panel {
 	struct drm_dsc_config dsc;
 };
 
 static inline struct sw43408_panel *to_panel_info(struct drm_panel *panel)
 {
 	return container_of(panel, struct sw43408_panel, base);
 }
 
-static int sw43408_unprepare(struct drm_panel *panel)
+static int sw43408_disable(struct drm_panel *panel)
 {
 	struct sw43408_panel *sw43408 = to_panel_info(panel);
 	struct mipi_dsi_multi_context ctx = { .dsi = sw43408->link };
-	int ret;
 
 	mipi_dsi_dcs_set_display_off_multi(&ctx);
 
 	mipi_dsi_dcs_enter_sleep_mode_multi(&ctx);
 
 	mipi_dsi_msleep(&ctx, 100);
 
-	gpiod_set_value(sw43408->reset_gpio, 1);
+	return ctx.accum_err;
+}
+
+static int sw43408_unprepare(struct drm_panel *panel)
+{
+	struct sw43408_panel *sw43408 = to_panel_info(panel);
 
-	ret = regulator_bulk_disable(ARRAY_SIZE(sw43408_supplies), sw43408->supplies);
+	gpiod_set_value(sw43408->reset_gpio, 1);
 
-	return ret ? : ctx.accum_err;
+	return regulator_bulk_disable(ARRAY_SIZE(sw43408_supplies),
+				      sw43408->supplies);
 }
 
 static int sw43408_program(struct drm_panel *panel)
 {
 	struct sw43408_panel *sw43408 = to_panel_info(panel);
 	struct mipi_dsi_multi_context ctx = { .dsi = sw43408->link };
 	struct drm_dsc_picture_parameter_set pps;
 
@@ -97,20 +102,16 @@ static int sw43408_program(struct drm_panel *panel)
 			       0x00, 0x00, 0x00, 0x19, 0x19, 0x19, 0x19, 0x19,
 			       0x19, 0x19, 0x19, 0x19, 0x19, 0x19, 0x19, 0x19,
 			       0x16, 0x16);
 	mipi_dsi_dcs_write_seq_multi(&ctx, 0xcb, 0x80, 0x5c, 0x07, 0x03, 0x28);
 	mipi_dsi_dcs_write_seq_multi(&ctx, 0xc0, 0x02, 0x02, 0x0f);
 	mipi_dsi_dcs_write_seq_multi(&ctx, 0x55, 0x04, 0x61, 0xdb, 0x04, 0x70, 0xdb);
 	mipi_dsi_dcs_write_seq_multi(&ctx, 0xb0, 0xca);
 
-	mipi_dsi_dcs_set_display_on_multi(&ctx);
-
-	mipi_dsi_msleep(&ctx, 50);
-
 	sw43408->link->mode_flags &= ~MIPI_DSI_MODE_LPM;
 
 	drm_dsc_pps_payload_pack(&pps, sw43408->link->dsc);
 
 	mipi_dsi_picture_parameter_set_multi(&ctx, &pps);
 
 	sw43408->link->mode_flags |= MIPI_DSI_MODE_LPM;
 
@@ -119,16 +120,27 @@ static int sw43408_program(struct drm_panel *panel)
 	 * PPS 1 if pps_identifier is 0
 	 * PPS 2 if pps_identifier is 1
 	 */
 	mipi_dsi_compression_mode_ext_multi(&ctx, true,
 					    MIPI_DSI_COMPRESSION_DSC, 1);
 	return ctx.accum_err;
 }
 
+static int sw43408_enable(struct drm_panel *panel)
+{
+	struct sw43408_panel *sw43408 = to_panel_info(panel);
+	struct mipi_dsi_multi_context ctx = { .dsi = sw43408->link };
+
+	mipi_dsi_dcs_set_display_on_multi(&ctx);
+	mipi_dsi_msleep(&ctx, 50);
+
+	return ctx.accum_err;
+}
+
 static void sw43408_reset(struct sw43408_panel *ctx)
 {
 	gpiod_set_value(ctx->reset_gpio, 0);
 	usleep_range(9000, 10000);
 	gpiod_set_value(ctx->reset_gpio, 1);
 	usleep_range(1000, 2000);
 	gpiod_set_value(ctx->reset_gpio, 0);
 	usleep_range(9000, 10000);
@@ -217,18 +229,20 @@ static int sw43408_backlight_init(struct sw43408_panel *ctx)
 	if (IS_ERR(ctx->base.backlight))
 		return dev_err_probe(dev, PTR_ERR(ctx->base.backlight),
 				     "Failed to create backlight\n");
 
 	return 0;
 }
 
 static const struct drm_panel_funcs sw43408_funcs = {
+	.disable = sw43408_disable,
 	.unprepare = sw43408_unprepare,
 	.prepare = sw43408_prepare,
+	.enable = sw43408_enable,
 	.get_modes = sw43408_get_modes,
 };
 
 static const struct of_device_id sw43408_of_match[] = {
 	{ .compatible = "lg,sw43408", }, /* legacy */
 	{ .compatible = "lg,sw43408-lh546wf1-ed01", },
 	{ /* sentinel */ }
 };

-- 
2.55.0



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

* [PATCH v3 4/5] drm/panel: lg-sw43408: keep VPNL paired with VDDI and reset deasserted
  2026-11-25 13:08 [PATCH v3 0/5] Pixel 3 display fixes David Heidelberg via B4 Relay
                   ` (2 preceding siblings ...)
  2026-11-25 13:08 ` [PATCH v3 3/5] drm/panel: lg-sw43408: split enable/disable from prepare/unprepare David Heidelberg via B4 Relay
@ 2026-11-25 13:08 ` David Heidelberg via B4 Relay
  2026-11-25 13:08 ` [PATCH v3 5/5] arm64: dts: qcom: sdm845-google: drop panel regulator-always-on David Heidelberg via B4 Relay
  4 siblings, 0 replies; 9+ messages in thread
From: David Heidelberg via B4 Relay @ 2026-11-25 13:08 UTC (permalink / raw)
  To: Abel Vesa, Bjorn Andersson, Casey Connolly, Conor Dooley,
	David Airlie, Dmitry Baryshkov, Jessica Zhang, Konrad Dybcio,
	Krzysztof Kozlowski, Maarten Lankhorst, Marijn Suijten,
	Maxime Ripard, Neil Armstrong, Rob Herring, Simona Vetter,
	Sumit Semwal, Thomas Zimmermann, Vinod Koul
  Cc: devicetree, dri-devel, linux-arm-msm, linux-kernel, phone-devel,
	David Heidelberg

From: David Heidelberg <david@ixit.cz>

On Google Pixel 3, VDDI (1.8 V) is shared with the STM FTS5 touchscreen
and remains powered while the system is awake or when double-tap wakeup
is armed, whereas VPNL (3.0 V) is exclusive to the panel.

Hardware testing on Pixel 3 shows the SW43408 DDIC only recovers cleanly
across unprepare/prepare when VDDI and VPNL stay paired and reset is not
held asserted while VDDI is powered:
- VDDI ON, VPNL ON, reset HIGH (Sleep-In): recovers cleanly.
- VDDI OFF, VPNL OFF, reset HIGH (cold POR): recovers cleanly.
- VDDI ON, VPNL OFF (with reset either HIGH or LOW): panel stays black
  on the next prepare even though DCS commands, TE, and LAB/IBB report
  normal status, until a full VDDI power cycle occurs.
- VDDI ON, VPNL ON, reset LOW: panel stays black on the next prepare.

Stop asserting reset_gpio in sw43408_unprepare() and sw43408_prepare()'s
poweroff error path, and disable VDDI first in sw43408_power_off(). Only
disable VPNL once VDDI actually powered down, checking both immediately
in sw43408_power_off() and from a late system sleep callback in case
a shared consumer drops VDDI later during system suspend.

Track whether the driver still holds VPNL enabled so sw43408_prepare()
balances the enable count without glitching VPNL, and register a devm
cleanup action to release VPNL if the driver is removed while
unprepared.

Fixes: 069a6c0e94f9 ("drm: panel: Add LG sw43408 panel driver")
Signed-off-by: David Heidelberg <david@ixit.cz>
---
 drivers/gpu/drm/panel/panel-lg-sw43408.c | 119 +++++++++++++++++++++++++++----
 1 file changed, 107 insertions(+), 12 deletions(-)

diff --git a/drivers/gpu/drm/panel/panel-lg-sw43408.c b/drivers/gpu/drm/panel/panel-lg-sw43408.c
index 7123ad18744cf..6854292bd99ca 100644
--- a/drivers/gpu/drm/panel/panel-lg-sw43408.c
+++ b/drivers/gpu/drm/panel/panel-lg-sw43408.c
@@ -15,28 +15,38 @@
 #include <video/mipi_display.h>
 
 #include <drm/drm_mipi_dsi.h>
 #include <drm/drm_panel.h>
 #include <drm/drm_probe_helper.h>
 #include <drm/display/drm_dsc.h>
 #include <drm/display/drm_dsc_helper.h>
 
+enum {
+	SW43408_SUPPLY_VDDI,
+	SW43408_SUPPLY_VPNL,
+};
+
 static const struct regulator_bulk_data sw43408_supplies[] = {
-	{ .supply = "vddi", /* 1.8 V */
-	  .init_load_uA = 62000 },
-	{ .supply = "vpnl", /* 3.0 V */
-	  .init_load_uA = 857000 },
+	[SW43408_SUPPLY_VDDI] = {
+		.supply = "vddi", /* 1.8 V */
+		.init_load_uA = 62000,
+	},
+	[SW43408_SUPPLY_VPNL] = {
+		.supply = "vpnl", /* 3.0 V */
+		.init_load_uA = 857000,
+	},
 };
 
 struct sw43408_panel {
 	struct drm_panel base;
 	struct mipi_dsi_device *link;
 
 	struct regulator_bulk_data *supplies;
+	bool vpnl_enabled;
 
 	struct gpio_desc *reset_gpio;
 
 	struct drm_dsc_config dsc;
 };
 
 static inline struct sw43408_panel *to_panel_info(struct drm_panel *panel)
 {
@@ -52,24 +62,90 @@ static int sw43408_disable(struct drm_panel *panel)
 
 	mipi_dsi_dcs_enter_sleep_mode_multi(&ctx);
 
 	mipi_dsi_msleep(&ctx, 100);
 
 	return ctx.accum_err;
 }
 
-static int sw43408_unprepare(struct drm_panel *panel)
+static int sw43408_maybe_disable_vpnl(struct sw43408_panel *ctx)
 {
-	struct sw43408_panel *sw43408 = to_panel_info(panel);
+	struct regulator *vddi = ctx->supplies[SW43408_SUPPLY_VDDI].consumer;
+	struct regulator *vpnl = ctx->supplies[SW43408_SUPPLY_VPNL].consumer;
+
+	/*
+	 * On Pixel 3, vddi is shared with the touchscreen and remains
+	 * powered while awake or when touch wakeup is armed. Dropping vpnl
+	 * (3.0 V) or asserting reset while vddi (1.8 V) stays powered leaves
+	 * the DDIC in a state no init sequence recovers from (until a full
+	 * vddi power cycle): it answers DCS commands and reports display-on,
+	 * but never lights up again.
+	 */
+	if (ctx->vpnl_enabled && regulator_is_enabled(vddi) == 0) {
+		int ret = regulator_disable(vpnl);
 
-	gpiod_set_value(sw43408->reset_gpio, 1);
+		if (ret < 0)
+			return ret;
+
+		ctx->vpnl_enabled = false;
+	}
 
-	return regulator_bulk_disable(ARRAY_SIZE(sw43408_supplies),
-				      sw43408->supplies);
+	return 0;
+}
+
+static int sw43408_power_off(struct sw43408_panel *ctx)
+{
+	struct regulator *vddi = ctx->supplies[SW43408_SUPPLY_VDDI].consumer;
+	int ret;
+
+	ret = regulator_disable(vddi);
+	if (ret)
+		return ret;
+
+	ret = sw43408_maybe_disable_vpnl(ctx);
+	if (ret)
+		goto recover_vddi;
+
+	return 0;
+
+recover_vddi:
+	/* vpnl disable failed, thus we need to re-enable vddi */
+	(void)regulator_enable(vddi);
+	return ret;
+}
+
+static int sw43408_suspend_late(struct device *dev)
+{
+	struct sw43408_panel *ctx = dev_get_drvdata(dev);
+	int ret;
+
+	if (ctx->base.prepared)
+		return 0;
+
+	ret = sw43408_maybe_disable_vpnl(ctx);
+	if (ret)
+		return ret;
+
+	return 0;
+}
+
+static void sw43408_cleanup_vpnl(void *data)
+{
+	struct sw43408_panel *ctx = data;
+
+	if (ctx->vpnl_enabled) {
+		regulator_disable(ctx->supplies[SW43408_SUPPLY_VPNL].consumer);
+		ctx->vpnl_enabled = false;
+	}
+}
+
+static int sw43408_unprepare(struct drm_panel *panel)
+{
+	return sw43408_power_off(to_panel_info(panel));
 }
 
 static int sw43408_program(struct drm_panel *panel)
 {
 	struct sw43408_panel *sw43408 = to_panel_info(panel);
 	struct mipi_dsi_multi_context ctx = { .dsi = sw43408->link };
 	struct drm_dsc_picture_parameter_set pps;
 
@@ -144,35 +220,45 @@ static void sw43408_reset(struct sw43408_panel *ctx)
 	usleep_range(1000, 2000);
 	gpiod_set_value(ctx->reset_gpio, 0);
 	usleep_range(9000, 10000);
 }
 
 static int sw43408_prepare(struct drm_panel *panel)
 {
 	struct sw43408_panel *ctx = to_panel_info(panel);
+	struct regulator *vddi = ctx->supplies[SW43408_SUPPLY_VDDI].consumer;
+	struct regulator *vpnl = ctx->supplies[SW43408_SUPPLY_VPNL].consumer;
 	int ret;
 
-	ret = regulator_bulk_enable(ARRAY_SIZE(sw43408_supplies), ctx->supplies);
+	ret = regulator_enable(vddi);
 	if (ret < 0)
 		return ret;
 
+	if (!ctx->vpnl_enabled) {
+		ret = regulator_enable(vpnl);
+		if (ret < 0) {
+			regulator_disable(vddi);
+			return ret;
+		}
+		ctx->vpnl_enabled = true;
+	}
+
 	usleep_range(5000, 6000);
 
 	sw43408_reset(ctx);
 
 	ret = sw43408_program(panel);
 	if (ret)
 		goto poweroff;
 
 	return 0;
 
 poweroff:
-	gpiod_set_value(ctx->reset_gpio, 1);
-	regulator_bulk_disable(ARRAY_SIZE(sw43408_supplies), ctx->supplies);
+	sw43408_power_off(ctx);
 	return ret;
 }
 
 static const struct drm_display_mode lh546wf1_ed01_mode = {
 	.clock = (1080 + 20 + 32 + 20) * (2160 + 20 + 4 + 20) * 60 / 1000,
 
 	.hdisplay = 1080,
 	.hsync_start = 1080 + 20,
@@ -255,16 +341,20 @@ static int sw43408_add(struct sw43408_panel *ctx)
 
 	ret = devm_regulator_bulk_get_const(dev,
 					    ARRAY_SIZE(sw43408_supplies),
 					    sw43408_supplies,
 					    &ctx->supplies);
 	if (ret < 0)
 		return ret;
 
+	ret = devm_add_action_or_reset(dev, sw43408_cleanup_vpnl, ctx);
+	if (ret < 0)
+		return ret;
+
 	ctx->reset_gpio = devm_gpiod_get(dev, "reset", GPIOD_OUT_LOW);
 	if (IS_ERR(ctx->reset_gpio)) {
 		return dev_err_probe(dev, PTR_ERR(ctx->reset_gpio),
 				     "Failed to get reset-gpios\n");
 	}
 
 	ret = sw43408_backlight_init(ctx);
 	if (ret < 0)
@@ -313,20 +403,25 @@ static int sw43408_probe(struct mipi_dsi_device *dsi)
 	ctx->dsc.bits_per_pixel = 8 << 4;
 	ctx->dsc.block_pred_enable = true;
 
 	dsi->dsc = &ctx->dsc;
 
 	return devm_mipi_dsi_attach(&dsi->dev, dsi);
 }
 
+static const struct dev_pm_ops sw43408_pm_ops = {
+	LATE_SYSTEM_SLEEP_PM_OPS(sw43408_suspend_late, NULL)
+};
+
 static struct mipi_dsi_driver sw43408_driver = {
 	.driver = {
 		.name = "panel-lg-sw43408",
 		.of_match_table = sw43408_of_match,
+		.pm = pm_sleep_ptr(&sw43408_pm_ops),
 	},
 	.probe = sw43408_probe,
 };
 module_mipi_dsi_driver(sw43408_driver);
 
 MODULE_AUTHOR("Sumit Semwal <sumit.semwal@linaro.org>");
 MODULE_DESCRIPTION("LG SW436408 MIPI-DSI LED panel");
 MODULE_LICENSE("GPL");

-- 
2.55.0



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

* [PATCH v3 5/5] arm64: dts: qcom: sdm845-google: drop panel regulator-always-on
  2026-11-25 13:08 [PATCH v3 0/5] Pixel 3 display fixes David Heidelberg via B4 Relay
                   ` (3 preceding siblings ...)
  2026-11-25 13:08 ` [PATCH v3 4/5] drm/panel: lg-sw43408: keep VPNL paired with VDDI and reset deasserted David Heidelberg via B4 Relay
@ 2026-11-25 13:08 ` David Heidelberg via B4 Relay
  4 siblings, 0 replies; 9+ messages in thread
From: David Heidelberg via B4 Relay @ 2026-11-25 13:08 UTC (permalink / raw)
  To: Abel Vesa, Bjorn Andersson, Casey Connolly, Conor Dooley,
	David Airlie, Dmitry Baryshkov, Jessica Zhang, Konrad Dybcio,
	Krzysztof Kozlowski, Maarten Lankhorst, Marijn Suijten,
	Maxime Ripard, Neil Armstrong, Rob Herring, Simona Vetter,
	Sumit Semwal, Thomas Zimmermann, Vinod Koul
  Cc: devicetree, dri-devel, linux-arm-msm, linux-kernel, phone-devel,
	David Heidelberg

From: David Heidelberg <david@ixit.cz>

Drop the regulator-always-on workaround from vreg_l14a_1p8 (vddi) and
vreg_l28a_3p0 (vpnl/vci) now that the LG SW43408 panel driver keeps vpnl
paired with vddi, allowing both rails to power down on Pixel 3 when
neither the panel nor the touchscreen requires vddi.

Define the supplies on Pixel 3 XL's framebuffer0 node so simpledrm keeps
the panel powered once regulator late cleanup runs, while intentionally
leaving them off Pixel 3's framebuffer0 node so simpledrm handover does
not drop vpnl independently of vddi.

Signed-off-by: David Heidelberg <david@ixit.cz>
---
 arch/arm64/boot/dts/qcom/sdm845-google-blueline.dts   |  2 ++
 arch/arm64/boot/dts/qcom/sdm845-google-common.dtsi    | 10 ----------
 arch/arm64/boot/dts/qcom/sdm845-google-crosshatch.dts |  3 +++
 3 files changed, 5 insertions(+), 10 deletions(-)

diff --git a/arch/arm64/boot/dts/qcom/sdm845-google-blueline.dts b/arch/arm64/boot/dts/qcom/sdm845-google-blueline.dts
index a000c75494f1c..f916f4dbb89c5 100644
--- a/arch/arm64/boot/dts/qcom/sdm845-google-blueline.dts
+++ b/arch/arm64/boot/dts/qcom/sdm845-google-blueline.dts
@@ -14,16 +14,18 @@ &battery {
 	voltage-min-design-microvolt = <3600000>;
 	voltage-max-design-microvolt = <4400000>;
 };
 
 &framebuffer0 {
 	width = <1080>;
 	height = <2160>;
 	stride = <(1080 * 4)>;
+
+	/* intentionally no supplies here, see the LG SW43408 driver */
 };
 
 &i2c2 {
 	clock-frequency = <1000000>;
 
 	status = "okay";
 
 	/* ST,FTS @ 49 */
diff --git a/arch/arm64/boot/dts/qcom/sdm845-google-common.dtsi b/arch/arm64/boot/dts/qcom/sdm845-google-common.dtsi
index 3c9656b88b696..c025b2df4ea25 100644
--- a/arch/arm64/boot/dts/qcom/sdm845-google-common.dtsi
+++ b/arch/arm64/boot/dts/qcom/sdm845-google-common.dtsi
@@ -246,21 +246,16 @@ vreg_l13a_2p95: ldo13 {
 			regulator-initial-mode = <RPMH_REGULATOR_MODE_HPM>;
 		};
 
 		vreg_l14a_1p8: ldo14 {
 			regulator-min-microvolt = <1800000>;
 			regulator-max-microvolt = <1800000>;
 			regulator-initial-mode = <RPMH_REGULATOR_MODE_HPM>;
 			regulator-boot-on;
-			/*
-			 * We can't properly bring the panel back if it gets turned off
-			 * so keep it's regulators always on for now.
-			 */
-			regulator-always-on;
 		};
 
 		vreg_l17a_1p3: ldo17 {
 			regulator-min-microvolt = <1304000>;
 			regulator-max-microvolt = <1304000>;
 			regulator-initial-mode = <RPMH_REGULATOR_MODE_HPM>;
 		};
 
@@ -308,21 +303,16 @@ vreg_l26a_1p2: ldo26 {
 			regulator-boot-on;
 		};
 
 		vreg_l28a_3p0: ldo28 {
 			regulator-min-microvolt = <2856000>;
 			regulator-max-microvolt = <3008000>;
 			regulator-initial-mode = <RPMH_REGULATOR_MODE_LPM>;
 			regulator-boot-on;
-			/*
-			 * We can't properly bring the panel back if it gets turned off
-			 * so keep it's regulators always on for now.
-			 */
-			regulator-always-on;
 		};
 	};
 
 	regulators-1 {
 		compatible = "qcom,pmi8998-rpmh-regulators";
 		qcom,pmic-id = "b";
 
 		vdd-bob-supply = <&vph_pwr>;
diff --git a/arch/arm64/boot/dts/qcom/sdm845-google-crosshatch.dts b/arch/arm64/boot/dts/qcom/sdm845-google-crosshatch.dts
index 2a81ca1d00b1b..7591c6ebb1cb9 100644
--- a/arch/arm64/boot/dts/qcom/sdm845-google-crosshatch.dts
+++ b/arch/arm64/boot/dts/qcom/sdm845-google-crosshatch.dts
@@ -19,16 +19,19 @@ &dispcc {
 	/* Disable for now so simple-framebuffer continues working */
 	status = "disabled";
 };
 
 &framebuffer0 {
 	width = <1440>;
 	height = <2960>;
 	stride = <(1440 * 4)>;
+
+	vddi-supply = <&vreg_l14a_1p8>;
+	vci-supply = <&vreg_l28a_3p0>;
 };
 
 &mdss {
 	/* Disable for now so simple-framebuffer continues working */
 	status = "disabled";
 };
 
 &wifi {

-- 
2.55.0



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

* Re: [PATCH v3 1/5] drm/panel: lg-sw43408: use the full DCS brightness range
  2026-11-25 13:08 ` [PATCH v3 1/5] drm/panel: lg-sw43408: use the full DCS brightness range David Heidelberg via B4 Relay
@ 2026-11-25 15:39   ` Neil Armstrong
  0 siblings, 0 replies; 9+ messages in thread
From: Neil Armstrong @ 2026-11-25 15:39 UTC (permalink / raw)
  To: david, Abel Vesa, Bjorn Andersson, Casey Connolly, Conor Dooley,
	David Airlie, Dmitry Baryshkov, Jessica Zhang, Konrad Dybcio,
	Krzysztof Kozlowski, Maarten Lankhorst, Marijn Suijten,
	Maxime Ripard, Rob Herring, Simona Vetter, Sumit Semwal,
	Thomas Zimmermann, Vinod Koul
  Cc: devicetree, dri-devel, linux-arm-msm, linux-kernel, phone-devel



On 11/25/26 14:08, David Heidelberg via B4 Relay wrote:
> From: David Heidelberg <david@ixit.cz>
> 
> The vendor changed the value multiple times. Last value for production
> devices was 900. HBM can go up to 1023, but keep value safe for now.
> 
> Fixes: 069a6c0e94f9 ("drm: panel: Add LG sw43408 panel driver")
> Signed-off-by: David Heidelberg <david@ixit.cz>
> ---
>   drivers/gpu/drm/panel/panel-lg-sw43408.c | 3 ++-
>   1 file changed, 2 insertions(+), 1 deletion(-)
> 
> diff --git a/drivers/gpu/drm/panel/panel-lg-sw43408.c b/drivers/gpu/drm/panel/panel-lg-sw43408.c
> index 822318f546ef3..92cab6478ea61 100644
> --- a/drivers/gpu/drm/panel/panel-lg-sw43408.c
> +++ b/drivers/gpu/drm/panel/panel-lg-sw43408.c
> @@ -197,17 +197,18 @@ static const struct backlight_ops sw43408_backlight_ops = {
>   };
>   
>   static int sw43408_backlight_init(struct sw43408_panel *ctx)
>   {
>   	struct device *dev = &ctx->link->dev;
>   	const struct backlight_properties props = {
>   		.type = BACKLIGHT_PLATFORM,
>   		.brightness = 255,
> -		.max_brightness = 255,
> +		/* HBM can go up to 1023, stay safe for now */
> +		.max_brightness = 900,
>   	};
>   
>   	ctx->base.backlight = devm_backlight_device_register(dev, dev_name(dev), dev,
>   							     ctx->link,
>   							     &sw43408_backlight_ops,
>   							     &props);
>   
>   	if (IS_ERR(ctx->base.backlight))
> 

Reviewed-by: Neil Armstrong <neil.armstrong@linaro.org>

Thanks,
Neil

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

* Re: [PATCH v3 2/5] drm/panel: lg-sw43408: skip backlight updates when unprepared
  2026-11-25 13:08 ` [PATCH v3 2/5] drm/panel: lg-sw43408: skip backlight updates when unprepared David Heidelberg via B4 Relay
@ 2026-11-25 18:49   ` Neil Armstrong
  0 siblings, 0 replies; 9+ messages in thread
From: Neil Armstrong @ 2026-11-25 18:49 UTC (permalink / raw)
  To: david, Abel Vesa, Bjorn Andersson, Casey Connolly, Conor Dooley,
	David Airlie, Dmitry Baryshkov, Jessica Zhang, Konrad Dybcio,
	Krzysztof Kozlowski, Maarten Lankhorst, Marijn Suijten,
	Maxime Ripard, Rob Herring, Simona Vetter, Sumit Semwal,
	Thomas Zimmermann, Vinod Koul
  Cc: devicetree, dri-devel, linux-arm-msm, linux-kernel, phone-devel



On 11/25/26 14:08, David Heidelberg via B4 Relay wrote:
> From: David Heidelberg <david@ixit.cz>
> 
> sw43408_backlight_update_status() unconditionally sends a MIPI DSI DCS
> brightness command even when the panel is unprepared and the DSI host is
> powered down, causing sysfs brightness writes while blanked to fail with
> -EIO.
> 
> Pass struct sw43408_panel as the backlight device private data and return
> early when !ctx->base.prepared, matching other mainline MIPI DSI panel
> drivers.
> 
> Fixes: 069a6c0e94f9 ("drm: panel: Add LG sw43408 panel driver")
> Signed-off-by: David Heidelberg <david@ixit.cz>
> ---
>   drivers/gpu/drm/panel/panel-lg-sw43408.c | 9 ++++++---
>   1 file changed, 6 insertions(+), 3 deletions(-)
> 
> diff --git a/drivers/gpu/drm/panel/panel-lg-sw43408.c b/drivers/gpu/drm/panel/panel-lg-sw43408.c
> index 92cab6478ea61..7f7d7b6b17f61 100644
> --- a/drivers/gpu/drm/panel/panel-lg-sw43408.c
> +++ b/drivers/gpu/drm/panel/panel-lg-sw43408.c
> @@ -181,20 +181,23 @@ static const struct drm_display_mode lh546wf1_ed01_mode = {
>   static int sw43408_get_modes(struct drm_panel *panel,
>   			     struct drm_connector *connector)
>   {
>   	return drm_connector_helper_get_modes_fixed(connector, &lh546wf1_ed01_mode);
>   }
>   
>   static int sw43408_backlight_update_status(struct backlight_device *bl)
>   {
> -	struct mipi_dsi_device *dsi = bl_get_data(bl);
> +	struct sw43408_panel *ctx = bl_get_data(bl);
>   	u16 brightness = backlight_get_brightness(bl);
>   
> -	return mipi_dsi_dcs_set_display_brightness_large(dsi, brightness);
> +	if (!ctx->base.prepared)
> +		return 0;
> +
> +	return mipi_dsi_dcs_set_display_brightness_large(ctx->link, brightness);
>   }
>   
>   static const struct backlight_ops sw43408_backlight_ops = {
>   	.update_status = sw43408_backlight_update_status,
>   };
>   
>   static int sw43408_backlight_init(struct sw43408_panel *ctx)
>   {
> @@ -202,17 +205,17 @@ static int sw43408_backlight_init(struct sw43408_panel *ctx)
>   	const struct backlight_properties props = {
>   		.type = BACKLIGHT_PLATFORM,
>   		.brightness = 255,
>   		/* HBM can go up to 1023, stay safe for now */
>   		.max_brightness = 900,
>   	};
>   
>   	ctx->base.backlight = devm_backlight_device_register(dev, dev_name(dev), dev,
> -							     ctx->link,
> +							     ctx,
>   							     &sw43408_backlight_ops,
>   							     &props);
>   
>   	if (IS_ERR(ctx->base.backlight))
>   		return dev_err_probe(dev, PTR_ERR(ctx->base.backlight),
>   				     "Failed to create backlight\n");
>   
>   	return 0;
> 


Reviewed-by: Neil Armstrong <neil.armstrong@linaro.org>

Thanks,
Neil

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

* Re: [PATCH v3 3/5] drm/panel: lg-sw43408: split enable/disable from prepare/unprepare
  2026-11-25 13:08 ` [PATCH v3 3/5] drm/panel: lg-sw43408: split enable/disable from prepare/unprepare David Heidelberg via B4 Relay
@ 2026-12-03 10:35   ` Neil Armstrong
  0 siblings, 0 replies; 9+ messages in thread
From: Neil Armstrong @ 2026-12-03 10:35 UTC (permalink / raw)
  To: david, Abel Vesa, Bjorn Andersson, Casey Connolly, Conor Dooley,
	David Airlie, Dmitry Baryshkov, Jessica Zhang, Konrad Dybcio,
	Krzysztof Kozlowski, Maarten Lankhorst, Marijn Suijten,
	Maxime Ripard, Rob Herring, Simona Vetter, Sumit Semwal,
	Thomas Zimmermann, Vinod Koul
  Cc: devicetree, dri-devel, linux-arm-msm, linux-kernel, phone-devel

On 11/25/26 14:08, David Heidelberg via B4 Relay wrote:
> From: David Heidelberg <david@ixit.cz>
> 
> Separate display blanking (enable/disable) from panel power sequencing
> (prepare/unprepare), matching DRM panel conventions and other SDM845
> AMOLED panel drivers:
> 
> - Move MIPI_DCS_SET_DISPLAY_OFF, MIPI_DCS_ENTER_SLEEP_MODE, and the
>    100 ms sleep into sw43408_disable(), leaving sw43408_unprepare() to
>    handle panel power-down.
> - Move MIPI_DCS_SET_DISPLAY_ON and the 50 ms delay into sw43408_enable().
> 
> Signed-off-by: David Heidelberg <david@ixit.cz>
> ---
>   drivers/gpu/drm/panel/panel-lg-sw43408.c | 32 +++++++++++++++++++++++---------
>   1 file changed, 23 insertions(+), 9 deletions(-)
> 
> diff --git a/drivers/gpu/drm/panel/panel-lg-sw43408.c b/drivers/gpu/drm/panel/panel-lg-sw43408.c
> index 7f7d7b6b17f61..7123ad18744cf 100644
> --- a/drivers/gpu/drm/panel/panel-lg-sw43408.c
> +++ b/drivers/gpu/drm/panel/panel-lg-sw43408.c
> @@ -38,33 +38,38 @@ struct sw43408_panel {
>   	struct drm_dsc_config dsc;
>   };
>   
>   static inline struct sw43408_panel *to_panel_info(struct drm_panel *panel)
>   {
>   	return container_of(panel, struct sw43408_panel, base);
>   }
>   
> -static int sw43408_unprepare(struct drm_panel *panel)
> +static int sw43408_disable(struct drm_panel *panel)
>   {
>   	struct sw43408_panel *sw43408 = to_panel_info(panel);
>   	struct mipi_dsi_multi_context ctx = { .dsi = sw43408->link };
> -	int ret;
>   
>   	mipi_dsi_dcs_set_display_off_multi(&ctx);
>   
>   	mipi_dsi_dcs_enter_sleep_mode_multi(&ctx);
>   
>   	mipi_dsi_msleep(&ctx, 100);
>   
> -	gpiod_set_value(sw43408->reset_gpio, 1);
> +	return ctx.accum_err;
> +}
> +
> +static int sw43408_unprepare(struct drm_panel *panel)
> +{
> +	struct sw43408_panel *sw43408 = to_panel_info(panel);
>   
> -	ret = regulator_bulk_disable(ARRAY_SIZE(sw43408_supplies), sw43408->supplies);
> +	gpiod_set_value(sw43408->reset_gpio, 1);
>   
> -	return ret ? : ctx.accum_err;
> +	return regulator_bulk_disable(ARRAY_SIZE(sw43408_supplies),
> +				      sw43408->supplies);
>   }
>   
>   static int sw43408_program(struct drm_panel *panel)
>   {
>   	struct sw43408_panel *sw43408 = to_panel_info(panel);
>   	struct mipi_dsi_multi_context ctx = { .dsi = sw43408->link };
>   	struct drm_dsc_picture_parameter_set pps;
>   
> @@ -97,20 +102,16 @@ static int sw43408_program(struct drm_panel *panel)
>   			       0x00, 0x00, 0x00, 0x19, 0x19, 0x19, 0x19, 0x19,
>   			       0x19, 0x19, 0x19, 0x19, 0x19, 0x19, 0x19, 0x19,
>   			       0x16, 0x16);
>   	mipi_dsi_dcs_write_seq_multi(&ctx, 0xcb, 0x80, 0x5c, 0x07, 0x03, 0x28);
>   	mipi_dsi_dcs_write_seq_multi(&ctx, 0xc0, 0x02, 0x02, 0x0f);
>   	mipi_dsi_dcs_write_seq_multi(&ctx, 0x55, 0x04, 0x61, 0xdb, 0x04, 0x70, 0xdb);
>   	mipi_dsi_dcs_write_seq_multi(&ctx, 0xb0, 0xca);
>   
> -	mipi_dsi_dcs_set_display_on_multi(&ctx);
> -
> -	mipi_dsi_msleep(&ctx, 50);
> -
>   	sw43408->link->mode_flags &= ~MIPI_DSI_MODE_LPM;
>   
>   	drm_dsc_pps_payload_pack(&pps, sw43408->link->dsc);
>   
>   	mipi_dsi_picture_parameter_set_multi(&ctx, &pps);
>   
>   	sw43408->link->mode_flags |= MIPI_DSI_MODE_LPM;
>   
> @@ -119,16 +120,27 @@ static int sw43408_program(struct drm_panel *panel)
>   	 * PPS 1 if pps_identifier is 0
>   	 * PPS 2 if pps_identifier is 1
>   	 */
>   	mipi_dsi_compression_mode_ext_multi(&ctx, true,
>   					    MIPI_DSI_COMPRESSION_DSC, 1);
>   	return ctx.accum_err;
>   }
>   
> +static int sw43408_enable(struct drm_panel *panel)
> +{
> +	struct sw43408_panel *sw43408 = to_panel_info(panel);
> +	struct mipi_dsi_multi_context ctx = { .dsi = sw43408->link };
> +
> +	mipi_dsi_dcs_set_display_on_multi(&ctx);
> +	mipi_dsi_msleep(&ctx, 50);
> +
> +	return ctx.accum_err;
> +}
> +
>   static void sw43408_reset(struct sw43408_panel *ctx)
>   {
>   	gpiod_set_value(ctx->reset_gpio, 0);
>   	usleep_range(9000, 10000);
>   	gpiod_set_value(ctx->reset_gpio, 1);
>   	usleep_range(1000, 2000);
>   	gpiod_set_value(ctx->reset_gpio, 0);
>   	usleep_range(9000, 10000);
> @@ -217,18 +229,20 @@ static int sw43408_backlight_init(struct sw43408_panel *ctx)
>   	if (IS_ERR(ctx->base.backlight))
>   		return dev_err_probe(dev, PTR_ERR(ctx->base.backlight),
>   				     "Failed to create backlight\n");
>   
>   	return 0;
>   }
>   
>   static const struct drm_panel_funcs sw43408_funcs = {
> +	.disable = sw43408_disable,
>   	.unprepare = sw43408_unprepare,
>   	.prepare = sw43408_prepare,
> +	.enable = sw43408_enable,
>   	.get_modes = sw43408_get_modes,
>   };
>   
>   static const struct of_device_id sw43408_of_match[] = {
>   	{ .compatible = "lg,sw43408", }, /* legacy */
>   	{ .compatible = "lg,sw43408-lh546wf1-ed01", },
>   	{ /* sentinel */ }
>   };
> 

Reviewed-by: Neil Armstrong <neil.armstrong@linaro.org>

Thanks,
Neil

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

end of thread, other threads:[~2026-12-03 10:35 UTC | newest]

Thread overview: 9+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2026-11-25 13:08 [PATCH v3 0/5] Pixel 3 display fixes David Heidelberg via B4 Relay
2026-11-25 13:08 ` [PATCH v3 1/5] drm/panel: lg-sw43408: use the full DCS brightness range David Heidelberg via B4 Relay
2026-11-25 15:39   ` Neil Armstrong
2026-11-25 13:08 ` [PATCH v3 2/5] drm/panel: lg-sw43408: skip backlight updates when unprepared David Heidelberg via B4 Relay
2026-11-25 18:49   ` Neil Armstrong
2026-11-25 13:08 ` [PATCH v3 3/5] drm/panel: lg-sw43408: split enable/disable from prepare/unprepare David Heidelberg via B4 Relay
2026-12-03 10:35   ` Neil Armstrong
2026-11-25 13:08 ` [PATCH v3 4/5] drm/panel: lg-sw43408: keep VPNL paired with VDDI and reset deasserted David Heidelberg via B4 Relay
2026-11-25 13:08 ` [PATCH v3 5/5] arm64: dts: qcom: sdm845-google: drop panel regulator-always-on David Heidelberg via B4 Relay

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®