linux-mm.kvack.org archive mirror
 help / color / mirror / Atom feed
From: Benjamin Herrenschmidt <benh@kernel.crashing.org>
To: linux-mm@kvack.org
Cc: linux-kernel@vger.kernel.org, tglx@linutronix.de, mingo@elte.hu,
	davem@davemloft.net, lethal@linux-sh.org,
	Benjamin Herrenschmidt <benh@kernel.crashing.org>
Subject: [PATCH 24/25] lmb: Make lmb_alloc_try_nid() fallback to LMB_ALLOC_ANYWHERE
Date: Mon, 10 May 2010 19:46:04 +1000	[thread overview]
Message-ID: <1273484765-29055-24-git-send-email-benh@kernel.crashing.org> (raw)
In-Reply-To: <1273484765-29055-23-git-send-email-benh@kernel.crashing.org>

lmb_alloc_nid() used to fallback to allocating anywhere by using
lmb_alloc() as a fallback.

However, some of my previous patches limit lmb_alloc() to the region
covered by LMB_ALLOC_ACCESSIBLE which is not quite what we want
for lmb_alloc_try_nid().

So we fix it by explicitely using LMB_ALLOC_ANYWHERE.

Not that so far only sparc uses lmb_alloc_nid() and it hasn't been updated
to clamp the accessible zone yet. Thus the temporary "breakage" should have
no effect.

Signed-off-by: Benjamin Herrenschmidt <benh@kernel.crashing.org>
---
 lib/lmb.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/lib/lmb.c b/lib/lmb.c
index fd98261..6c38c87 100644
--- a/lib/lmb.c
+++ b/lib/lmb.c
@@ -531,7 +531,7 @@ phys_addr_t __init lmb_alloc_try_nid(phys_addr_t size, phys_addr_t align, int ni
 
 	if (res)
 		return res;
-	return lmb_alloc(size, align);
+	return lmb_alloc_base(size, align, LMB_ALLOC_ANYWHERE);
 }
 
 
-- 
1.6.3.3

--
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:[~2010-05-10  9:46 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <1273484765-29055-1-git-send-email-benh@kernel.crashing.org>
     [not found] ` <1273484765-29055-2-git-send-email-benh@kernel.crashing.org>
     [not found]   ` <1273484765-29055-3-git-send-email-benh@kernel.crashing.org>
     [not found]     ` <1273484765-29055-4-git-send-email-benh@kernel.crashing.org>
     [not found]       ` <1273484765-29055-5-git-send-email-benh@kernel.crashing.org>
     [not found]         ` <1273484765-29055-6-git-send-email-benh@kernel.crashing.org>
     [not found]           ` <1273484765-29055-7-git-send-email-benh@kernel.crashing.org>
     [not found]             ` <1273484765-29055-8-git-send-email-benh@kernel.crashing.org>
     [not found]               ` <1273484765-29055-9-git-send-email-benh@kernel.crashing.org>
     [not found]                 ` <1273484765-29055-10-git-send-email-benh@kernel.crashing.org>
     [not found]                   ` <1273484765-29055-11-git-send-email-benh@kernel.crashing.org>
     [not found]                     ` <1273484765-29055-12-git-send-email-benh@kernel.crashing.org>
     [not found]                       ` <1273484765-29055-13-git-send-email-benh@kernel.crashing.org>
     [not found]                         ` <1273484765-29055-14-git-send-email-benh@kernel.crashing.org>
     [not found]                           ` <1273484765-29055-15-git-send-email-benh@kernel.crashing.org>
     [not found]                             ` <1273484765-29055-16-git-send-email-benh@kernel.crashing.org>
     [not found]                               ` <1273484765-29055-17-git-send-email-benh@kernel.crashing.org>
     [not found]                                 ` <1273484765-29055-18-git-send-email-benh@kernel.crashing.org>
     [not found]                                   ` <1273484765-29055-19-git-send-email-benh@kernel.crashing.org>
     [not found]                                     ` <1273484765-29055-20-git-send-email-benh@kernel.crashing.org>
     [not found]                                       ` <1273484765-29055-21-git-send-email-benh@kernel.crashing.org>
     [not found]                                         ` <1273484765-29055-22-git-send-email-benh@kernel.crashing.org>
     [not found]                                           ` <1273484765-29055-23-git-send-email-benh@kernel.crashing.org>
2010-05-10  9:46                                             ` Benjamin Herrenschmidt [this message]
2010-05-10  9:46                                               ` [PATCH 25/25] lmb: Add debugfs files to dump the arrays content Benjamin Herrenschmidt

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=1273484765-29055-24-git-send-email-benh@kernel.crashing.org \
    --to=benh@kernel.crashing.org \
    --cc=davem@davemloft.net \
    --cc=lethal@linux-sh.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-mm@kvack.org \
    --cc=mingo@elte.hu \
    --cc=tglx@linutronix.de \
    /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).