Patchwork [1/4] net/mlx4_en: Setting the NETIF_F_GRO flag back to dev->hw_features

login
register
mail settings
Submitter Yevgeny Petrilin
Date Aug. 2, 2012, 3:30 p.m.
Message ID <1343921456-19180-2-git-send-email-yevgenyp@mellanox.co.il>
Download mbox | patch
Permalink /patch/174770/
State Changes Requested
Delegated to: David Miller
Headers show

Comments

Yevgeny Petrilin - Aug. 2, 2012, 3:30 p.m.
The bug which removed it was introduced in commit c8c64cff
which added the hw_features.

Signed-off-by: Yevgeny Petrilin <yevgenyp@mellanox.co.il>
---
 drivers/net/ethernet/mellanox/mlx4/en_netdev.c |    3 ++-
 1 files changed, 2 insertions(+), 1 deletions(-)
=?ISO-8859-2?Q?Micha=B3_Miros=B3aw?= - Aug. 2, 2012, 7:36 p.m.
2012/8/2 Yevgeny Petrilin <yevgenyp@mellanox.co.il>:
> The bug which removed it was introduced in commit c8c64cff
> which added the hw_features.
[...]
> -       dev->hw_features = NETIF_F_SG | NETIF_F_IP_CSUM | NETIF_F_IPV6_CSUM;
> +       dev->hw_features = NETIF_F_SG | NETIF_F_IP_CSUM | NETIF_F_IPV6_CSUM |
> +                          NETIF_F_GRO;

Just try to realize the truth: there is no bug.

register_netdevice() is setting GSO and GRO bits for everyone.

Best Regards,
Michał Mirosław
--
To unsubscribe from this list: send the line "unsubscribe netdev" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Patch

diff --git a/drivers/net/ethernet/mellanox/mlx4/en_netdev.c b/drivers/net/ethernet/mellanox/mlx4/en_netdev.c
index edd9cb8..c031e12 100644
--- a/drivers/net/ethernet/mellanox/mlx4/en_netdev.c
+++ b/drivers/net/ethernet/mellanox/mlx4/en_netdev.c
@@ -1658,7 +1658,8 @@  int mlx4_en_init_netdev(struct mlx4_en_dev *mdev, int port,
 	/*
 	 * Set driver features
 	 */
-	dev->hw_features = NETIF_F_SG | NETIF_F_IP_CSUM | NETIF_F_IPV6_CSUM;
+	dev->hw_features = NETIF_F_SG | NETIF_F_IP_CSUM | NETIF_F_IPV6_CSUM |
+			   NETIF_F_GRO;
 	if (mdev->LSO_support)
 		dev->hw_features |= NETIF_F_TSO | NETIF_F_TSO6;