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]
Date: Fri, 5 Jan 2024 20:31:55 +0000
From: Matthew Brost <matthew.brost@...el.com>
To: Dan Carpenter <dan.carpenter@...aro.org>
CC: Himal Prasad Ghimiray <himal.prasad.ghimiray@...el.com>, Matt Roper
	<matthew.d.roper@...el.com>, Thomas Hellström
	<thomas.hellstrom@...ux.intel.com>, <kernel-janitors@...r.kernel.org>, "Lucas
 De Marchi" <lucas.demarchi@...el.com>, Oded Gabbay <ogabbay@...nel.org>,
	<linux-kernel@...r.kernel.org>, Maxime Ripard <mripard@...nel.org>,
	<dri-devel@...ts.freedesktop.org>, Thomas Zimmermann <tzimmermann@...e.de>,
	Rodrigo Vivi <rodrigo.vivi@...el.com>, <intel-xe@...ts.freedesktop.org>
Subject: Re: [PATCH] drm/xe/device: clean up on error in probe()

On Fri, Jan 05, 2024 at 03:22:23PM +0300, Dan Carpenter wrote:
> This error path should clean up before returning.
> 
> Smatch detected this bug:
>   drivers/gpu/drm/xe/xe_device.c:487 xe_device_probe() warn: missing unwind goto?
> 
> Fixes: 4cb12b71923b ("drm/xe/xe2: Determine bios enablement for flat ccs on igfx")
> Signed-off-by: Dan Carpenter <dan.carpenter@...aro.org>

Reviewed-by: Matthew Brost <matthew.brost@...el.com>

> ---
> Speeking of static analysis, someone should probably run Sparse on this
> driver.  There are some missing annotations.
> 
> drivers/gpu/drm/xe/xe_mmio.h:65:72: warning: incorrect type in argument 1 (different address spaces)
> drivers/gpu/drm/xe/xe_mmio.h:65:72:    expected void const volatile [noderef] __iomem *addr
> drivers/gpu/drm/xe/xe_mmio.h:65:72:    got void *
> 
>  drivers/gpu/drm/xe/xe_device.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/drivers/gpu/drm/xe/xe_device.c b/drivers/gpu/drm/xe/xe_device.c
> index d9ae77fe7382..b8d8da546670 100644
> --- a/drivers/gpu/drm/xe/xe_device.c
> +++ b/drivers/gpu/drm/xe/xe_device.c
> @@ -484,7 +484,7 @@ int xe_device_probe(struct xe_device *xe)
>  
>  	err = xe_device_set_has_flat_ccs(xe);
>  	if (err)
> -		return err;
> +		goto err_irq_shutdown;
>  
>  	err = xe_mmio_probe_vram(xe);
>  	if (err)
> -- 
> 2.42.0
> 

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ