Re: bugfix in copy_mount_options()?

From: Tigran Aivazian (tigran@veritas.com)
Date: Fri May 05 2000 - 01:54:26 EST


On Fri, 5 May 2000, Tigran Aivazian wrote:
> On Thu, 4 May 2000 kernel@kvack.org wrote:
> > > It would seem that the callers of find_vma() are supposed to
> > > down(&mm->mmap_sem) but copy_mount_options() does not do so and the
> > > obvious attempt to make it do so results in a deadlock. Any ideas on the
> > > reason how can copy_mount_options() safely call find_vma() without being
> > > protected by mmap_sem semaphore?
> >
> > I presume you did an up on mmap_sem before the copy_from_user.
>
> yes, I did.

No, I did not... I did up at the very end - Ah, so that is where the
deadlock is coming from... Thank you!

Ok, so now we have two potential candidates for submission to Linus:

a) your patch, assuming those checks are indeed NOT needed

or

b) my new (now working!) patch protecting call to find_vma() by mmap_sem
if someone proves that the extra checks are needed.

Regards,
Tigran

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



This archive was generated by hypermail 2b29 : Sun May 07 2000 - 21:00:16 EST