All of lore.kernel.org
 help / color / mirror / Atom feed
From: Joel Stanley <joel@jms.id.au>
To: Julia Suvorova <jusual@mail.ru>
Cc: "Peter Maydell" <peter.maydell@linaro.org>,
	"QEMU Developers" <qemu-devel@nongnu.org>,
	qemu-arm <qemu-arm@nongnu.org>,
	"Jim Mussared" <jim.mussared@gmail.com>,
	"Stefan Hajnoczi" <stefanha@gmail.com>,
	"Steffen Görtz" <contrib@steffen-goertz.de>
Subject: Re: [Qemu-devel] [PATCH v3 2/3] arm: Add Nordic Semiconductor nRF51 SoC
Date: Mon, 30 Jul 2018 23:32:55 +0930	[thread overview]
Message-ID: <CACPK8XfYvU8+0s+FBGe7NuAst38ska0vpS8HVPWkM8OHyLFpdQ@mail.gmail.com> (raw)
In-Reply-To: <94bc2d11-7916-bc4e-02d8-da62e3ed303b@mail.ru>

On 26 July 2018 at 20:31, Julia Suvorova <jusual@mail.ru> wrote:

>> +++ b/hw/arm/nrf51_soc.c

>> +static void nrf51_soc_init(Object *obj)
>> +{
>> +    NRF51State *s = NRF51_SOC(obj);
>> +
>> +    memory_region_init(&s->container, obj, "nrf51-container",
>> UINT64_MAX);
>> +
>> +    object_initialize(&s->cpu, sizeof(s->cpu), TYPE_ARM_M_PROFILE);
>> +    object_property_add_child(OBJECT(s), "armv6m", OBJECT(&s->cpu),
>> &error_abort);
>> +    qdev_set_parent_bus(DEVICE(&s->cpu), sysbus_get_default());
>> +    qdev_prop_set_string(DEVICE(&s->cpu), "cpu-type",
>> ARM_CPU_TYPE_NAME("cortex-m0"));
>> +    qdev_prop_set_uint32(DEVICE(&s->cpu), "num-irq", 96);
>
>
> Where did this number come from? ARMv6-M NVIC supports only 32 interrupts.

I think this was left over from when I was first creating a m0 based
system (efm32hg) over a year ago. Good catch.

I couldn't see a table of valid interrupts in the nrf51 datasheet. Are
you able to find this information?

If not, I will re-spin with the number of irqs set to 32.

Cheers,

Joel

  reply	other threads:[~2018-07-30 14:03 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-07-26  2:36 [Qemu-devel] [PATCH v3 0/3] arm: Add nRF51 SoC and micro:bit machine Joel Stanley
2018-07-26  2:36 ` [Qemu-devel] [PATCH v3 1/3] MAINTAINERS: Add NRF51 entry Joel Stanley
2018-07-26  2:36 ` [Qemu-devel] [PATCH v3 2/3] arm: Add Nordic Semiconductor nRF51 SoC Joel Stanley
2018-07-26 11:01   ` Julia Suvorova
2018-07-30 14:02     ` Joel Stanley [this message]
2018-08-02  9:42       ` Julia Suvorova
2018-07-26  2:36 ` [Qemu-devel] [PATCH v3 3/3] arm: Add BBC micro:bit machine Joel Stanley
2018-07-26  2:46 ` [Qemu-devel] [PATCH v3 0/3] arm: Add nRF51 SoC and " no-reply
2018-07-26  2:59 ` Fam Zheng
2018-07-26  3:04 ` no-reply

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=CACPK8XfYvU8+0s+FBGe7NuAst38ska0vpS8HVPWkM8OHyLFpdQ@mail.gmail.com \
    --to=joel@jms.id.au \
    --cc=contrib@steffen-goertz.de \
    --cc=jim.mussared@gmail.com \
    --cc=jusual@mail.ru \
    --cc=peter.maydell@linaro.org \
    --cc=qemu-arm@nongnu.org \
    --cc=qemu-devel@nongnu.org \
    --cc=stefanha@gmail.com \
    /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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.