Re: [PATCH V5 0/7] Allow user to request memory to be locked on page fault

2015-07-29 Thread Vlastimil Babka
On 07/29/2015 12:45 PM, Michal Hocko wrote: In a much less likely corner case, it is not possible in the current setup to request all current VMAs be VM_LOCKONFAULT and all future be VM_LOCKED. Vlastimil has already pointed that out. MCL_FUTURE doesn't clear MCL_CURRENT. I was quite

Re: [PATCH V5 0/7] Allow user to request memory to be locked on page fault

2015-07-29 Thread Michal Hocko
On Tue 28-07-15 09:49:42, Eric B Munson wrote: On Tue, 28 Jul 2015, Michal Hocko wrote: [I am sorry but I didn't get to this sooner.] On Mon 27-07-15 10:54:09, Eric B Munson wrote: Now that VM_LOCKONFAULT is a modifier to VM_LOCKED and cannot be specified independentally, it might

Re: [PATCH V5 0/7] Allow user to request memory to be locked on page fault

2015-07-28 Thread Eric B Munson
On Tue, 28 Jul 2015, Michal Hocko wrote: [I am sorry but I didn't get to this sooner.] On Mon 27-07-15 10:54:09, Eric B Munson wrote: Now that VM_LOCKONFAULT is a modifier to VM_LOCKED and cannot be specified independentally, it might make more sense to mirror that relationship to

Re: [PATCH V5 0/7] Allow user to request memory to be locked on page fault

2015-07-28 Thread Vlastimil Babka
On 07/28/2015 01:17 PM, Michal Hocko wrote: [I am sorry but I didn't get to this sooner.] On Mon 27-07-15 10:54:09, Eric B Munson wrote: Now that VM_LOCKONFAULT is a modifier to VM_LOCKED and cannot be specified independentally, it might make more sense to mirror that relationship to

Re: [PATCH V5 0/7] Allow user to request memory to be locked on page fault

2015-07-28 Thread Eric B Munson
On Tue, 28 Jul 2015, Vlastimil Babka wrote: On 07/28/2015 03:49 PM, Eric B Munson wrote: On Tue, 28 Jul 2015, Michal Hocko wrote: [...] The only remaining question I have is should we have 2 new mlockall flags so that the caller can explicitly set VM_LOCKONFAULT in the mm-def_flags vs

Re: [PATCH V5 0/7] Allow user to request memory to be locked on page fault

2015-07-28 Thread Michal Hocko
[I am sorry but I didn't get to this sooner.] On Mon 27-07-15 10:54:09, Eric B Munson wrote: Now that VM_LOCKONFAULT is a modifier to VM_LOCKED and cannot be specified independentally, it might make more sense to mirror that relationship to userspace. Which would lead to soemthing like the

Re: [PATCH V5 0/7] Allow user to request memory to be locked on page fault

2015-07-27 Thread Eric B Munson
On Mon, 27 Jul 2015, Vlastimil Babka wrote: On 07/24/2015 11:28 PM, Eric B Munson wrote: ... Changes from V4: Drop all architectures for new sys call entries except x86[_64] and MIPS Drop munlock2 and munlockall2 Make VM_LOCKONFAULT a modifier to VM_LOCKED only to simplify book keeping

Re: [PATCH V5 0/7] Allow user to request memory to be locked on page fault

2015-07-27 Thread Eric B Munson
On Mon, 27 Jul 2015, Vlastimil Babka wrote: On 07/27/2015 03:35 PM, Eric B Munson wrote: On Mon, 27 Jul 2015, Vlastimil Babka wrote: On 07/24/2015 11:28 PM, Eric B Munson wrote: ... Changes from V4: Drop all architectures for new sys call entries except x86[_64] and MIPS Drop

Re: [PATCH V5 0/7] Allow user to request memory to be locked on page fault

2015-07-27 Thread Vlastimil Babka
On 07/27/2015 04:54 PM, Eric B Munson wrote: On Mon, 27 Jul 2015, Vlastimil Babka wrote: We do actually have an MCL_LOCKED, we just call it MCL_CURRENT. Would you prefer that I match the name in mlock2() (add MLOCK_CURRENT instead)? Hm it's similar but not exactly the same, because

Re: [PATCH V5 0/7] Allow user to request memory to be locked on page fault

2015-07-27 Thread Vlastimil Babka
On 07/27/2015 03:35 PM, Eric B Munson wrote: On Mon, 27 Jul 2015, Vlastimil Babka wrote: On 07/24/2015 11:28 PM, Eric B Munson wrote: ... Changes from V4: Drop all architectures for new sys call entries except x86[_64] and MIPS Drop munlock2 and munlockall2 Make VM_LOCKONFAULT a modifier to

Re: [PATCH V5 0/7] Allow user to request memory to be locked on page fault

2015-07-27 Thread Vlastimil Babka
On 07/24/2015 11:28 PM, Eric B Munson wrote: ... Changes from V4: Drop all architectures for new sys call entries except x86[_64] and MIPS Drop munlock2 and munlockall2 Make VM_LOCKONFAULT a modifier to VM_LOCKED only to simplify book keeping Adjust tests to match Hi, thanks for considering