From: Alistair Francis <alistair.francis@xilinx.com>
To: qemu-devel@nongnu.org, peter.maydell@linaro.org
Cc: alistair.francis@xilinx.com, crosthwaitepeter@gmail.com,
armbru@redhat.com, cov@codeaurora.org, pbonzini@redhat.com
Subject: [Qemu-devel] [PATCH v9 2/8] loader: Use the specified MemoryRegion
Date: Wed, 13 Jul 2016 17:03:27 -0700 [thread overview]
Message-ID: <ac9e812d6a1231d4ca9ce30e42daeffe3e39b48e.1468454556.git.alistair.francis@xilinx.com> (raw)
In-Reply-To: <cover.1468454556.git.alistair.francis@xilinx.com>
Prevously the specified MemoryRegion was ignored during the rom register
reset. This patch uses the rom MemoryRegion is avaliable.
Signed-off-by: Alistair Francis <alistair.francis@xilinx.com>
---
hw/core/loader.c | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/hw/core/loader.c b/hw/core/loader.c
index 53e0e41..6b61f29 100644
--- a/hw/core/loader.c
+++ b/hw/core/loader.c
@@ -1045,7 +1045,8 @@ int rom_check_and_register_reset(void)
}
addr = rom->addr;
addr += rom->romsize;
- section = memory_region_find(get_system_memory(), rom->addr, 1);
+ section = memory_region_find(rom->mr ? rom->mr : get_system_memory(),
+ rom->addr, 1);
rom->isrom = int128_nz(section.size) && memory_region_is_rom(section.mr);
memory_region_unref(section.mr);
}
--
2.7.4
next prev parent reply other threads:[~2016-07-14 0:04 UTC|newest]
Thread overview: 20+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-07-14 0:03 [Qemu-devel] [PATCH v9 0/8] Add a generic loader Alistair Francis
2016-07-14 0:03 ` [Qemu-devel] [PATCH v9 1/8] loader: Allow ELF loader to auto-detect the ELF arch Alistair Francis
2016-07-29 15:42 ` Peter Maydell
2016-08-02 0:03 ` Alistair Francis
2016-07-14 0:03 ` Alistair Francis [this message]
2016-07-29 17:34 ` [Qemu-devel] [PATCH v9 2/8] loader: Use the specified MemoryRegion Peter Maydell
2016-07-14 0:03 ` [Qemu-devel] [PATCH v9 3/8] loader: Allow a custom AddressSpace when loading ROMs Alistair Francis
2016-07-29 15:56 ` Peter Maydell
2016-08-02 22:59 ` Alistair Francis
2016-07-14 0:03 ` [Qemu-devel] [PATCH v9 4/8] loader: Add AddressSpace loading support to ELFs Alistair Francis
2016-07-29 17:35 ` Peter Maydell
2016-07-14 0:03 ` [Qemu-devel] [PATCH v9 5/8] loader: Add AddressSpace loading support to uImages Alistair Francis
2016-07-29 17:41 ` Peter Maydell
2016-07-14 0:03 ` [Qemu-devel] [PATCH v9 6/8] loader: Add AddressSpace loading support to targphys Alistair Francis
2016-07-29 17:42 ` Peter Maydell
2016-08-02 21:21 ` Alistair Francis
2016-07-14 0:03 ` [Qemu-devel] [PATCH v9 7/8] generic-loader: Add a generic loader Alistair Francis
2016-07-14 0:03 ` [Qemu-devel] [PATCH v9 8/8] docs: Add a generic loader explanation document Alistair Francis
2016-07-29 17:55 ` Peter Maydell
2016-08-03 18:22 ` Alistair Francis
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=ac9e812d6a1231d4ca9ce30e42daeffe3e39b48e.1468454556.git.alistair.francis@xilinx.com \
--to=alistair.francis@xilinx.com \
--cc=armbru@redhat.com \
--cc=cov@codeaurora.org \
--cc=crosthwaitepeter@gmail.com \
--cc=pbonzini@redhat.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).