ipv6: Refactor exception functions
authorDavid Ahern <dsahern@gmail.com>
Thu, 23 May 2019 03:27:57 +0000 (20:27 -0700)
committerDavid S. Miller <davem@davemloft.net>
Fri, 24 May 2019 20:26:44 +0000 (13:26 -0700)
commitc0b220cf7d80eb8a36ae9f12cae6df4577a6814e
tree19515a336ba75f4322beff34b2caa7a4a1182a59
parent7d88d8b5570b6adba39289487138cff38f84336d
ipv6: Refactor exception functions

Before moving exception bucket from fib6_info to fib6_nh, refactor
rt6_flush_exceptions, rt6_remove_exception_rt, rt6_mtu_change_route,
and rt6_update_exception_stamp_rt. In all 3 cases, move the primary
logic into a new helper that starts with fib6_nh_. The latter 3
functions still take a fib6_info; this will be changed to fib6_nh
in the next patch.

In the case of rt6_mtu_change_route, move the fib6_metric_locked
out as a standalone check - no need to call the new function if
the fib entry has the mtu locked. Also, add fib6_info to
rt6_mtu_change_arg as a way of passing the fib entry to the new
helper.

No functional change intended. The goal here is to make the next
patch easier to review by moving existing lookup logic for each to
new helpers.

Signed-off-by: David Ahern <dsahern@gmail.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
net/ipv6/route.c