From: Peter Crosthwaite <peter.crosthwaite@xilinx.com>
To: qemu-devel@nongnu.org, peter.maydell@linaro.org
Cc: peter.crosthwaite@xilinx.com, antonynpavlov@gmail.com,
afaerber@suse.de, mark.langsdorf@calxeda.com, mst@redhat.com
Subject: [Qemu-devel] [PATCH target-arm v5 00/10] Fix Support for ARM CBAR and reset-hivecs
Date: Sun, 15 Dec 2013 18:28:09 -0800 [thread overview]
Message-ID: <cover.1387160489.git.peter.crosthwaite@xilinx.com> (raw)
Hi All,
This patch series adds support for two board configurable ARM CPU
properties - Configuration Base Address Register and the
hivecs-on-reset.
The CBAR is needed to fix Zynq and Highbank which both were broken for
linux boot. This series provides the fixes.
I have added these properties as qdev properties rather than object
properties to pick up the desired writable-until-realize semantic.
To test the semantics of these new qdev properties I hacked Highbank
to illegally set the property after realize:
diff --git a/hw/arm/highbank.c b/hw/arm/highbank.c
index c75b425..905483d 100644
--- a/hw/arm/highbank.c
+++ b/hw/arm/highbank.c
@@ -236,13 +236,13 @@ static void calxeda_init(QEMUMachineInitArgs
*args, enum cxmachines machine)
cpu = ARM_CPU(object_new(object_class_get_name(oc)));
- object_property_set_int(OBJECT(cpu), MPCORE_PERIPHBASE, "reset-cbar",
- &err);
+ object_property_set_bool(OBJECT(cpu), true, "realized", &err);
if (err) {
error_report("%s", error_get_pretty(err));
exit(1);
}
- object_property_set_bool(OBJECT(cpu), true, "realized", &err);
+ object_property_set_int(OBJECT(cpu), MPCORE_PERIPHBASE, "reset-cbar",
+ &err);
if (err) {
error_report("%s", error_get_pretty(err));
exit(1);
Booting with this bug I now get:
$ qemu-system-arm -M highbank ...
qemu-system-arm: Attempt to set property 'reset-cbar' on anonymous device (type 'cortex-a9-arm-cpu') after it was realized
whereas the previous versions would have silent failed.
Regards,
Peter
changed since v4:
Reimplemented using qdev properties
dropped QOM patches
rebased against mainline
changed since v3:
Rebased against target-arm patch queue (2013/12/11)
Added Antonys reset hivecs patches
changed since v2:
Fixed comment in p8 (PMM review)
Enabled CBAR for a15 (PMM review)
Typo sweep
Changed since v1:
Fix QOM to support writeable dynamic properties
Use dynamic props instead (PMM/AF discussion)
Use error_report (AF reivew)
Use reset- prefix on propname (AF review)
Fix machine model namings or the MPCore PERIPHBASE
Antony Pavlov (2):
ARM: cpu: add "reset_hivecs" property
ARM: arm_cpu_reset: make it possible to use high vectors for reset_exc
Peter Crosthwaite (8):
target-arm/helper.c: Allow cp15.c15 dummy override
target-arm: Define and use ARM_FEATURE_CBAR
target-arm/cpu: Convert reset CBAR to a property
arm/highbank: Use object_new() rather than cpu_arm_init()
arm/highbank: Fix CBAR initialisation
arm/xilinx_zynq: Use object_new() rather than cpu_arm_init()
arm/xilinx_zynq: Implement CBAR initialisation
arm/highbank.c: Fix MPCore periphbase name
hw/arm/highbank.c | 33 +++++++++++++++++++++------------
hw/arm/xilinx_zynq.c | 21 +++++++++++++++++----
target-arm/cpu-qom.h | 1 +
target-arm/cpu.c | 47 ++++++++++++++++++++++++++++++++++++++---------
target-arm/cpu.h | 1 +
target-arm/helper.c | 12 +++++++++++-
6 files changed, 89 insertions(+), 26 deletions(-)
--
1.8.5.1
next reply other threads:[~2013-12-16 2:28 UTC|newest]
Thread overview: 12+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-12-16 2:28 Peter Crosthwaite [this message]
2013-12-16 2:28 ` [Qemu-devel] [PATCH target-arm v5 01/10] target-arm/helper.c: Allow cp15.c15 dummy override Peter Crosthwaite
2013-12-16 2:29 ` [Qemu-devel] [PATCH target-arm v5 02/10] target-arm: Define and use ARM_FEATURE_CBAR Peter Crosthwaite
2013-12-16 2:29 ` [Qemu-devel] [PATCH target-arm v5 03/10] target-arm/cpu: Convert reset CBAR to a property Peter Crosthwaite
2013-12-16 2:30 ` [Qemu-devel] [PATCH target-arm v5 04/10] arm/highbank: Use object_new() rather than cpu_arm_init() Peter Crosthwaite
2013-12-16 2:31 ` [Qemu-devel] [PATCH target-arm v5 05/10] arm/highbank: Fix CBAR initialisation Peter Crosthwaite
2013-12-16 2:31 ` [Qemu-devel] [PATCH target-arm v5 06/10] arm/xilinx_zynq: Use object_new() rather than cpu_arm_init() Peter Crosthwaite
2013-12-16 2:32 ` [Qemu-devel] [PATCH target-arm v5 07/10] arm/xilinx_zynq: Implement CBAR initialisation Peter Crosthwaite
2013-12-16 2:32 ` [Qemu-devel] [PATCH target-arm v5 08/10] arm/highbank.c: Fix MPCore periphbase name Peter Crosthwaite
2013-12-16 2:33 ` [Qemu-devel] [PATCH target-arm v5 09/10] ARM: cpu: add "reset_hivecs" property Peter Crosthwaite
2013-12-16 2:33 ` [Qemu-devel] [PATCH target-arm v5 10/10] ARM: arm_cpu_reset: make it possible to use high vectors for reset_exc Peter Crosthwaite
2013-12-16 15:41 ` [Qemu-devel] [PATCH target-arm v5 00/10] Fix Support for ARM CBAR and reset-hivecs 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=cover.1387160489.git.peter.crosthwaite@xilinx.com \
--to=peter.crosthwaite@xilinx.com \
--cc=afaerber@suse.de \
--cc=antonynpavlov@gmail.com \
--cc=mark.langsdorf@calxeda.com \
--cc=mst@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).