From: Peter Maydell <peter.maydell@linaro.org>
To: peter.crosthwaite@xilinx.com
Cc: qemu-devel@nongnu.org
Subject: Re: [Qemu-devel] [PATCH v1 1/1] target-arm: helper.c: RAZ REVIDR cp register
Date: Tue, 23 Apr 2013 11:55:17 +0100 [thread overview]
Message-ID: <CAFEAcA82UGBOZGyMOSuF3ouNqZchrOF_E9DBVw1Xp9=fF-pafQ@mail.gmail.com> (raw)
In-Reply-To: <a1a99e3d3e17686fe0540a0e18ece49b62110275.1366682426.git.peter.crosthwaite@xilinx.com>
On 23 April 2013 03:08, <peter.crosthwaite@xilinx.com> wrote:
> From: Peter Crosthwaite <peter.crosthwaite@xilinx.com>
>
> Guests should be able to read REVIDR without suffering an abort. Just
> RAZ the REVIDR register.
>
> Signed-off-by: Peter Crosthwaite <peter.crosthwaite@xilinx.com>
> ---
>
> target-arm/helper.c | 4 ++++
> 1 files changed, 4 insertions(+), 0 deletions(-)
>
> diff --git a/target-arm/helper.c b/target-arm/helper.c
> index fd055e8..e655c74 100644
> --- a/target-arm/helper.c
> +++ b/target-arm/helper.c
> @@ -1187,6 +1187,10 @@ void register_cp_regs_for_features(ARMCPU *cpu)
> { .name = "TLBTR",
> .cp = 15, .crn = 0, .crm = 0, .opc1 = 0, .opc2 = 3,
> .access = PL1_R, .type = ARM_CP_CONST, .resetvalue = 0 },
> + /* RAZ the REVIDR register */
> + { .name = "REVIDR",
> + .cp = 15, .crn = 0, .crm = 0, .opc1 = 0, .opc2 = 6,
> + .access = PL1_R, .type = ARM_CP_CONST, .resetvalue = 0 },
> /* crn = 0 op1 = 0 crm = 3..7 : currently unassigned; we RAZ. */
> { .name = "DUMMY",
> .cp = 15, .crn = 0, .crm = 3, .opc1 = 0, .opc2 = CP_ANY,
REVIDR is v7 only, so I don't think this is the right place to define it.
(It's also IMPDEF whether it exists or whether it's an alias for MIDR;
A7, A9 and A15 have a REVIDR, A5 and A8 don't.)
I suggest doing what we do for the MPIDR: define a feature bit
and a one-entry cp_reginfo for it.
(We don't implement the documented behaviour that unallocated
entries in c0,c0,0,X should read the MIDR, so I wouldn't worry
about that.)
thanks
-- PMM
prev parent reply other threads:[~2013-04-23 10:55 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <cover.1366682426.git.peter.crosthwaite@xilinx.com>
2013-04-23 2:08 ` [Qemu-devel] [PATCH v1 1/1] target-arm: helper.c: RAZ REVIDR cp register peter.crosthwaite
2013-04-23 10:55 ` Peter Maydell [this message]
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='CAFEAcA82UGBOZGyMOSuF3ouNqZchrOF_E9DBVw1Xp9=fF-pafQ@mail.gmail.com' \
--to=peter.maydell@linaro.org \
--cc=peter.crosthwaite@xilinx.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).