diff options
Diffstat (limited to 'net')
-rw-r--r-- | net/ipv6/addrconf.c | 12 | ||||
-rw-r--r-- | net/ipv6/route.c | 2 |
2 files changed, 13 insertions, 1 deletions
diff --git a/net/ipv6/addrconf.c b/net/ipv6/addrconf.c index 51edba5fea26..e7add61e6e39 100644 --- a/net/ipv6/addrconf.c +++ b/net/ipv6/addrconf.c | |||
@@ -169,6 +169,7 @@ struct ipv6_devconf ipv6_devconf = { | |||
169 | .accept_ra_pinfo = 1, | 169 | .accept_ra_pinfo = 1, |
170 | #ifdef CONFIG_IPV6_ROUTER_PREF | 170 | #ifdef CONFIG_IPV6_ROUTER_PREF |
171 | .accept_ra_rtr_pref = 1, | 171 | .accept_ra_rtr_pref = 1, |
172 | .rtr_probe_interval = 60 * HZ, | ||
172 | #endif | 173 | #endif |
173 | }; | 174 | }; |
174 | 175 | ||
@@ -195,6 +196,7 @@ static struct ipv6_devconf ipv6_devconf_dflt = { | |||
195 | .accept_ra_pinfo = 1, | 196 | .accept_ra_pinfo = 1, |
196 | #ifdef CONFIG_IPV6_ROUTER_PREF | 197 | #ifdef CONFIG_IPV6_ROUTER_PREF |
197 | .accept_ra_rtr_pref = 1, | 198 | .accept_ra_rtr_pref = 1, |
199 | .rtr_probe_interval = 60 * HZ, | ||
198 | #endif | 200 | #endif |
199 | }; | 201 | }; |
200 | 202 | ||
@@ -3130,6 +3132,7 @@ static void inline ipv6_store_devconf(struct ipv6_devconf *cnf, | |||
3130 | array[DEVCONF_ACCEPT_RA_PINFO] = cnf->accept_ra_pinfo; | 3132 | array[DEVCONF_ACCEPT_RA_PINFO] = cnf->accept_ra_pinfo; |
3131 | #ifdef CONFIG_IPV6_ROUTER_PREF | 3133 | #ifdef CONFIG_IPV6_ROUTER_PREF |
3132 | array[DEVCONF_ACCEPT_RA_RTR_PREF] = cnf->accept_ra_rtr_pref; | 3134 | array[DEVCONF_ACCEPT_RA_RTR_PREF] = cnf->accept_ra_rtr_pref; |
3135 | array[DEVCONF_RTR_PROBE_INTERVAL] = cnf->rtr_probe_interval; | ||
3133 | #endif | 3136 | #endif |
3134 | } | 3137 | } |
3135 | 3138 | ||
@@ -3608,6 +3611,15 @@ static struct addrconf_sysctl_table | |||
3608 | .mode = 0644, | 3611 | .mode = 0644, |
3609 | .proc_handler = &proc_dointvec, | 3612 | .proc_handler = &proc_dointvec, |
3610 | }, | 3613 | }, |
3614 | { | ||
3615 | .ctl_name = NET_IPV6_RTR_PROBE_INTERVAL, | ||
3616 | .procname = "router_probe_interval", | ||
3617 | .data = &ipv6_devconf.rtr_probe_interval, | ||
3618 | .maxlen = sizeof(int), | ||
3619 | .mode = 0644, | ||
3620 | .proc_handler = &proc_dointvec_jiffies, | ||
3621 | .strategy = &sysctl_jiffies, | ||
3622 | }, | ||
3611 | #endif | 3623 | #endif |
3612 | { | 3624 | { |
3613 | .ctl_name = 0, /* sentinel */ | 3625 | .ctl_name = 0, /* sentinel */ |
diff --git a/net/ipv6/route.c b/net/ipv6/route.c index 8ba8900c0a5f..c797b9bbb7d1 100644 --- a/net/ipv6/route.c +++ b/net/ipv6/route.c | |||
@@ -234,7 +234,7 @@ static void rt6_probe(struct rt6_info *rt) | |||
234 | return; | 234 | return; |
235 | read_lock_bh(&neigh->lock); | 235 | read_lock_bh(&neigh->lock); |
236 | if (!(neigh->nud_state & NUD_VALID) && | 236 | if (!(neigh->nud_state & NUD_VALID) && |
237 | time_after(jiffies, neigh->updated + 60 * HZ)) { | 237 | time_after(jiffies, neigh->updated + rt->rt6i_idev->cnf.rtr_probe_interval)) { |
238 | struct in6_addr mcaddr; | 238 | struct in6_addr mcaddr; |
239 | struct in6_addr *target; | 239 | struct in6_addr *target; |
240 | 240 | ||