Re: [PATCH] umount after bad chdir

From: raven
Date: Wed Apr 14 2004 - 07:30:50 EST


On Wed, 14 Apr 2004 viro@xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx wrote:

> On Wed, Apr 14, 2004 at 08:12:33PM +0800, raven@xxxxxxxxxx wrote:
> > On Wed, 14 Apr 2004, Hugh Dickins wrote:
> >
> > > After chdir (or chroot) to non-existent directory on 2.6.5-mm5, you
> > > can no longer unmount filesystem holding working directory (or root).
> > >
> >
> > Of course.
> >
> > Excellent. Thanks very much.
>
> Mind you, chdir() patch in -mm is broken in a lot of other ways - e.g.
> it assumes that another thread sharing ->fs with us won't call chdir()
> in the wrong moment...

Thanks for your interest Al.

I see your point (I think).

If I understand you correctly (please explain if I don't) I need to lock
the ->fs struct.
But then I can't use the set_fs_xxx calls.

Do you have any suggestions on how I should do this?

Ian

-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/