From: Mark Langsdorf <mark.langsdorf@calxeda.com>
To: qemu-devel@nongnu.org
Cc: i.mitsyanko@gmail.com, peter.maydell@linaro.org,
afaerber@suse.de, mark.langsdorf@calxeda.com,
edgar.iglesias@gmail.com
Subject: [Qemu-devel] [PATCH v13 4/6] arm_boot: support board IDs more than 16 bits wide
Date: Fri, 20 Jan 2012 14:46:58 -0600 [thread overview]
Message-ID: <1327092420-10814-5-git-send-email-mark.langsdorf@calxeda.com> (raw)
In-Reply-To: <1327092420-10814-1-git-send-email-mark.langsdorf@calxeda.com>
From: Peter Maydell <peter.maydell@linaro.org>
Support passing a board ID value to the kernel in r1
that is more than 16 bits wide. This is needed to pass
the '-1 == invalid' value for boards which only support
device tree booting.
Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
Tested-by: Mark Langsdorf <mark.langsdorf@calxeda.com>
---
Changes from v1-v12
Skipped
hw/arm_boot.c | 11 +++++------
1 files changed, 5 insertions(+), 6 deletions(-)
diff --git a/hw/arm_boot.c b/hw/arm_boot.c
index 35ca22f..5f163fd 100644
--- a/hw/arm_boot.c
+++ b/hw/arm_boot.c
@@ -20,10 +20,10 @@
/* The worlds second smallest bootloader. Set r0-r2, then jump to kernel. */
static uint32_t bootloader[] = {
0xe3a00000, /* mov r0, #0 */
- 0xe3a01000, /* mov r1, #0x?? */
- 0xe3811c00, /* orr r1, r1, #0x??00 */
- 0xe59f2000, /* ldr r2, [pc, #0] */
- 0xe59ff000, /* ldr pc, [pc, #0] */
+ 0xe59f1004, /* ldr r1, [pc, #4] */
+ 0xe59f2004, /* ldr r2, [pc, #4] */
+ 0xe59ff004, /* ldr pc, [pc, #4] */
+ 0, /* Board ID */
0, /* Address of kernel args. Set by integratorcp_init. */
0 /* Kernel entry point. Set by integratorcp_init. */
};
@@ -301,8 +301,7 @@ void arm_load_kernel(CPUState *env, struct arm_boot_info *info)
} else {
initrd_size = 0;
}
- bootloader[1] |= info->board_id & 0xff;
- bootloader[2] |= (info->board_id >> 8) & 0xff;
+ bootloader[4] = info->board_id;
bootloader[5] = info->loader_start + KERNEL_ARGS_ADDR;
bootloader[6] = entry;
for (n = 0; n < sizeof(bootloader) / 4; n++) {
--
1.7.5.4
next prev parent reply other threads:[~2012-01-20 20:47 UTC|newest]
Thread overview: 19+ messages / expand[flat|nested] mbox.gz Atom feed top
2012-01-20 20:46 [Qemu-devel] [PATCH v13 0/6] arm: add support for Calxeda Highbank Mark Langsdorf
2012-01-20 20:46 ` [Qemu-devel] [PATCH v13 1/6] Add xgmac ethernet model Mark Langsdorf
2012-01-20 20:46 ` [Qemu-devel] [PATCH v13 2/6] ahci: add support for non-PCI based controllers Mark Langsdorf
2012-01-20 20:46 ` [Qemu-devel] [PATCH v13 3/6] arm: add secondary cpu boot callbacks to arm_boot.c Mark Langsdorf
2012-01-23 14:24 ` Peter Maydell
2012-01-20 20:46 ` Mark Langsdorf [this message]
2012-01-20 20:46 ` [Qemu-devel] [PATCH v13 5/6] arm: store the config_base_register during cpu_reset Mark Langsdorf
2012-01-23 14:41 ` Peter Maydell
2012-01-20 20:47 ` [Qemu-devel] [PATCH v13 6/6] arm: SoC model for Calxeda Highbank Mark Langsdorf
2012-01-23 14:34 ` Peter Maydell
2012-01-23 16:05 ` [Qemu-devel] [PATCH v14 0/6] arm: add support " Mark Langsdorf
2012-01-23 16:05 ` [Qemu-devel] [PATCH v14 1/6] Add xgmac ethernet model Mark Langsdorf
2012-01-23 16:05 ` [Qemu-devel] [PATCH v14 2/6] ahci: add support for non-PCI based controllers Mark Langsdorf
2012-01-23 16:05 ` [Qemu-devel] [PATCH v14 3/6] arm: add secondary cpu boot callbacks to arm_boot.c Mark Langsdorf
2012-01-23 16:05 ` [Qemu-devel] [PATCH v14 4/6] arm_boot: support board IDs more than 16 bits wide Mark Langsdorf
2012-01-23 16:05 ` [Qemu-devel] [PATCH v14 5/6] arm: store the config_base_register during cpu_reset Mark Langsdorf
2012-01-23 17:37 ` Peter Maydell
2012-01-23 16:05 ` [Qemu-devel] [PATCH v14 6/6] arm: SoC model for Calxeda Highbank Mark Langsdorf
2012-01-23 17:43 ` Peter Maydell
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=1327092420-10814-5-git-send-email-mark.langsdorf@calxeda.com \
--to=mark.langsdorf@calxeda.com \
--cc=afaerber@suse.de \
--cc=edgar.iglesias@gmail.com \
--cc=i.mitsyanko@gmail.com \
--cc=peter.maydell@linaro.org \
--cc=qemu-devel@nongnu.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).