Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
L
linux
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
nexedi
linux
Commits
fdd2f9fb
Commit
fdd2f9fb
authored
Feb 16, 2004
by
David Stevens
Committed by
David S. Miller
Feb 16, 2004
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
[IPV6]: Add sysctl to force MLD version.
parent
091a8aa4
Changes
4
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
19 additions
and
4 deletions
+19
-4
include/linux/ipv6.h
include/linux/ipv6.h
+2
-0
include/linux/sysctl.h
include/linux/sysctl.h
+2
-1
net/ipv6/addrconf.c
net/ipv6/addrconf.c
+11
-1
net/ipv6/mcast.c
net/ipv6/mcast.c
+4
-2
No files found.
include/linux/ipv6.h
View file @
fdd2f9fb
...
...
@@ -136,6 +136,7 @@ struct ipv6_devconf {
__s32
rtr_solicits
;
__s32
rtr_solicit_interval
;
__s32
rtr_solicit_delay
;
__s32
force_mld_version
;
#ifdef CONFIG_IPV6_PRIVACY
__s32
use_tempaddr
;
__s32
temp_valid_lft
;
...
...
@@ -165,6 +166,7 @@ enum {
DEVCONF_REGEN_MAX_RETRY
,
DEVCONF_MAX_DESYNC_FACTOR
,
DEVCONF_MAX_ADDRESSES
,
DEVCONF_FORCE_MLD_VERSION
,
DEVCONF_MAX
};
...
...
include/linux/sysctl.h
View file @
fdd2f9fb
...
...
@@ -424,7 +424,8 @@ enum {
NET_IPV6_TEMP_PREFERED_LFT
=
13
,
NET_IPV6_REGEN_MAX_RETRY
=
14
,
NET_IPV6_MAX_DESYNC_FACTOR
=
15
,
NET_IPV6_MAX_ADDRESSES
=
16
NET_IPV6_MAX_ADDRESSES
=
16
,
NET_IPV6_FORCE_MLD_VERSION
=
17
};
/* /proc/sys/net/ipv6/icmp */
...
...
net/ipv6/addrconf.c
View file @
fdd2f9fb
...
...
@@ -149,6 +149,7 @@ struct ipv6_devconf ipv6_devconf = {
.
accept_ra
=
1
,
.
accept_redirects
=
1
,
.
autoconf
=
1
,
.
force_mld_version
=
0
,
.
dad_transmits
=
1
,
.
rtr_solicits
=
MAX_RTR_SOLICITATIONS
,
.
rtr_solicit_interval
=
RTR_SOLICITATION_INTERVAL
,
...
...
@@ -2739,6 +2740,7 @@ static void inline ipv6_store_devconf(struct ipv6_devconf *cnf,
array
[
DEVCONF_RTR_SOLICITS
]
=
cnf
->
rtr_solicits
;
array
[
DEVCONF_RTR_SOLICIT_INTERVAL
]
=
cnf
->
rtr_solicit_interval
;
array
[
DEVCONF_RTR_SOLICIT_DELAY
]
=
cnf
->
rtr_solicit_delay
;
array
[
DEVCONF_FORCE_MLD_VERSION
]
=
cnf
->
force_mld_version
;
#ifdef CONFIG_IPV6_PRIVACY
array
[
DEVCONF_USE_TEMPADDR
]
=
cnf
->
use_tempaddr
;
array
[
DEVCONF_TEMP_VALID_LFT
]
=
cnf
->
temp_valid_lft
;
...
...
@@ -3042,7 +3044,7 @@ static int addrconf_sysctl_forward_strategy(ctl_table *table,
static
struct
addrconf_sysctl_table
{
struct
ctl_table_header
*
sysctl_header
;
ctl_table
addrconf_vars
[
1
7
];
ctl_table
addrconf_vars
[
1
8
];
ctl_table
addrconf_dev
[
2
];
ctl_table
addrconf_conf_dir
[
2
];
ctl_table
addrconf_proto_dir
[
2
];
...
...
@@ -3133,6 +3135,14 @@ static struct addrconf_sysctl_table
.
proc_handler
=
&
proc_dointvec_jiffies
,
.
strategy
=
&
sysctl_jiffies
,
},
{
.
ctl_name
=
NET_IPV6_FORCE_MLD_VERSION
,
.
procname
=
"force_mld_version"
,
.
data
=
&
ipv6_devconf
.
force_mld_version
,
.
maxlen
=
sizeof
(
int
),
.
mode
=
0644
,
.
proc_handler
=
&
proc_dointvec
,
},
#ifdef CONFIG_IPV6_PRIVACY
{
.
ctl_name
=
NET_IPV6_USE_TEMPADDR
,
...
...
net/ipv6/mcast.c
View file @
fdd2f9fb
...
...
@@ -152,8 +152,10 @@ int ip6_mc_leave_src(struct sock *sk, struct ipv6_mc_socklist *iml,
#define IGMP6_UNSOLICITED_IVAL (10*HZ)
#define MLD_QRV_DEFAULT 2
#define MLD_V1_SEEN(idev) ((idev)->mc_v1_seen && \
time_before(jiffies, (idev)->mc_v1_seen))
#define MLD_V1_SEEN(idev) (ipv6_devconf.force_mld_version == 1 || \
(idev)->cnf.force_mld_version == 1 || \
((idev)->mc_v1_seen && \
time_before(jiffies, (idev)->mc_v1_seen)))
#define MLDV2_MASK(value, nb) ((nb)>=32 ? (value) : ((1<<(nb))-1) & (value))
#define MLDV2_EXP(thresh, nbmant, nbexp, value) \
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment