Re: [PATCH -mm] mincore: apply page table walker on do_mincore() (Re: [PATCH 00/10] mm: pagewalk: huge page cleanups and VMA passing)

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

 



On Tue, Jun 03, 2014 at 08:59:45AM -0700, Dave Hansen wrote:
> On 06/02/2014 11:18 PM, Naoya Horiguchi wrote:
> > +	/*
> > +	 * Huge pages are always in RAM for now, but
> > +	 * theoretically it needs to be checked.
> > +	 */
> > +	present = pte && !huge_pte_none(huge_ptep_get(pte));
> > +	for (; addr != end; vec++, addr += PAGE_SIZE)
> > +		*vec = present;
> > +	cond_resched();
> > +	walk->private += (end - addr) >> PAGE_SHIFT;
> 
> That comment is bogus, fwiw.  Huge pages are demand-faulted and it's
> quite possible that they are not present.

No. hugetlbfs adopts prefault mechanism, which creates free hugepage
pool in advance and hugepage allocation is done from the pool,
The above comment claims this. But if we want to comment more precisely,
it should be like "Hugepages under user process are always in RAM and
never swapped out, but ...".

Thanks,
Naoya Horiguchi

--
To unsubscribe, send a message with 'unsubscribe linux-mm' in
the body to majordomo@xxxxxxxxx.  For more info on Linux MM,
see: http://www.linux-mm.org/ .
Don't email: <a href=mailto:"dont@xxxxxxxxx";> email@xxxxxxxxx </a>




[Index of Archives]     [Linux ARM Kernel]     [Linux ARM]     [Linux Omap]     [Fedora ARM]     [IETF Annouce]     [Bugtraq]     [Linux]     [Linux OMAP]     [Linux MIPS]     [ECOS]     [Asterisk Internet PBX]     [Linux API]