Re: [PATCH] mlx5: ensure 0 is returned when vport is zero

David Miller
2017-08-18T23:29:22Z

From: Colin King <colin.king-Z7WLFzj8eWMS+FvcfC7Uqw@public.gmane.org>
Date: Fri, 18 Aug 2017 14:49:25 +0100

> From: Colin Ian King <colin.king-Z7WLFzj8eWMS+FvcfC7Uqw@public.gmane.org>
>
> Currently, if vport is zero then then an uninialized return status
> in err is returned. Since the only return status at the end of the
> function esw_add_uc_addr is zero for the current set of return paths
> we may as well just return 0 rather than err to fix this issue.
>
> Detected by CoverityScan, CID#1452698 ("Uninitialized scalar variable")
>
> Fixes: eeb66cdb6826 ("net/mlx5: Separate between E-Switch and MPFS")
> Signed-off-by: Colin Ian King <colin.king-Z7WLFzj8eWMS+FvcfC7Uqw@public.gmane.org>

Applied to net-next, thanks.