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: <rpita5o6za64p7tamasssb2fja6h6ipr5cibh6gs7klkijyk6r@mausrcet2ycx>
Date: Fri, 10 May 2024 03:56:04 +0300
From: Dmitry Baryshkov <dmitry.baryshkov@...aro.org>
To: Barnabás Czémán <trabarni@...il.com>
Cc: Neil Armstrong <neil.armstrong@...aro.org>, 
	Jessica Zhang <quic_jesszhan@...cinc.com>, Sam Ravnborg <sam@...nborg.org>, 
	Maarten Lankhorst <maarten.lankhorst@...ux.intel.com>, Maxime Ripard <mripard@...nel.org>, 
	Thomas Zimmermann <tzimmermann@...e.de>, David Airlie <airlied@...il.com>, 
	Daniel Vetter <daniel@...ll.ch>, dri-devel@...ts.freedesktop.org, linux-kernel@...r.kernel.org
Subject: Re: [PATCH] drm/panel: jdi-fhd-r63452: move DCS off commands to
 disable

On Thu, May 09, 2024 at 08:14:07PM +0200, Barnabás Czémán wrote:
> Move DCS off commands from .unprepare to .disable so that they
> actually reach the DSI host.
> 
> Signed-off-by: Barnabás Czémán <trabarni@...il.com>
> ---
>  drivers/gpu/drm/panel/panel-jdi-fhd-r63452.c | 12 ++++++++++--
>  1 file changed, 10 insertions(+), 2 deletions(-)

I don't think this is correct. If the driver sends enable commands in
prepare, it should be able to send commands during unprepare too.

> 
> diff --git a/drivers/gpu/drm/panel/panel-jdi-fhd-r63452.c b/drivers/gpu/drm/panel/panel-jdi-fhd-r63452.c
> index 483dc88d16d8..f7222974d6ed 100644
> --- a/drivers/gpu/drm/panel/panel-jdi-fhd-r63452.c
> +++ b/drivers/gpu/drm/panel/panel-jdi-fhd-r63452.c
> @@ -169,6 +169,15 @@ static int jdi_fhd_r63452_prepare(struct drm_panel *panel)
>  }
>  
>  static int jdi_fhd_r63452_unprepare(struct drm_panel *panel)
> +{
> +	struct jdi_fhd_r63452 *ctx = to_jdi_fhd_r63452(panel);
> +
> +	gpiod_set_value_cansleep(ctx->reset_gpio, 1);
> +
> +	return 0;
> +}
> +
> +static int jdi_fhd_r63452_disable(struct drm_panel *panel)
>  {
>  	struct jdi_fhd_r63452 *ctx = to_jdi_fhd_r63452(panel);
>  	struct device *dev = &ctx->dsi->dev;
> @@ -178,8 +187,6 @@ static int jdi_fhd_r63452_unprepare(struct drm_panel *panel)
>  	if (ret < 0)
>  		dev_err(dev, "Failed to un-initialize panel: %d\n", ret);
>  
> -	gpiod_set_value_cansleep(ctx->reset_gpio, 1);
> -
>  	return 0;
>  }
>  
> @@ -219,6 +226,7 @@ static int jdi_fhd_r63452_get_modes(struct drm_panel *panel,
>  static const struct drm_panel_funcs jdi_fhd_r63452_panel_funcs = {
>  	.prepare = jdi_fhd_r63452_prepare,
>  	.unprepare = jdi_fhd_r63452_unprepare,
> +	.disable = jdi_fhd_r63452_disable,
>  	.get_modes = jdi_fhd_r63452_get_modes,
>  };
>  
> 
> ---
> base-commit: 704ba27ac55579704ba1289392448b0c66b56258
> change-id: 20240509-jdi-use-disable-ee29098d9c81
> 
> Best regards,
> -- 
> Barnabás Czémán <trabarni@...il.com>
> 

-- 
With best wishes
Dmitry

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ