mlxsw: spectrum_router: Extract mlxsw_sp_fi_is_gateway()
authorPetr Machata <petrm@mellanox.com>
Sat, 2 Sep 2017 21:49:20 +0000 (23:49 +0200)
committerDavid S. Miller <davem@davemloft.net>
Mon, 4 Sep 2017 03:23:25 +0000 (20:23 -0700)
commit9b01451ad5fe09d95aea9cfd5b36cde574651ab4
tree401f30b8fbb8ca1514538dc170711a4bcb870e32
parent6ddb7426a7d4429c9df9dada9ebc0cc396d31cc4
mlxsw: spectrum_router: Extract mlxsw_sp_fi_is_gateway()

For IPv4 IP-in-IP offload, routes that direct traffic to IP-in-IP
devices need to be considered gateway routes as well. That involves a
bit more logic, so extract the current test to a separate function,
where the logic can be later added.

Signed-off-by: Petr Machata <petrm@mellanox.com>
Reviewed-by: Ido Schimmel <idosch@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