From: Artyom Tarasenko <atar4qemu@googlemail.com>
To: qemu-devel@nongnu.org
Cc: blauwirbel@gmail.com, Artyom Tarasenko <atar4qemu@gmail.com>
Subject: [Qemu-devel] [patch 02/02] sparc32 use empty_slot for missing RAM v1
Date: Sun, 18 Apr 2010 00:34:03 +0200 [thread overview]
Message-ID: <1271543643-28463-1-git-send-email-atar4qemu@google.com> (raw)
use empty_slot device for the RAM which is not installed
Models without ECC don't trap when missing ram is accessed.
v0->v1 compile only once and fix indentation
Signed-off-by: Artyom Tarasenko <atar4qemu@gmail.com>
---
diff --git a/Makefile.objs b/Makefile.objs
index ab1af88..f4d2faf 100644
--- a/Makefile.objs
+++ b/Makefile.objs
@@ -140,6 +140,7 @@ hw-obj-$(CONFIG_PFLASH_CFI02) += pflash_cfi02.o
hw-obj-$(CONFIG_M48T59) += m48t59.o
hw-obj-$(CONFIG_ESCC) += escc.o
+hw-obj-$(CONFIG_EMPTY_SLOT) += empty_slot.o
hw-obj-$(CONFIG_SERIAL) += serial.o
hw-obj-$(CONFIG_PARALLEL) += parallel.o
diff --git a/default-configs/sparc-softmmu.mak b/default-configs/sparc-softmmu.mak
index 54899ff..becf880 100644
--- a/default-configs/sparc-softmmu.mak
+++ b/default-configs/sparc-softmmu.mak
@@ -7,3 +7,4 @@ CONFIG_M48T59=y
CONFIG_PTIMER=y
CONFIG_FDC=y
CONFIG_VIRTIO_PCI=y
+CONFIG_EMPTY_SLOT=y
diff --git a/hw/sun4m.c b/hw/sun4m.c
index 90e661d..73b6949 100644
--- a/hw/sun4m.c
+++ b/hw/sun4m.c
@@ -36,6 +36,7 @@
#include "isa.h"
#include "fw_cfg.h"
#include "escc.h"
+#include "empty_slot.h"
#include "qdev-addr.h"
#include "loader.h"
#include "elf.h"
@@ -820,7 +821,11 @@ static void sun4m_hw_init(const struct sun4m_hwdef *hwdef, ram_addr_t RAM_size,
/* set up devices */
ram_init(0, RAM_size, hwdef->max_mem);
-
+ /* models without ECC don't trap when missing ram is accessed */
+ if (!hwdef->ecc_base) {
+ empty_slot_init(RAM_size, hwdef->max_mem - RAM_size);
+ }
+
prom_init(hwdef->slavio_base, bios_name);
slavio_intctl = slavio_intctl_init(hwdef->intctl_base,
next reply other threads:[~2010-04-17 22:34 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2010-04-17 22:34 Artyom Tarasenko [this message]
2010-04-18 8:58 ` [Qemu-devel] Re: [patch 02/02] sparc32 use empty_slot for missing RAM v1 Blue Swirl
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=1271543643-28463-1-git-send-email-atar4qemu@google.com \
--to=atar4qemu@googlemail.com \
--cc=atar4qemu@gmail.com \
--cc=blauwirbel@gmail.com \
--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).