]> www.infradead.org Git - users/jedix/linux-maple.git/commitdiff
net: iavf: reject unsupported coalescing params
authorJakub Kicinski <kuba@kernel.org>
Wed, 11 Mar 2020 22:32:57 +0000 (15:32 -0700)
committerDavid S. Miller <davem@davemloft.net>
Thu, 12 Mar 2020 18:32:36 +0000 (11:32 -0700)
Set ethtool_ops->supported_coalesce_params to let
the core reject unsupported coalescing parameters.

This driver did not previously reject unsupported parameters.

Signed-off-by: Jakub Kicinski <kuba@kernel.org>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/ethernet/intel/iavf/iavf_ethtool.c

index f807e2c7597f68f6ff3afae4a1eb5c2e14e3d26d..2c39d46b613854dd0b1237309b4e8d03463ef707 100644 (file)
@@ -996,6 +996,10 @@ static int iavf_set_rxfh(struct net_device *netdev, const u32 *indir,
 }
 
 static const struct ethtool_ops iavf_ethtool_ops = {
+       .supported_coalesce_params = ETHTOOL_COALESCE_USECS |
+                                    ETHTOOL_COALESCE_MAX_FRAMES |
+                                    ETHTOOL_COALESCE_MAX_FRAMES_IRQ |
+                                    ETHTOOL_COALESCE_USE_ADAPTIVE,
        .get_drvinfo            = iavf_get_drvinfo,
        .get_link               = ethtool_op_get_link,
        .get_ringparam          = iavf_get_ringparam,