[Intel-wired-lan] [next PATCH S86 V3 4/8] i40e: refactor promisc_changed in i40e_sync_vsi_filters

Bowers, AndrewX andrewx.bowers at intel.com
Tue Feb 6 22:35:27 UTC 2018


> -----Original Message-----
> From: Intel-wired-lan [mailto:intel-wired-lan-bounces at osuosl.org] On
> Behalf Of Alice Michael
> Sent: Monday, February 5, 2018 3:11 AM
> To: Michael, Alice <alice.michael at intel.com>; intel-wired-
> lan at lists.osuosl.org
> Subject: [Intel-wired-lan] [next PATCH S86 V3 4/8] i40e: refactor
> promisc_changed in i40e_sync_vsi_filters
> 
> From: Alan Brady <alan.brady at intel.com>
> 
> This code here is quite complex and easy to screw up.  Let's see if we can't
> improve the readability and maintainability a bit.  This refactors out
> promisc_changed into two variables 'old_overflow' and 'new_overflow'
> which makes it a bit clearer when we're concerned about when and how
> overflow promiscuous is changed.  This also makes so that we no longer need
> to pass a boolean pointer to i40e_aqc_add_filters.  Instead we can simply
> check if we changed the overflow promiscuous flag since the function start.
> 
> Signed-off-by: Alan Brady <alan.brady at intel.com>
> ---
>  drivers/net/ethernet/intel/i40e/i40e_main.c | 42 ++++++++++++++----------
> -----
>  1 file changed, 20 insertions(+), 22 deletions(-)

Tested-by: Andrew Bowers <andrewx.bowers at intel.com>




More information about the Intel-wired-lan mailing list