mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: David Heidelberg <david@ixit.cz>
To: Doug Anderson <dianders@chromium.org>
Cc: "Neil Armstrong" <neil.armstrong@linaro.org>,
	"Jessica Zhang" <jesszhan0024@gmail.com>,
	"Maarten Lankhorst" <maarten.lankhorst@linux.intel.com>,
	"Maxime Ripard" <mripard@kernel.org>,
	"Thomas Zimmermann" <tzimmermann@suse.de>,
	"David Airlie" <airlied@gmail.com>,
	"Simona Vetter" <simona@ffwll.ch>,
	"Guido Günther" <agx@sigxcpu.org>,
	"Alexander Martinz" <amartinz@shiftphones.com>,
	"Dmitry Baryshkov" <dmitry.baryshkov@oss.qualcomm.com>,
	dri-devel@lists.freedesktop.org, linux-kernel@vger.kernel.org,
	phone-devel@vger.kernel.org
Subject: Re: [PATCH v2 1/2] drm/panel: visionox-rm69299: Move off/sleep DSI commands to disable()
Date: Wed, 2 Dec 2026 17:53:54 +0100	[thread overview]
Message-ID: <9bc0a648-dc3d-4559-b17d-15164aff75c6@ixit.cz> (raw)
In-Reply-To: <CAD=FV=UPCEp5ZredhChXckoCbopbpLFgD3kRAvfm1RdOzWqp-A@mail.gmail.com>

On 02/12/2026 04:33, Doug Anderson wrote:
> Hi,
> 
> On Thu, Nov 26, 2026 at 11:57 AM David Heidelberg via B4 Relay
> <devnull+david.ixit.cz@kernel.org> wrote:
>>
>> From: Guido Günther <agx@sigxcpu.org>
>>
>> With prepare_prev_first set, DRM calls visionox_rm69299_unprepare()
>> after the display controller timing engine has been stopped and before
>> the DSI host bridge post_disable() resets the video engine. Sending the
>> display-off and enter-sleep DCS commands from unprepare() therefore
>> causes DSI timeouts on every screen blank/unblank on the SHIFT6mq:
>>
>> dmesg:
>>    msm_dsi ae94000.dsi: [drm:dsi_cmds2buf_tx] *ERROR* wait for video done timed out
>>    dsi_cmds2buf_tx: cmd dma tx failed, type=0x5, data0=0x28, len=4, ret=-110
>>    panel-visionox-rm69299 ae94000.dsi.0: sending DCS SET_DISPLAY_OFF failed: -110
>>
>> Move the display-off and enter-sleep DCS commands into a new disable()
>> callback so they execute while the DSI link is still active, while
>> keeping the power-on and initialization commands in prepare() where the
>> link is in LP11 before video starts.
>>
>> Fixes: 4a92ef0c57df ("drm/panel: visionox-rm69299: Make use of prepare_prev_first")
>> Signed-off-by: Guido Günther <agx@sigxcpu.org>
>> [David: keep power-on and init commands in prepare() per v1 review]
>> Signed-off-by: David Heidelberg <david@ixit.cz>
>> ---
>>   drivers/gpu/drm/panel/panel-visionox-rm69299.c | 10 +++++++++-
>>   1 file changed, 9 insertions(+), 1 deletion(-)
>>
>> diff --git a/drivers/gpu/drm/panel/panel-visionox-rm69299.c b/drivers/gpu/drm/panel/panel-visionox-rm69299.c
>> index 4309e04c35c4b..bca1004656e45 100644
>> --- a/drivers/gpu/drm/panel/panel-visionox-rm69299.c
>> +++ b/drivers/gpu/drm/panel/panel-visionox-rm69299.c
>> @@ -184,30 +184,37 @@ static int visionox_rm69299_power_on(struct visionox_rm69299 *ctx)
>>   static int visionox_rm69299_power_off(struct visionox_rm69299 *ctx)
>>   {
>>          gpiod_set_value(ctx->reset_gpio, 0);
>>
>>          return regulator_bulk_disable(ARRAY_SIZE(visionox_rm69299_supplies),
>>                                        ctx->supplies);
>>   }
>>
>> -static int visionox_rm69299_unprepare(struct drm_panel *panel)
>> +static int visionox_rm69299_disable(struct drm_panel *panel)
>>   {
>>          struct visionox_rm69299 *ctx = panel_to_ctx(panel);
>>          struct mipi_dsi_multi_context dsi_ctx = { .dsi = ctx->dsi };
>>
>>          ctx->dsi->mode_flags &= ~MIPI_DSI_MODE_LPM;
>>
>>          mipi_dsi_dcs_set_display_off_multi(&dsi_ctx);
>>
>>          /* 120ms delay required here as per DCS spec */
>>          mipi_dsi_msleep(&dsi_ctx, 120);
>>
>>          mipi_dsi_dcs_enter_sleep_mode_multi(&dsi_ctx);
>>
>> +       return dsi_ctx.accum_err;
> 
> The above should be `return 0;`. The old code didn't consider it a
> fatal error if mipi_dsi_dcs_set_display_off_multi() and
> mipi_dsi_dcs_enter_sleep_mode_multi() failed. You shouldn't either.
> The best you can do is continue on and try to power off.

Good point, thanks. I'll be in v3.

David


  reply	other threads:[~2026-12-02 16:54 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-11-26 19:57 [PATCH v2 0/2] " David Heidelberg via B4 Relay
2026-11-26 19:57 ` [PATCH v2 1/2] " David Heidelberg via B4 Relay
2026-12-02  3:33   ` Doug Anderson
2026-12-02 16:53     ` David Heidelberg [this message]
2026-11-26 19:57 ` [PATCH v2 2/2] drm/panel: visionox-rm69299: Move power_off() into unprepare() David Heidelberg via B4 Relay
2026-12-02  3:33   ` Doug Anderson

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=9bc0a648-dc3d-4559-b17d-15164aff75c6@ixit.cz \
    --to=david@ixit.cz \
    --cc=agx@sigxcpu.org \
    --cc=airlied@gmail.com \
    --cc=amartinz@shiftphones.com \
    --cc=dianders@chromium.org \
    --cc=dmitry.baryshkov@oss.qualcomm.com \
    --cc=dri-devel@lists.freedesktop.org \
    --cc=jesszhan0024@gmail.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=maarten.lankhorst@linux.intel.com \
    --cc=mripard@kernel.org \
    --cc=neil.armstrong@linaro.org \
    --cc=phone-devel@vger.kernel.org \
    --cc=simona@ffwll.ch \
    --cc=tzimmermann@suse.de \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
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®