Messages in this thread | | | Date | Wed, 18 Jan 2012 22:23:44 +0400 | From | Cyrill Gorcunov <> | Subject | Re: [RFC] fs, proc: Introduce /proc/<pid>/task/<tid>/children entry v6 |
| |
On Wed, Jan 18, 2012 at 03:36:31PM +0100, Oleg Nesterov wrote: > On 01/18, Cyrill Gorcunov wrote: > > > > So Oleg, I think you meant something like below? Comment is moved down an > > list_empty over siblings remans, right? > > Yes, except the comment still looks misleading to me. > > Otherwise looks correct, but I'll try to re-check once again with > the fresh head. Although I think you should remove me from CC: after > I found the nonexistent bug ;) >
There is no way back from CC ;)
> This is minor, but "freshly created" looks very confusing to me. > What does it mean? We hold tasklist, we can't race with fork(). >
Hmm. Sure we keep a lock here, but changes might happen between reads If only I'm not missing something again.
Look which scenario I've had in mind. We have a task A and children B,C,D,E. ... Here my scenario ended and I realised that you're right. I'll update the comment.
> Yes we can miss a child, but this has nothing to do with "freshly". > Just suppose that the parent sleeps, but N children exit after we > printed their tids. Now the slow paths skips N extra children, we > miss N tasks. > > Oleg. >
Cyrill
| |