Re: Way to Know When cleanup_net() Calls Are Done

2017-07-05 Thread Leon Yang
In my case, as I know the number of unshare(2) calls (say 1), I think there should be same number of net_drop_ns() calls regardless of the userns counter. So the 1th call to net_drop_ns() should be the last one. After some investigation I figure out my problem. When I was running the progr

Re: Way to Know When cleanup_net() Calls Are Done

2017-07-05 Thread Cong Wang
On Sat, Jul 1, 2017 at 10:50 PM, Leon Yang wrote: > Hi, > > I am measuring the time cost of parallel creation and destruction of > net namespaces. > > As cleanup_net() is invoked from workqueue, the exit of a net > namespace does not mean the cleanup is completed. Therefore I use > ftrace to count

Way to Know When cleanup_net() Calls Are Done

2017-07-01 Thread Leon Yang
Hi, I am measuring the time cost of parallel creation and destruction of net namespaces. As cleanup_net() is invoked from workqueue, the exit of a net namespace does not mean the cleanup is completed. Therefore I use ftrace to count the number of net_drop_ns() are called. But I found that the num