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
b325fddb
Commit
b325fddb
authored
Feb 26, 2009
by
Stephen Hemminger
Committed by
David S. Miller
Mar 03, 2009
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
ipv6: Fix sysctl unregistration deadlock
Signed-off-by:
David S. Miller
<
davem@davemloft.net
>
parent
5a5990d3
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
8 additions
and
6 deletions
+8
-6
net/ipv6/addrconf.c
net/ipv6/addrconf.c
+8
-6
No files found.
net/ipv6/addrconf.c
View file @
b325fddb
...
...
@@ -493,15 +493,17 @@ static void addrconf_forward_change(struct net *net, __s32 newf)
read_unlock
(
&
dev_base_lock
);
}
static
void
addrconf_fixup_forwarding
(
struct
ctl_table
*
table
,
int
*
p
,
int
old
)
static
int
addrconf_fixup_forwarding
(
struct
ctl_table
*
table
,
int
*
p
,
int
old
)
{
struct
net
*
net
;
net
=
(
struct
net
*
)
table
->
extra2
;
if
(
p
==
&
net
->
ipv6
.
devconf_dflt
->
forwarding
)
return
;
return
0
;
if
(
!
rtnl_trylock
())
return
-
ERESTARTSYS
;
rtnl_lock
();
if
(
p
==
&
net
->
ipv6
.
devconf_all
->
forwarding
)
{
__s32
newf
=
net
->
ipv6
.
devconf_all
->
forwarding
;
net
->
ipv6
.
devconf_dflt
->
forwarding
=
newf
;
...
...
@@ -512,6 +514,7 @@ static void addrconf_fixup_forwarding(struct ctl_table *table, int *p, int old)
if
(
*
p
)
rt6_purge_dflt_routers
(
net
);
return
1
;
}
#endif
...
...
@@ -3983,7 +3986,7 @@ int addrconf_sysctl_forward(ctl_table *ctl, int write, struct file * filp,
ret
=
proc_dointvec
(
ctl
,
write
,
filp
,
buffer
,
lenp
,
ppos
);
if
(
write
)
addrconf_fixup_forwarding
(
ctl
,
valp
,
val
);
ret
=
addrconf_fixup_forwarding
(
ctl
,
valp
,
val
);
return
ret
;
}
...
...
@@ -4019,8 +4022,7 @@ static int addrconf_sysctl_forward_strategy(ctl_table *table,
}
*
valp
=
new
;
addrconf_fixup_forwarding
(
table
,
valp
,
val
);
return
1
;
return
addrconf_fixup_forwarding
(
table
,
valp
,
val
);
}
static
struct
addrconf_sysctl_table
...
...
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