[Linux-stm32] [PATCH] media: stm32-dcmi: fix irq = 0 case

Pavel Machek pavel at denx.de
Fri May 31 09:30:54 UTC 2019


On Fri 2019-05-31 11:18:15, Fabien Dessenne wrote:
> Manage the irq = 0 case, where we shall return an error.
> 
> Fixes: b5b5a27bee58 ("media: stm32-dcmi: return appropriate error codes during probe")
> Signed-off-by: Fabien Dessenne <fabien.dessenne at st.com>

Acked-by: Pavel Machek <pavel at ucw.cz>
Reported-by: Pavel Machek <pavel at ucw.cz>

:-).
								Pavel

> +++ b/drivers/media/platform/stm32/stm32-dcmi.c
> @@ -1702,7 +1702,7 @@ static int dcmi_probe(struct platform_device *pdev)
>  	if (irq <= 0) {
>  		if (irq != -EPROBE_DEFER)
>  			dev_err(&pdev->dev, "Could not get irq\n");
> -		return irq;
> +		return irq ? irq : -ENXIO;
>  	}
>  
>  	dcmi->res = platform_get_resource(pdev, IORESOURCE_MEM, 0);

-- 
DENX Software Engineering GmbH,      Managing Director: Wolfgang Denk
HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 181 bytes
Desc: Digital signature
URL: <http://st-md-mailman.stormreply.com/pipermail/linux-stm32/attachments/20190531/935182ec/attachment.sig>


More information about the Linux-stm32 mailing list