lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date:   Wed, 26 Apr 2023 09:50:18 +0300
From:   Leon Romanovsky <leon@...nel.org>
To:     Tony Nguyen <anthony.l.nguyen@...el.com>
Cc:     davem@...emloft.net, kuba@...nel.org, pabeni@...hat.com,
        edumazet@...gle.com, netdev@...r.kernel.org,
        Ahmed Zaki <ahmed.zaki@...el.com>,
        Rafal Romanowski <rafal.romanowski@...el.com>
Subject: Re: [PATCH net 3/3] iavf: send VLAN offloading caps once after VFR

On Tue, Apr 25, 2023 at 10:01:27AM -0700, Tony Nguyen wrote:
> From: Ahmed Zaki <ahmed.zaki@...el.com>
> 
> When the user disables rxvlan offloading and then changes the number of
> channels, all VLAN ports are unable to receive traffic.
> 
> Changing the number of channels triggers a VFR reset. During re-init, when
> VIRTCHNL_OP_GET_OFFLOAD_VLAN_V2_CAPS is received, we do:
> 1 - set the IAVF_FLAG_SETUP_NETDEV_FEATURES flag
> 2 - call
>     iavf_set_vlan_offload_features(adapter, 0, netdev->features);
> 
> The second step sends to the PF the __default__ features, in this case
> aq_required |= IAVF_FLAG_AQ_ENABLE_CTAG_VLAN_STRIPPING
> 
> While the first step forces the watchdog task to call
> netdev_update_features() ->  iavf_set_features() ->
> iavf_set_vlan_offload_features(adapter, netdev->features, features).
> Since the user disabled the "rxvlan", this sets:
> aq_required |= IAVF_FLAG_AQ_DISABLE_CTAG_VLAN_STRIPPING
> 
> When we start processing the AQ commands, both flags are enabled. Since we
> process DISABLE_XTAG first then ENABLE_XTAG, this results in the PF
> enabling the rxvlan offload. This breaks all communications on the VLAN
> net devices.
> 
> Fix by removing the call to iavf_set_vlan_offload_features() (second
> step). Calling netdev_update_features() from watchdog task is enough for
> both init and reset paths.
> 
> Fixes: 7598f4b40bd6 ("iavf: Move netdev_update_features() into watchdog task")
> Signed-off-by: Ahmed Zaki <ahmed.zaki@...el.com>
> Tested-by: Rafal Romanowski <rafal.romanowski@...el.com>
> Signed-off-by: Tony Nguyen <anthony.l.nguyen@...el.com>
> ---
>  drivers/net/ethernet/intel/iavf/iavf_virtchnl.c | 5 -----
>  1 file changed, 5 deletions(-)
> 

Thanks,
Reviewed-by: Leon Romanovsky <leonro@...dia.com>

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ