Re: 64GB NUMA-Q after pgcl

Andrea Arcangeli (andrea@suse.de)
Tue, 1 Apr 2003 03:25:53 +0200


On Mon, Mar 31, 2003 at 02:27:33PM -0800, William Lee Irwin III wrote:
> On Sun, Mar 30, 2003 at 09:22:14PM -0800, William Lee Irwin III wrote:
> >> Miscellaneous side effects happen, like follow_page() and
> >> get_user_pages() need to return pfn's instead of struct pages.
>
> On Mon, Mar 31, 2003 at 11:02:51PM +0200, Ingo Oeser wrote:
> > Hmm, but you know, that users of get_user_pages() play games with
> > pages? They need to lock them into memory, mark them eventually
> > dirty, map them to a struct scatterlist and much more.
> > I worked on an API (I called it the page-walk-api), to make this
> > more and more transparent.
>
> There are no changes of semantics, it finds the struct page, does
> page_cache_get() and fiddles with the struct page just like before, but
> it needs to use the pfn as the handle to the thing when returning it to
> the caller, not the struct page pointer.
>
> The caller invariably needs the page structures to do anything, but
> it also often needs the subpfn (which pfn inside the area tracked by
> the struct page). The pfn is just the most compact way to pass that
> information. Things end up doing pfn_to_page() to get at the page
> structures that are returned in current mainline, and just use the
> low bits of the pfn to reconstruct the offset into the page for copying
> and bitblitting and so on.

This complicates things but to get the file offset right it's probably
unavoidable to leave hard page size knowledge in the common code in
terms of hard-pfn.

> On Mon, Mar 31, 2003 at 11:02:51PM +0200, Ingo Oeser wrote:
> > So if this work will go into 2.6.x, then the page-walk-API will
> > be needed, or else the driver writers playing tricks with
> > virtual<->physical<->bus address conversions will go nuts.
> > So which kernel is the target of this development?
>
> My target for this has always been 2.7; earlier kernels can take
> things on at the maintainer's discretion. I expect it to live out
> of tree for a substantial amount of time. =(

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