From: Paolo Bonzini <pbonzini@redhat.com>
To: qemu-devel@nongnu.org
Cc: peter.maydell@linaro.org, qemu-arm@nongnu.org
Subject: [PATCH v2 003/122] cris: do not use ram_size global
Date: Fri, 13 Nov 2020 05:15:05 -0500 [thread overview]
Message-ID: <20201113101704.1438368-3-pbonzini@redhat.com> (raw)
In-Reply-To: <20201113101704.1438368-1-pbonzini@redhat.com>
Use the machine properties instead.
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
---
hw/cris/axis_dev88.c | 1 +
hw/cris/boot.c | 2 +-
hw/cris/boot.h | 1 +
3 files changed, 3 insertions(+), 1 deletion(-)
diff --git a/hw/cris/axis_dev88.c b/hw/cris/axis_dev88.c
index dab7423c73..b0cb6d84af 100644
--- a/hw/cris/axis_dev88.c
+++ b/hw/cris/axis_dev88.c
@@ -333,6 +333,7 @@ void axisdev88_init(MachineState *machine)
if (kernel_filename) {
li.image_filename = kernel_filename;
li.cmdline = kernel_cmdline;
+ li.ram_size = machine->ram_size;
cris_load_image(cpu, &li);
} else if (!qtest_enabled()) {
fprintf(stderr, "Kernel image must be specified\n");
diff --git a/hw/cris/boot.c b/hw/cris/boot.c
index aa8d2756d6..9fa09cfd83 100644
--- a/hw/cris/boot.c
+++ b/hw/cris/boot.c
@@ -81,7 +81,7 @@ void cris_load_image(CRISCPU *cpu, struct cris_load_info *li)
if (image_size < 0) {
/* Takes a kimage from the axis devboard SDK. */
image_size = load_image_targphys(li->image_filename, 0x40004000,
- ram_size);
+ li->ram_size);
li->entry = 0x40004000;
}
diff --git a/hw/cris/boot.h b/hw/cris/boot.h
index 218854e5d1..9f1e0e340c 100644
--- a/hw/cris/boot.h
+++ b/hw/cris/boot.h
@@ -6,6 +6,7 @@ struct cris_load_info
const char *image_filename;
const char *cmdline;
int image_size;
+ ram_addr_t ram_size;
hwaddr entry;
};
--
2.26.2
next prev parent reply other threads:[~2020-11-13 10:19 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-11-13 10:15 [PATCH v2 001/122] vl: remove bios_name Paolo Bonzini
2020-11-13 10:15 ` [PATCH v2 002/122] arm: do not use ram_size global Paolo Bonzini
2020-11-13 10:15 ` Paolo Bonzini [this message]
2020-11-13 10:15 ` [PATCH v2 004/122] hppa: " Paolo Bonzini
2020-11-13 10:15 ` [PATCH v2 005/122] i386: " Paolo Bonzini
2020-11-13 10:15 ` [PATCH v2 006/122] m68k: " Paolo Bonzini
2020-11-13 10:44 ` Thomas Huth
2020-11-13 11:17 ` Paolo Bonzini
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=20201113101704.1438368-3-pbonzini@redhat.com \
--to=pbonzini@redhat.com \
--cc=peter.maydell@linaro.org \
--cc=qemu-arm@nongnu.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).