diff options
author | Nikolay Aleksandrov <nikolay@cumulusnetworks.com> | 2016-07-26 18:54:52 +0200 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2016-07-26 15:18:31 -0700 |
commit | 90b5ca1766ae7806a711d66df056af1290faa2c0 (patch) | |
tree | 02848b638c0a45588b7867631bd8a1e55f9440dd /net/ipv4/ipmr.c | |
parent | e3a3b626010a14fe067f163c2c43409d5afcd2a9 (diff) | |
download | linux-stable-90b5ca1766ae7806a711d66df056af1290faa2c0.tar.gz linux-stable-90b5ca1766ae7806a711d66df056af1290faa2c0.tar.bz2 linux-stable-90b5ca1766ae7806a711d66df056af1290faa2c0.zip |
net: ipmr/ip6mr: update lastuse on entry change
Currently lastuse is updated on entry creation and cache hit, but it should
also be updated on entry change. Since both on add and update the ttl array
is updated we can simply update the lastuse in ipmr_update_thresholds.
Signed-off-by: Nikolay Aleksandrov <nikolay@cumulusnetworks.com>
CC: Roopa Prabhu <roopa@cumulusnetworks.com>
CC: Donald Sharp <sharpd@cumulusnetworks.com>
CC: David S. Miller <davem@davemloft.net>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net/ipv4/ipmr.c')
-rw-r--r-- | net/ipv4/ipmr.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/net/ipv4/ipmr.c b/net/ipv4/ipmr.c index eec234161b89..26253328d227 100644 --- a/net/ipv4/ipmr.c +++ b/net/ipv4/ipmr.c @@ -722,6 +722,7 @@ static void ipmr_update_thresholds(struct mr_table *mrt, struct mfc_cache *cache cache->mfc_un.res.maxvif = vifi + 1; } } + cache->mfc_un.res.lastuse = jiffies; } static int vif_add(struct net *net, struct mr_table *mrt, @@ -1150,7 +1151,6 @@ static int ipmr_mfc_add(struct net *net, struct mr_table *mrt, c->mfc_origin = mfc->mfcc_origin.s_addr; c->mfc_mcastgrp = mfc->mfcc_mcastgrp.s_addr; c->mfc_parent = mfc->mfcc_parent; - c->mfc_un.res.lastuse = jiffies; ipmr_update_thresholds(mrt, c, mfc->mfcc_ttls); if (!mrtsock) c->mfc_flags |= MFC_STATIC; |