summaryrefslogtreecommitdiffstats
path: root/drivers/net/ethernet/mellanox/mlx5/core/eq.c
diff options
context:
space:
mode:
authorEyal Davidovich2018-12-10 22:15:12 +0100
committerSaeed Mahameed2018-12-10 23:00:08 +0100
commitfd4572b3ff3ff57ca7fa612f9ea42b90afdd8bff (patch)
tree38e023b4171d93fb26e8a63c026b41dc1a51503a /drivers/net/ethernet/mellanox/mlx5/core/eq.c
parentnet/mlx5: Add support for plugged-disabled cable status in PME (diff)
downloadkernel-qcow2-linux-fd4572b3ff3ff57ca7fa612f9ea42b90afdd8bff.tar.gz
kernel-qcow2-linux-fd4572b3ff3ff57ca7fa612f9ea42b90afdd8bff.tar.xz
kernel-qcow2-linux-fd4572b3ff3ff57ca7fa612f9ea42b90afdd8bff.zip
net/mlx5: Add monitor commands layout and event data
Will be used in downstream patch to monitor counter changes by the HCA and report it to the driver by an event. The driver will update its counters cached data accordingly. Signed-off-by: Eyal Davidovich <eyald@mellanox.com> Reviewed-by: Eran Ben Elisha <eranbe@mellanox.com> Signed-off-by: Saeed Mahameed <saeedm@mellanox.com>
Diffstat (limited to 'drivers/net/ethernet/mellanox/mlx5/core/eq.c')
-rw-r--r--drivers/net/ethernet/mellanox/mlx5/core/eq.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/drivers/net/ethernet/mellanox/mlx5/core/eq.c b/drivers/net/ethernet/mellanox/mlx5/core/eq.c
index 4aa39a1fe23f..ee04aab65a9f 100644
--- a/drivers/net/ethernet/mellanox/mlx5/core/eq.c
+++ b/drivers/net/ethernet/mellanox/mlx5/core/eq.c
@@ -527,6 +527,9 @@ static u64 gather_async_events_mask(struct mlx5_core_dev *dev)
if (MLX5_CAP_MCAM_REG(dev, tracer_registers))
async_event_mask |= (1ull << MLX5_EVENT_TYPE_DEVICE_TRACER);
+ if (MLX5_CAP_GEN(dev, max_num_of_monitor_counters))
+ async_event_mask |= (1ull << MLX5_EVENT_TYPE_MONITOR_COUNTER);
+
return async_event_mask;
}