From e72eff5a360a25f03ae43da25dbe13a4effd31d8 Mon Sep 17 00:00:00 2001 From: Alejandro Garcia Date: Sun, 1 Nov 2026 08:05:19 -0800 Subject: [PATCH 1/6] drm/panel: samsung-s6e3fc3: support sleep and a cold restart from KMS Mark a panel taken over from the bootloader as prepared and enabled, so drm_panel_disable() and drm_panel_unprepare() reach it, and track whether it is out of reset and sleep. While it is not, backlight updates only record the new state (drm_panel_enable() applies it through backlight_enable()). prepare() leaves the display off, which the reset does. Take the panel's lock in prepare/enable/disable/unprepare and in backlight updates, so their command sequences don't interleave. This follows the same change to the S6E3HC4 driver, for the Pixel 7 Pro, and lets gs-decon put the Pixel 7's panel to sleep with the screen off. Tested on a Pixel 7 from slot B (7.3.0-rc6), with gs-decon driving the screen: with gs_decon.screen_off=2, DPMS off put the panel to sleep and DPMS on woke it through the cold init (reset, the vendor init at 60 Hz, TE2 and DSC) with the picture correct; the power key's lock turned the screen off and a tap brought it back. No DSIM errors. Assisted-by: Claude Opus 5.5 Signed-off-by: Alejandro Garcia --- drivers/gpu/drm/panel/panel-samsung-s6e3fc3.c | 37 ++++++++++++++++++- 1 file changed, 36 insertions(+), 1 deletion(-) diff --git a/drivers/gpu/drm/panel/panel-samsung-s6e3fc3.c b/drivers/gpu/drm/panel/panel-samsung-s6e3fc3.c index 56d97ec744..c5e55917ce 100644 --- a/drivers/gpu/drm/panel/panel-samsung-s6e3fc3.c +++ b/drivers/gpu/drm/panel/panel-samsung-s6e3fc3.c @@ -17,6 +17,7 @@ #include #include #include +#include #include #include