Re: [PATCH iwl-next v2 5/7] i40e: Consolidate checks whether given VSI is main

From: Simon Horman
Date: Thu Mar 28 2024 - 13:24:42 EST


On Wed, Mar 27, 2024 at 08:57:31AM +0100, Ivan Vecera wrote:
> In the driver code there are 3 types of checks whether given
> VSI is main or not:
> 1. vsi->type ==/!= I40E_VSI_MAIN
> 2. vsi ==/!= pf->vsi[pf->lan_vsi]
> 3. vsi->seid ==/!= pf->vsi[pf->lan_vsi]->seid
>
> All of them are equivalent and can be consolidated. Convert cases
> 2 and 3 to case 1.
>
> Reviewed-by: Michal Schmidt <mschmidt@xxxxxxxxxx>
> Signed-off-by: Ivan Vecera <ivecera@xxxxxxxxxx>

Reviewed-by: Simon Horman <horms@xxxxxxxxxx>