lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <aVJh2xdCreGpi_f9@SoMainline.org>
Date: Mon, 29 Dec 2025 12:21:37 +0100
From: Marijn Suijten <marijn.suijten@...ainline.org>
To: Linus Walleij <linusw@...nel.org>
Cc: Neil Armstrong <neil.armstrong@...aro.org>, 
	Sam Ravnborg <sam@...nborg.org>, David Airlie <airlied@...il.com>, 
	Rob Herring <robh+dt@...nel.org>, Krzysztof Kozlowski <krzysztof.kozlowski+dt@...aro.org>, 
	Conor Dooley <conor+dt@...nel.org>, Andy Gross <agross@...nel.org>, 
	Bjorn Andersson <andersson@...nel.org>, Jessica Zhang <jesszhan0024@...il.com>, 
	Maarten Lankhorst <maarten.lankhorst@...ux.intel.com>, Maxime Ripard <mripard@...nel.org>, 
	Thomas Zimmermann <tzimmermann@...e.de>, Simona Vetter <simona@...ll.ch>, 
	Casey Connolly <casey.connolly@...aro.org>, Rob Herring <robh@...nel.org>, 
	Krzysztof Kozlowski <krzk+dt@...nel.org>, Simona Vetter <simona.vetter@...ll.ch>, 
	~postmarketos/upstreaming@...ts.sr.ht, 
	AngeloGioacchino Del Regno <angelogioacchino.delregno@...ainline.org>, Martin Botka <martin.botka@...ainline.org>, 
	Jami Kettunen <jami.kettunen@...ainline.org>, dri-devel@...ts.freedesktop.org, linux-kernel@...r.kernel.org, 
	devicetree@...r.kernel.org, linux-arm-msm@...r.kernel.org, 
	Abhinav Kumar <quic_abhinavk@...cinc.com>, Kuogee Hsieh <quic_khsieh@...cinc.com>, 
	Jessica Zhang <quic_jesszhan@...cinc.com>, 
	AngeloGioacchino Del Regno <angelogioacchino.delregno@...labora.com>, Konrad Dybcio <konrad.dybcio@....qualcomm.com>, 
	Konrad Dybcio <konradybcio@...nel.org>, Dmitry Baryshkov <lumag@...nel.org>
Subject: Re: [PATCH v2 03/11] drm/panel: Add LGD LH599QH3-EDB1 panel driver
 for Sony Xperia XZ3

On 2025-12-26 14:12:25, Linus Walleij wrote:
...
> > +static int lgd_lh599qh3_edb1_program(struct lgd_lh599qh3_edb1 *ctx)
> > +{
> > +       struct mipi_dsi_multi_context dsi_ctx = { .dsi = ctx->dsi };
> > +
> > +       dsi_ctx.dsi->mode_flags |= MIPI_DSI_MODE_LPM;
> > +
> > +       mipi_dsi_dcs_write_seq_multi(&dsi_ctx, 0x7f, 0x5a, 0x5a);
> > +       mipi_dsi_dcs_write_seq_multi(&dsi_ctx, 0xf0, 0x5a, 0x5a);
> > +       mipi_dsi_dcs_write_seq_multi(&dsi_ctx, 0xf1, 0x5a, 0x5a);
> > +       mipi_dsi_dcs_write_seq_multi(&dsi_ctx, 0xf2, 0x5a, 0x5a);
> 
> Clearly an "unlock" sequence.
> 
> > +       mipi_dsi_dcs_write_seq_multi(&dsi_ctx, 0x02, 0x01);
> > +       mipi_dsi_dcs_write_seq_multi(&dsi_ctx, 0x59, 0x01);
> > +       mipi_dsi_dcs_write_seq_multi(&dsi_ctx, MIPI_DCS_WRITE_CONTROL_DISPLAY,
> > +                                    WRITE_CONTROL_DISPLAY_BACKLIGHT);
> > +       mipi_dsi_dcs_write_seq_multi(&dsi_ctx, 0x57, 0x20, 0x80, 0xde, 0x60, 0x00);
> > +       mipi_dsi_dcs_set_column_address_multi(&dsi_ctx, 0, 1440 - 1);
> > +       mipi_dsi_dcs_set_page_address_multi(&dsi_ctx, 0, 2880 - 1);
> > +
> > +       mipi_dsi_dcs_write_seq_multi(&dsi_ctx, MIPI_DCS_WRITE_POWER_SAVE, 0x00);
> > +
> > +       mipi_dsi_dcs_set_tear_on_multi(&dsi_ctx, MIPI_DSI_DCS_TEAR_MODE_VBLANK);
> > +
> > +       mipi_dsi_dcs_write_seq_multi(&dsi_ctx, 0x7f, 0x5a, 0x5a);
> > +       mipi_dsi_dcs_write_seq_multi(&dsi_ctx, 0xf0, 0x5a, 0x5a);
> > +       mipi_dsi_dcs_write_seq_multi(&dsi_ctx, 0xf1, 0x5a, 0x5a);
> > +       mipi_dsi_dcs_write_seq_multi(&dsi_ctx, 0xf2, 0x5a, 0x5a);
> 
> Cleary another copy of the "unlock" sequence.
> 
> Can you break it out to a subroutine?
> lgd_lh599qh3_edb1_unlock()?

Sure, though unsure where the "lock" sequence resides (and why it needs to be
unlocked twice, unless this was autogenerated and is unnecessary, or implies a
"flush" of sorts) or why it looks so familiar to the Samsung panels.

Will rename it to lgd_lh599qh3_edb1_unlock_multi() and pass it a
mipi_dsi_multi_context so that no extra return-code handling needs to be
implemented.

> +/- this nitpick:
> Reviewed-by: Linus Walleij <linusw@...nel.org>

Just making sure, you reviewed the SOFEF01 driver with your Linaro address,
which one do you prefer or should I keep this distinction?

- Marijn

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ