Re: [patch 4/5] mm: add vm_insert_pfn helpler



Benjamin Herrenschmidt wrote:
+ vma->vm_flags |= VM_PFNMAP;


I wouldn't do that here. I would keep that to the caller (and set it
before setting the PTE along with a wmb maybe to make sure it's visible
before the PTE no ?)

Oops, good catch. You're right.

We probably don't need a barrier because we take the ptl lock
around setting the pte, and the only other readers who care should
be ones that also take the same ptl lock.

--
SUSE Labs, Novell Inc.
Send instant messages to your online friends http://au.messenger.yahoo.com -
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/



Relevant Pages

  • Re: [Patch 3/3] prepopulate/cache cleared pages
    ... to signal "this pte can be flipped in from now on", which bit would automatically be cleared if mprotector munmapis called over that range. ... interface that guarantees an architecture cannot free the page table ... Is it coming from brkfrom the allocator? ... Send instant messages to your online friends http://au.messenger.yahoo.com - ...
    (Linux-Kernel)
  • Re: [3/3 PATCH] Kprobes: User space probes support- single stepping out-of-line
    ... a pointer to a pte is a good idea to be exporting. ... other standard APIs can't be used. ... in an individual patch to add your required API to mm/. ... Send instant messages to your online friends http://au.messenger.yahoo.com ...
    (Linux-Kernel)
  • Re: [3/3 PATCH] Kprobes: User space probes support- single stepping out-of-line
    ... Andrew Morton wrote: ... * This routines get the pte of the page containing the specified address. ... other standard APIs can't be used. ... Send instant messages to your online friends http://au.messenger.yahoo.com - ...
    (Linux-Kernel)
  • Re: [RFC PATCH 30/35] Add generic_page_range() function
    ... function to every pte in a given virtual address range in a given mm ... to ensure that pagetables have been allocated ... I think you confuse our terminology: ... Send instant messages to your online friends http://au.messenger.yahoo.com - ...
    (Linux-Kernel)
  • Re: [patch 2.6.13-rc4] fix get_user_pages bug
    ... >marked the PTE dirty (and yes, part of testing this would be to verify ... write on a readonly pte, and that is where your problem is introduced. ... Send instant messages to your online friends http://au.messenger.yahoo.com ... send the line "unsubscribe linux-kernel" in ...
    (Linux-Kernel)