Patchwork [net] net/mlx_en: Timestamping is not supported in slave mode

login
register
mail settings
Submitter Amir Vadai
Date June 20, 2013, 11:58 a.m.
Message ID <1371729490-10491-1-git-send-email-amirv@mellanox.com>
Download mbox | patch
Permalink /patch/252888/
State Accepted
Delegated to: David Miller
Headers show

Comments

Amir Vadai - June 20, 2013, 11:58 a.m.
Old hypervisors don't mask out timestamp capability for slave. Till slave
support will be added, need to disable capability by slave.

Signed-off-by: Amir Vadai <amirv@mellanox.com>
---
 drivers/net/ethernet/mellanox/mlx4/main.c | 3 +++
 1 file changed, 3 insertions(+)
David Miller - June 24, 2013, 7:03 a.m.
From: Amir Vadai <amirv@mellanox.com>
Date: Thu, 20 Jun 2013 14:58:10 +0300

> Old hypervisors don't mask out timestamp capability for slave. Till slave
> support will be added, need to disable capability by slave.
> 
> Signed-off-by: Amir Vadai <amirv@mellanox.com>

Applied.
--
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/main.c b/drivers/net/ethernet/mellanox/mlx4/main.c
index 2f4a260..8a43499 100644
--- a/drivers/net/ethernet/mellanox/mlx4/main.c
+++ b/drivers/net/ethernet/mellanox/mlx4/main.c
@@ -632,6 +632,9 @@  static int mlx4_slave_cap(struct mlx4_dev *dev)
 		dev->caps.cqe_size   = 32;
 	}
 
+	dev->caps.flags2 &= ~MLX4_DEV_CAP_FLAG2_TS;
+	mlx4_warn(dev, "Timestamping is not supported in slave mode.\n");
+
 	slave_adjust_steering_mode(dev, &dev_cap, &hca_param);
 
 	return 0;