diff options
author | Ryan Stone <rstone@FreeBSD.org> | 2018-01-23 03:15:44 +0000 |
---|---|---|
committer | Ryan Stone <rstone@FreeBSD.org> | 2018-01-23 03:15:44 +0000 |
commit | bc3d87fd596415ba7d00b6a47ccec0286d63a6a6 (patch) | |
tree | 6ae13e4e5d68ffba3c4931abfcb17f73eda25307 /sys/net/route.c | |
parent | fc21c53f63e8f45a5fec4f7dceb7995cc2fe27ab (diff) | |
download | src-test2-bc3d87fd596415ba7d00b6a47ccec0286d63a6a6.tar.gz src-test2-bc3d87fd596415ba7d00b6a47ccec0286d63a6a6.zip |
Notes
Diffstat (limited to 'sys/net/route.c')
-rw-r--r-- | sys/net/route.c | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/sys/net/route.c b/sys/net/route.c index 320a0a1b7d36..db1039094477 100644 --- a/sys/net/route.c +++ b/sys/net/route.c @@ -1733,6 +1733,8 @@ rtrequest1_fib_change(struct rib_head *rnh, struct rt_addrinfo *info, int family, mtu; struct if_mtuinfo ifmtu; + RIB_WLOCK_ASSERT(rnh); + rt = (struct rtentry *)rnh->rnh_lookup(info->rti_info[RTAX_DST], info->rti_info[RTAX_NETMASK], &rnh->head); @@ -1823,6 +1825,13 @@ rtrequest1_fib_change(struct rib_head *rnh, struct rt_addrinfo *info, } } + /* + * This route change may have modified the route's gateway. In that + * case, any inpcbs that have cached this route need to invalidate their + * llentry cache. + */ + rnh->rnh_gen++; + if (ret_nrt) { *ret_nrt = rt; RT_ADDREF(rt); |