All of lore.kernel.org
 help / color / mirror / Atom feed
From: Vineet Gupta <Vineet.Gupta1@synopsys.com>
To: Andrew Morton <akpm@linux-foundation.org>,
	Chris Zankel <chris@zankel.net>,
	Max Filippov <jcmvbkbc@gmail.com>,
	Marc Gauthier <marc@tensilica.com>
Cc: Vineet Gupta <Vineet.Gupta1@synopsys.com>,
	<linux-xtensa@linux-xtensa.org>, <linux-kernel@vger.kernel.org>
Subject: [PATCH 2/2] xtensa: Flat DeviceTree copy not future-safe
Date: Fri, 22 Feb 2013 00:09:22 +0530	[thread overview]
Message-ID: <1361471962-25164-3-git-send-email-vgupta@synopsys.com> (raw)
In-Reply-To: <1361471962-25164-1-git-send-email-vgupta@synopsys.com>

flat DT copy code calls bootmem allocator with @align = 0.
This is probably OK with legacy allocator which xtensa uses right now,
but this will panic right away with memblock allocator

Signed-off-by: Vineet Gupta <vgupta@synopsys.com>
Cc: Chris Zankel <chris@zankel.net>
Cc: Max Filippov <jcmvbkbc@gmail.com>
Cc: Marc Gauthier <marc@tensilica.com>
Cc: linux-xtensa@linux-xtensa.org
Cc: linux-kernel@vger.kernel.org
---
 arch/xtensa/kernel/setup.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/arch/xtensa/kernel/setup.c b/arch/xtensa/kernel/setup.c
index 6dd25ec..c2a526e 100644
--- a/arch/xtensa/kernel/setup.c
+++ b/arch/xtensa/kernel/setup.c
@@ -256,7 +256,7 @@ void __init early_init_devtree(void *params)
 static void __init copy_devtree(void)
 {
 	void *alloc = early_init_dt_alloc_memory_arch(
-			be32_to_cpu(initial_boot_params->totalsize), 0);
+			be32_to_cpu(initial_boot_params->totalsize), 8);
 	if (alloc) {
 		memcpy(alloc, initial_boot_params,
 				be32_to_cpu(initial_boot_params->totalsize));
-- 
1.7.4.1


  parent reply	other threads:[~2013-02-21 18:40 UTC|newest]

Thread overview: 26+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <1361471962-25164-1-git-send-email-vgupta@synopsys.com>
2013-02-21 18:39 ` [PATCH 1/2] memblock: add assertion for zero allocation size Vineet Gupta
2013-02-21 18:39   ` Vineet Gupta
2013-02-21 19:27   ` Yinghai Lu
2013-02-21 19:27     ` Yinghai Lu
2013-02-21 19:33     ` Vineet Gupta
2013-02-21 19:33       ` Vineet Gupta
2013-02-21 19:36       ` Tejun Heo
2013-02-21 19:36         ` Tejun Heo
2013-02-21 19:43         ` Vineet Gupta
2013-02-21 19:43           ` Vineet Gupta
2013-02-21 20:10         ` [PATCH v2 1/2] memblock: add assertion for zero allocation alignment Vineet Gupta
2013-02-21 20:10           ` Vineet Gupta
2013-02-21 20:31           ` Yinghai Lu
2013-02-21 20:31             ` Yinghai Lu
2013-02-21 20:47             ` Vineet Gupta
2013-02-21 20:47               ` Vineet Gupta
2013-02-21 20:52             ` [PATCH v3 " Vineet Gupta
2013-02-21 20:52               ` Vineet Gupta
2013-02-21 20:53               ` Tejun Heo
2013-02-21 20:53                 ` Tejun Heo
2013-03-04 11:15                 ` Vineet Gupta
2013-03-04 11:15                   ` Vineet Gupta
2013-02-21 18:39 ` Vineet Gupta [this message]
2013-02-21 20:06   ` [PATCH 2/2] xtensa: Flat DeviceTree copy not future-safe Max Filippov
2013-05-29 13:10   ` Fwd: " Vineet Gupta
2013-05-31  1:01     ` Max Filippov

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=1361471962-25164-3-git-send-email-vgupta@synopsys.com \
    --to=vineet.gupta1@synopsys.com \
    --cc=akpm@linux-foundation.org \
    --cc=chris@zankel.net \
    --cc=jcmvbkbc@gmail.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-xtensa@linux-xtensa.org \
    --cc=marc@tensilica.com \
    /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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.