Re: [PATCH net-next v14 08/13] rtase: Implement net_device_ops

From: Paolo Abeni
Date: Tue Dec 12 2023 - 05:09:37 EST


On Fri, 2023-12-08 at 17:47 +0800, Justin Lai wrote:
> +static netdev_features_t rtase_fix_features(struct net_device *dev,
> + netdev_features_t features)
> +{
> + netdev_features_t features_fix = features;
> +
> + if (dev->mtu > MSS_MAX)
> + features_fix &= ~NETIF_F_ALL_TSO;
> +
> + if (dev->mtu > ETH_DATA_LEN)
> + features_fix &= ~NETIF_F_ALL_TSO;

This latter condition is strictly more restrictive than the previous
one, you can drop the latter. Also could you please drop a note about
the why of it?

Cheers,

Paolo