[PATCH] net: add rtnl assertion to linkwatch_run_queue

Subsystems: networking [general], the rest

STALE5918d

2 messages, 2 authors, 2010-05-29 · open the first message on its own page

[PATCH] net: add rtnl assertion to linkwatch_run_queue

From: Denis Kirjanov <hidden>
Date: 2010-05-27 05:51:12

Add RTNL assertion to linkwatch_run_queue since function 
must be called with semaphore held

Signed-off-by: Denis Kirjanov <dkirjanov@kernel.org>
---
net/core/link_watch.c |    1 +
 1 files changed, 1 insertions(+), 0 deletions(-)
diff --git a/net/core/link_watch.c b/net/core/link_watch.c
index bdbce2f..e6d06c0 100644
--- a/net/core/link_watch.c
+++ b/net/core/link_watch.c
@@ -220,6 +220,7 @@ void linkwatch_forget_dev(struct net_device *dev)
 /* Must be called with the rtnl semaphore held */
 void linkwatch_run_queue(void)
 {
+	ASSERT_RTNL();
 	__linkwatch_run_queue(0);
 }
 

Re: [PATCH] net: add rtnl assertion to linkwatch_run_queue

From: David Miller <davem@davemloft.net>
Date: 2010-05-29 07:01:09

From: Denis Kirjanov <redacted>
Date: Thu, 27 May 2010 05:51:00 +0000
Add RTNL assertion to linkwatch_run_queue since function 
must be called with semaphore held

Signed-off-by: Denis Kirjanov <dkirjanov@kernel.org>
This function is exported purely for netdev_wait_allrefs()'s sake
and for no other purpose.

In fact, I'd say this is entirely a private functional interface
specifically built for generic network interface tear-down.

If you are trying to use this function in another context, that's
something you need to discuss with us first before we start peppering
it with various assertions.

I am not applying this patch.
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help