> Currently to RX jumbo packets fails for NICs not supporting scatter.
> Scatter is not strictly needed for jumbo support on RX. This change fixes
> the issue by only enabling scatter for NICs supporting it. Add a quirk for
> "igb" while the PMD is fixed to advertise scatter.
> 

Thanks for the v2 Pablo.

Adding Eelco and Kevin as they had some comments on the v1.

FYI I'm investigating on the DPDK side to see how/when the flag should be set 
and used for igb and ixgbe as well as other drivers.

https://dpdk.org/ml/archives/dev/2018-April/097056.html

> Reported-by: Louis Peens <louis.pe...@netronome.com>
> Signed-off-by: Pablo Cascón <pablo.cas...@netronome.com>
> Reviewed-by: Simon Horman <simon.hor...@netronome.com>
> ---
>  lib/netdev-dpdk.c | 10 +++++++++-
>  1 file changed, 9 insertions(+), 1 deletion(-)
> 
> diff --git a/lib/netdev-dpdk.c b/lib/netdev-dpdk.c index ee39cbe..8f6a0a3
> 100644
> --- a/lib/netdev-dpdk.c
> +++ b/lib/netdev-dpdk.c
> @@ -694,11 +694,19 @@ dpdk_eth_dev_queue_setup(struct netdev_dpdk *dev,
> int n_rxq, int n_txq)
>      int diag = 0;
>      int i;
>      struct rte_eth_conf conf = port_conf;
> +    struct rte_eth_dev_info info;
> 
>      /* For some NICs (e.g. Niantic), scatter_rx mode needs to be
> explicitly
>       * enabled. */
>      if (dev->mtu > ETHER_MTU) {
> -        conf.rxmode.enable_scatter = 1;
> +        rte_eth_dev_info_get(dev->port_id, &info);
> +        if (info.rx_offload_capa & DEV_RX_OFFLOAD_SCATTER) {
> +            conf.rxmode.enable_scatter = 1;
> +        } else if (!strcmp(info.driver_name, "igb")) {
> +            /* Quirk: as of DPDK 17.11.1 igb's PMD requires explicitly
> +               enabling scatter but fails to advertise it. */

I'm not sure this is acceptable. I'm worried it sets a precedent for code for 
specific devices and could lead to further instances of this in the future.

It could be argued the scatter approach up to now was specific to Niantic but 
it also worked for igb and i40e. I40e devices don’t require scatter but can 
handle it without issue if it is set.

In the past this type of solution has been rejected as the preferred approach 
was to keep netdev-dpdk code generic as possible.

That’s why I suggest deferring the patch in OVS until the required changes are 
made in DPDK to satisfy all cases. 17.11.2 is targeted for May 19th. We could 
have a solution in place for then.

I'm not trying to obstruct this but these cases do arise so interested to hear 
what others think?

Ian

> +            conf.rxmode.enable_scatter = 1;
> +        }
>      }
> 
>      conf.rxmode.hw_ip_checksum = (dev->hw_ol_features &
> --
> 2.7.4
> 
> _______________________________________________
> dev mailing list
> d...@openvswitch.org
> https://mail.openvswitch.org/mailman/listinfo/ovs-dev
_______________________________________________
dev mailing list
d...@openvswitch.org
https://mail.openvswitch.org/mailman/listinfo/ovs-dev

Reply via email to