Subject: Re: [net 4/4] i40e: fix call of ndo_dflt_bridge_getlink()

From: Greg <[email-masked]>
Date: Thu, 27 Oct 2016 15:13:39 -0700

On Thu, 2016-10-27 at 14:27 -0700, Jeff Kirsher wrote:
> From: Huaibin Wang <[email-masked]>
> 
> Order of arguments is wrong.
> The wrong code has been introduced by commit 7d4f8d871ab1, but is compiled
> only since commit 9df70b66418e.
> 
> Note that this may break netlink dumps.
> 
> Fixes: 9df70b66418e ("i40e: Remove incorrect #ifdef's")
> Fixes: 7d4f8d871ab1 ("switchdev; add VLAN support for port's bridge_getlink")
> CC: Carolyn Wyborny <[email-masked]>
> Signed-off-by: Huaibin Wang <[email-masked]>
> Signed-off-by: Nicolas Dichtel <[email-masked]>
> Tested-by: Andrew Bowers <[email-masked]>
> Signed-off-by: Jeff Kirsher <[email-masked]>
> ---
>  drivers/net/ethernet/intel/i40e/i40e_main.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/drivers/net/ethernet/intel/i40e/i40e_main.c b/drivers/net/ethernet/intel/i40e/i40e_main.c
> index 6abc130..31c97e3 100644
> --- a/drivers/net/ethernet/intel/i40e/i40e_main.c
> +++ b/drivers/net/ethernet/intel/i40e/i40e_main.c
> @@ -9034,7 +9034,7 @@ static int i40e_ndo_bridge_getlink(struct sk_buff *skb, u32 pid, u32 seq,
>  		return 0;
>  
>  	return ndo_dflt_bridge_getlink(skb, pid, seq, dev, veb->bridge_mode,
> -				       nlflags, 0, 0, filter_mask, NULL);
> +				       0, 0, nlflags, filter_mask, NULL);

Yikes!  And NDO function with 10 parameters?  No wonder they get mixed
up.

- Greg

>  }
>  
>  /* Hardware supports L4 tunnel length of 128B (=2^7) which includes