Re: get_user_pages() and shared memory question

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



    Timur> Hi, Is it possible for a page of memory that's been
    Timur> "grabbed" with get_user_pages() to ever be allocated to
    Timur> another process?  I'm assuming the answer is no, but I have
    Timur> a specific case I want to ask about.

Not to the best of my knowledge, although you should probably read the
code to convince yourself.

    Timur> Until 2.6.7, there was a bug in the VM where a page that
    Timur> was grabbed with get_user_pages() could be swapped out.
    Timur> Those of you familar with the OpenIB work know what I'm
    Timur> talking about.  Would that bug affect anything I'm talking
    Timur> about?

This isn't what the bug caused.  What could happen was that the
swapper could unmap a page from a process's virtual memory map before
it noticed that the page had an elevated reference count.  The page
wouldn't get swapped out, but when the process caused a page fault to
bring the virtual address back, it would get a different piece of
physical memory.

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

[Index of Archives]     [Kernel Newbies]     [Netfilter]     [Bugtraq]     [Photo]     [Stuff]     [Gimp]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Video 4 Linux]     [Linux for the blind]     [Linux Resources]
  Powered by Linux