lkml.org 
[lkml]   [2013]   [Mar]   [12]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
Patch in this message
/
Date
From
SubjectRe: pipe_release oops.
On Sun, 10 March 2013 23:33:18 +0000, Al Viro wrote:
> On Fri, Mar 08, 2013 at 01:26:49PM -0500, J??rn Engel wrote:
>
> > + files_cookie = async_schedule(exit_files_async, tsk);
> > exit_mm(tsk);
> >
> > if (group_dead)
> > @@ -990,7 +998,7 @@ void do_exit(long code)
> >
> > exit_sem(tsk);
> > exit_shm(tsk);
> > - exit_files(tsk);
> > + async_synchronize_cookie(files_cookie);
>
> That doesn't do what you seem to think it's doing. It does *not* wait
> for the completion of that sucker's execution - only the ones scheduled
> before it. IOW, your exit_files_async() might very well be executed
> *after* do_exit() completes and tsk gets reused.

Indeed. Maybe async_barrier() would have been a less dangerous name
in the presence of people like me. Oh well!

I have kernel/async.c on my list anyway. We've had a number of cases
where a single bad scsi device turned the "do the scanning
asynchronously" idea into a "make completely unrelated stuff
synchonously wait for a broken disk" reality.

Thanks for spotting this!

Jörn

--
The cheapest, fastest and most reliable components of a computer
system are those that aren't there.
-- Gordon Bell, DEC labratories
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
\
 
 \ /
  Last update: 2013-03-12 22:23    [W:0.158 / U:0.180 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site