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] [day] [month] [year] [list]
Message-ID: <65ce7efd-a7ae-5a47-9915-94964906e28b@ideasonboard.com>
Date:   Wed, 27 Jan 2021 16:23:24 +0200
From:   Tomi Valkeinen <tomi.valkeinen@...asonboard.com>
To:     menglong8.dong@...il.com, sebastian.reichel@...labora.com
Cc:     airlied@...ux.ie, daniel@...ll.ch,
        laurent.pinchart@...asonboard.com, dri-devel@...ts.freedesktop.org,
        linux-kernel@...r.kernel.org,
        Menglong Dong <dong.menglong@....com.cn>
Subject: Re: [PATCH v2] drm/omap: dsi: fix unreachable code in
 dsi_vc_send_short()

On 27/01/2021 03:51, menglong8.dong@...il.com wrote:
> From: Menglong Dong <dong.menglong@....com.cn>
> 
> The 'r' in dsi_vc_send_short() is of type 'unsigned int', so the
> 'r < 0' can't be true.
> 
> Fix this by introducing a 'err' of type 'int' insteaded.
> 
> Fixes: 1ed6253856cb ("drm/omap: dsi: switch dsi_vc_send_long/short to mipi_dsi_msg")
> 
> Signed-off-by: Menglong Dong <dong.menglong@....com.cn>
> Reviewed-by: Sebastian Reichel <sebastian.reichel@...labora.com>
> ---
> v2:
> - remove word wrap in 'Fixes' tag
> ---
>  drivers/gpu/drm/omapdrm/dss/dsi.c | 7 ++++---
>  1 file changed, 4 insertions(+), 3 deletions(-)
> 
> diff --git a/drivers/gpu/drm/omapdrm/dss/dsi.c b/drivers/gpu/drm/omapdrm/dss/dsi.c
> index 8e11612f5fe1..febcc87ddfe1 100644
> --- a/drivers/gpu/drm/omapdrm/dss/dsi.c
> +++ b/drivers/gpu/drm/omapdrm/dss/dsi.c
> @@ -2149,11 +2149,12 @@ static int dsi_vc_send_short(struct dsi_data *dsi, int vc,
>  			     const struct mipi_dsi_msg *msg)
>  {
>  	struct mipi_dsi_packet pkt;
> +	int err;
>  	u32 r;
>  
> -	r = mipi_dsi_create_packet(&pkt, msg);
> -	if (r < 0)
> -		return r;
> +	err = mipi_dsi_create_packet(&pkt, msg);
> +	if (err)
> +		return err;
>  
>  	WARN_ON(!dsi_bus_is_locked(dsi));
>  

Thanks! I'll apply to drm-misc-next.

 Tomi

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ