Re: [PATCH net 2/2] net: tehuti: Fix leaks in the error handling path of bdx_probe()

From: Jiri Pirko
Date: Wed Feb 28 2024 - 05:25:10 EST


Tue, Feb 27, 2024 at 09:50:56PM CET, christophe.jaillet@xxxxxxxxxx wrote:
>If an error occurs when allocating the net_device, all the one already
>allocated and registered should be released, as already done in the remove
>function.
>
>Add a new label, remove the now useless 'err_out_disable_msi' label and
>adjust the error handling path accordingly.
>
>Fixes: 1a348ccc1047 ("[NET]: Add Tehuti network driver.")
>Signed-off-by: Christophe JAILLET <christophe.jaillet@xxxxxxxxxx>
>---
>Compile tested only.


Looks okay.

Reviewed-by: Jiri Pirko <jiri@xxxxxxxxxx>