qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
From: Peter Maydell <peter.maydell@linaro.org>
To: "Andreas Färber" <afaerber@suse.de>
Cc: "Edgar E. Iglesias" <edgar.iglesias@gmail.com>,
	Andreas Galauner <andreas@galauner.de>,
	QEMU Developers <qemu-devel@nongnu.org>,
	Paolo Bonzini <pbonzini@redhat.com>
Subject: Re: [Qemu-devel] Cortex-M3: reading NVIC registers causes segfaults
Date: Tue, 18 Feb 2014 09:51:26 +0000	[thread overview]
Message-ID: <CAFEAcA8tS3h0Dz5EZBYLbwjy9=WRVsD+fgB9PLaCHsSmHojzjA@mail.gmail.com> (raw)
In-Reply-To: <5302B40F.5090009@suse.de>

On 18 February 2014 01:14, Andreas Färber <afaerber@suse.de> wrote:
> While first_cpu may help Andreas in his local copy for STM32, that
> assumption is not okay in general. The Vybrid VF6 has both a GIC and an
> NVIC, so our NVIC code should not make assumptions which CPU it can
> access.

Do you mean it has an M core CPU with an NVIC plus some other
A-class CPU with a GIC. Certainly in a system with heterogenous
CPUs this change won't work, but we don't support that at all
currently and there's a lot of work between here and there.

> I assume we would shield both using CPU address spaces

The GIC needs to know which CPU it's being accessed by.
I guess in theory you could have it export N distributor memory
regions which were identical apart from making "I assume I'm
being accessed by CPU X" assumptions, but that seems like a
bit of a kludge. Ideally we should have some way for the target
of a memory transaction to get at information about the source
(ie all the out of band info that hardware sends like master ID,
privilege level, secure vs nonsecure, etc).

> but I
> wonder if either of you two has already thought about how those will
> interact for gdbstub?

I'd need to look at the protocol to figure out if gdbstub does
memory accesses in the context of a particular thread (CPU
for us) or not. If not, that could be awkward.

thanks
-- PMM

      reply	other threads:[~2014-02-18  9:52 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-02-17 14:52 [Qemu-devel] Cortex-M3: reading NVIC registers causes segfaults Andreas Galauner
2014-02-17 15:18 ` Peter Maydell
2014-02-18  1:14   ` Andreas Färber
2014-02-18  9:51     ` 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='CAFEAcA8tS3h0Dz5EZBYLbwjy9=WRVsD+fgB9PLaCHsSmHojzjA@mail.gmail.com' \
    --to=peter.maydell@linaro.org \
    --cc=afaerber@suse.de \
    --cc=andreas@galauner.de \
    --cc=edgar.iglesias@gmail.com \
    --cc=pbonzini@redhat.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).