net: Fix devinet_sysctl_forward
authorEric W. Biederman <ebiederm@xmission.com>
Wed, 13 May 2009 16:59:21 +0000 (16:59 +0000)
committerDavid S. Miller <davem@davemloft.net>
Tue, 19 May 2009 05:15:58 +0000 (22:15 -0700)
sysctls are unregistered with the rntl_lock held making
it unsafe to unconditionally grab the the rtnl_lock.  Instead
we need to call rtnl_trylock and restart the system call
if we can not grab it.  Otherwise we could deadlock at unregistration
time.

Signed-off-by: Eric W. Biederman <ebiederm@aristanetworks.com>
Signed-off-by: David S. Miller <davem@davemloft.net>

No differences found