Re: [PATCH 4.19 37/39] Input: i8042 - fix error return code in i8042_setup_aux()

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi!

> From: Luo Meng <luomeng12@xxxxxxxxxx>
> 
> commit 855b69857830f8d918d715014f05e59a3f7491a0 upstream.
> 
> Fix to return a negative error code from the error handling case
> instead of 0 in function i8042_setup_aux(), as done elsewhere in this
> function.
> 
> Fixes: f81134163fc7 ("Input: i8042 - use platform_driver_probe")

I'd recommend not taking this. It is not known to fix
end-user-visible-bug, i8042 is normally quite fragile, and the patch
is less then month old so did not get adequate testing.

Yes, code looks cleaner after the fix. With i8042, that does not mean
much.

Best regards,
								Pavel


> --- a/drivers/input/serio/i8042.c
> +++ b/drivers/input/serio/i8042.c
> @@ -1472,7 +1472,8 @@ static int __init i8042_setup_aux(void)
>  	if (error)
>  		goto err_free_ports;
>  
> -	if (aux_enable())
> +	error = aux_enable();
> +	if (error)
>  		goto err_free_irq;
>  
>  	i8042_aux_irq_registered = true;
> 

-- 
DENX Software Engineering GmbH,      Managing Director: Wolfgang Denk
HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany

Attachment: signature.asc
Description: Digital signature


[Index of Archives]     [Linux Kernel]     [Kernel Development Newbies]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Yosemite Hiking]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux