]> git.ipfire.org Git - thirdparty/iproute2.git/commit
ip: nexthop: keep cache netlink socket open
authorNikolay Aleksandrov <nikolay@nvidia.com>
Mon, 4 Oct 2021 09:03:28 +0000 (12:03 +0300)
committerDavid Ahern <dsahern@kernel.org>
Tue, 5 Oct 2021 14:34:29 +0000 (08:34 -0600)
commitb840c620fe818a313f09891cd2ede492e928e8d4
treea9b3e64873178e9b9ca10ea15f8beaa87525cd96
parentb90174354dce29d3b699558709d851b35b0c5a22
ip: nexthop: keep cache netlink socket open

Since we use the cache netlink socket for each nexthop we can keep it open
instead of opening and closing it on every add call. The socket is opened
once, on the first add call and then reused for the rest.

Suggested-by: David Ahern <dsahern@gmail.com>
Signed-off-by: Nikolay Aleksandrov <nikolay@nvidia.com>
Signed-off-by: David Ahern <dsahern@kernel.org>
ip/ipnexthop.c