summaryrefslogtreecommitdiff
path: root/drivers/net/ethernet/mellanox/mlxsw/spectrum_router.h
diff options
context:
space:
mode:
authorArkadi Sharshevsky <arkadis@mellanox.com>2017-09-25 10:32:28 +0200
committerDavid S. Miller <davem@davemloft.net>2017-09-26 20:04:35 -0700
commita5390278a5eb573b76d2d28ce576b6b62c2200be (patch)
treedee638cbb6e5232797534d2237533ee05371900f /drivers/net/ethernet/mellanox/mlxsw/spectrum_router.h
parentf4de25fb530c936af7c3d9a158a7dde86adb2848 (diff)
mlxsw: spectrum: Add support for setting counters on nexthops
Add support for setting counters on nexthops based on dpipe's adjacency table counter status. This patch also adds the ability for getting the counter value, which will be used by the dpipe adjacency table dump implementation in the next patches. Signed-off-by: Arkadi Sharshevsky <arkadis@mellanox.com> Signed-off-by: Jiri Pirko <jiri@mellanox.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/ethernet/mellanox/mlxsw/spectrum_router.h')
-rw-r--r--drivers/net/ethernet/mellanox/mlxsw/spectrum_router.h2
1 files changed, 2 insertions, 0 deletions
diff --git a/drivers/net/ethernet/mellanox/mlxsw/spectrum_router.h b/drivers/net/ethernet/mellanox/mlxsw/spectrum_router.h
index d6951d516cf4..a6e86590939f 100644
--- a/drivers/net/ethernet/mellanox/mlxsw/spectrum_router.h
+++ b/drivers/net/ethernet/mellanox/mlxsw/spectrum_router.h
@@ -120,5 +120,7 @@ bool mlxsw_sp_nexthop_group_has_ipip(struct mlxsw_sp_nexthop *nh);
#define mlxsw_sp_nexthop_for_each(nh, router) \
for (nh = mlxsw_sp_nexthop_next(router, NULL); nh; \
nh = mlxsw_sp_nexthop_next(router, nh))
+int mlxsw_sp_nexthop_counter_get(struct mlxsw_sp *mlxsw_sp,
+ struct mlxsw_sp_nexthop *nh, u64 *p_counter);
#endif /* _MLXSW_ROUTER_H_*/