mlxsw: spectrum_router: Add helpers for nexthop access
authorArkadi Sharshevsky <arkadis@mellanox.com>
Mon, 25 Sep 2017 08:32:25 +0000 (10:32 +0200)
committerDavid S. Miller <davem@davemloft.net>
Wed, 27 Sep 2017 03:04:35 +0000 (20:04 -0700)
commitc556cd28930661f337d7989fe74ac31871fd3888
tree27b2ca9268fd19e8edda46a70ac6834c24097e61
parentec2437f42b44edc84054feb943d49e8030154c38
mlxsw: spectrum_router: Add helpers for nexthop access

This is done as a preparation before introducing the ability to dump the
adjacency table via dpipe, and to count the table size. The current table
implementation avoids tunnel entries, thus a helper for checking if
the nexthop group contains tunnel entries is also provided. The mlxsw's
nexthop representative struct stays private to the router module.

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>
drivers/net/ethernet/mellanox/mlxsw/spectrum_router.c
drivers/net/ethernet/mellanox/mlxsw/spectrum_router.h