Linux-kernel mailing list archive 1999-41,: Re: locking question: do_mmap(), do_munmap()

# Re: locking question: do_mmap(), do_munmap()

Stephen C. Tweedie (sct@redhat.com)
Mon, 11 Oct 1999 21:15:37 +0100 (BST)

- Messages sorted by: [ date ][ thread ][ subject ][ author ]
- Next message: nathan.zook@amd.com: "RE: mmapping of page 0xfffff000 impossible ?"
- Previous message: Stephen C. Tweedie: "Re: locking question: do_mmap(), do_munmap()"

Hi,

On Mon, 11 Oct 1999 20:02:40 +0200, Manfred Spraul
<manfreds@colorfullife.com> said:

> What about something like a rw-semaphore which protects the vma list:
> vma-list modifiers [ie merge_segments(), insert_vm_struct() and
> do_munmap()] grab it exclusive, swapper grabs it "shared, starve
> exclusive".
> All other vma-list readers are protected by mm->mmap_sem.

> This should not dead-lock, and no changes are required in
> vm_ops-> swapout().

The swapout method will need to drop the spinlock. We need to preserve
the vma over the call into the swapout method, and the method will need
to be able to block.

--Stephen

-
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/

- Next message: nathan.zook@amd.com: "RE: mmapping of page 0xfffff000 impossible ?"
- Previous message: Stephen C. Tweedie: "Re: locking question: do_mmap(), do_munmap()"