linux-mm.kvack.org archive mirror
 help / color / mirror / Atom feed
From: David Miller <davem@davemloft.net>
To: hannes@cmpxchg.org
Cc: x86@kernel.org, akpm@linux-foundation.org, ben@decadent.org.uk,
	linux-mm@kvack.org, linux-arch@vger.kernel.org,
	linux-kernel@vger.kernel.org
Subject: Re: [patch 2/5] sparse-vmemmap: specify vmemmap population range in bytes
Date: Wed, 20 Mar 2013 14:43:41 -0400 (EDT)	[thread overview]
Message-ID: <20130320.144341.680730923044605208.davem@davemloft.net> (raw)
In-Reply-To: <1363802612-32127-3-git-send-email-hannes@cmpxchg.org>

From: Johannes Weiner <hannes@cmpxchg.org>
Date: Wed, 20 Mar 2013 14:03:29 -0400

> The sparse code, when asking the architecture to populate the vmemmap,
> specifies the section range as a starting page and a number of pages.
> 
> This is an awkward interface, because none of the arch-specific code
> actually thinks of the range in terms of 'struct page' units and
> always translates it to bytes first.
> 
> In addition, later patches mix huge page and regular page backing for
> the vmemmap.  For this, they need to call vmemmap_populate_basepages()
> on sub-section ranges with PAGE_SIZE and PMD_SIZE in mind.  But these
> are not necessarily multiples of the 'struct page' size and so this
> unit is too coarse.
> 
> Just translate the section range into bytes once in the generic sparse
> code, then pass byte ranges down the stack.
> 
> Signed-off-by: Johannes Weiner <hannes@cmpxchg.org>

Boot tested on sparc64:

Acked-by: David S. Miller <davem@davemloft.net>

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

  reply	other threads:[~2013-03-20 18:43 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-03-20 18:03 [patch 0/5] sparse-vmemmap: hotplug fixes & cleanups Johannes Weiner
2013-03-20 18:03 ` [patch 1/5] mm: Try harder to allocate vmemmap blocks Johannes Weiner
2013-03-20 18:03 ` [patch 2/5] sparse-vmemmap: specify vmemmap population range in bytes Johannes Weiner
2013-03-20 18:43   ` David Miller [this message]
2013-03-20 18:03 ` [patch 3/5] x86-64: remove dead debugging code for !pse setups Johannes Weiner
2013-03-20 18:03 ` [patch 4/5] x86-64: use vmemmap_populate_basepages() " Johannes Weiner
2013-03-20 18:03 ` [patch 5/5] x86-64: fall back to regular page vmemmap on allocation failure Johannes Weiner

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20130320.144341.680730923044605208.davem@davemloft.net \
    --to=davem@davemloft.net \
    --cc=akpm@linux-foundation.org \
    --cc=ben@decadent.org.uk \
    --cc=hannes@cmpxchg.org \
    --cc=linux-arch@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-mm@kvack.org \
    --cc=x86@kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).