All of lore.kernel.org
 help / color / mirror / Atom feed
From: Matthew McClintock <msm@freescale.com>
To: u-boot@lists.denx.de
Subject: [U-Boot] [PATCH V2] mpx85xx/fdt: Add cpu-release-addr for all cores
Date: Thu, 19 Aug 2010 13:57:48 -0500	[thread overview]
Message-ID: <1282244268-30693-1-git-send-email-msm@freescale.com> (raw)
In-Reply-To: <E4D43E95-E42C-4A01-862B-CCEE0B38718B@freescale.com>

We currently do not add a cpu-release-addr for core 0, this is needed
when we want to reset core 0 and later restart it from Linux

Signed-off-by: Matthew McClintock <msm@freescale.com>
---
v2: Mark boot cpu status as "okay"

 arch/powerpc/cpu/mpc85xx/fdt.c |   15 ++++++++-------
 1 files changed, 8 insertions(+), 7 deletions(-)

diff --git a/arch/powerpc/cpu/mpc85xx/fdt.c b/arch/powerpc/cpu/mpc85xx/fdt.c
index 8e7b827..4540364 100644
--- a/arch/powerpc/cpu/mpc85xx/fdt.c
+++ b/arch/powerpc/cpu/mpc85xx/fdt.c
@@ -54,18 +54,19 @@ void ft_fixup_cpu(void *blob, u64 memory_limit)
 		u32 *reg = (u32 *)fdt_getprop(blob, off, "reg", 0);
 
 		if (reg) {
+			u64 val = *reg * SIZE_BOOT_ENTRY + spin_tbl_addr;
+			val = cpu_to_fdt32(val);
 			if (*reg == id) {
-				fdt_setprop_string(blob, off, "status", "okay");
+				fdt_setprop_string(blob, off, "status",
+								"okay");
 			} else {
-				u64 val = *reg * SIZE_BOOT_ENTRY + spin_tbl_addr;
-				val = cpu_to_fdt32(val);
 				fdt_setprop_string(blob, off, "status",
 								"disabled");
-				fdt_setprop_string(blob, off, "enable-method",
-								"spin-table");
-				fdt_setprop(blob, off, "cpu-release-addr",
-						&val, sizeof(val));
 			}
+			fdt_setprop_string(blob, off, "enable-method",
+							"spin-table");
+			fdt_setprop(blob, off, "cpu-release-addr",
+					&val, sizeof(val));
 		} else {
 			printf ("cpu NULL\n");
 		}
-- 
1.6.6.1

  reply	other threads:[~2010-08-19 18:57 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-08-18 20:12 [U-Boot] [PATCH] mpx85xx/fdt: Add cpu-release-addr for all cores Matthew McClintock
2010-08-19  6:53 ` Kumar Gala
2010-08-19 18:57   ` Matthew McClintock [this message]
2010-08-20  2:27     ` [U-Boot] [PATCH V2] " Kumar Gala

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=1282244268-30693-1-git-send-email-msm@freescale.com \
    --to=msm@freescale.com \
    --cc=u-boot@lists.denx.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 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.