Skip to content

Commit

Permalink
armv7m_nvic: fix AIRCR implementation
Browse files Browse the repository at this point in the history
The returned reset value was wrong (off by one zero nibble), and
qemu didn't log unimplemented writes to the PRIGROUP field.

Signed-off-by: Oran Avraham <oranav@gmail.com>
Message-id: 1403010447-4627-1-git-send-email-oranav@gmail.com
Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
  • Loading branch information
oranav authored and pm215 committed Jun 19, 2014
1 parent 0695573 commit b6fb3a8
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion hw/intc/armv7m_nvic.c
Expand Up @@ -211,7 +211,7 @@ static uint32_t nvic_readl(nvic_state *s, uint32_t offset)
cpu = ARM_CPU(current_cpu);
return cpu->env.v7m.vecbase;
case 0xd0c: /* Application Interrupt/Reset Control. */
return 0xfa05000;
return 0xfa050000;
case 0xd10: /* System Control. */
/* TODO: Implement SLEEPONEXIT. */
return 0;
Expand Down Expand Up @@ -346,6 +346,9 @@ static void nvic_writel(nvic_state *s, uint32_t offset, uint32_t value)
if (value & 5) {
qemu_log_mask(LOG_UNIMP, "AIRCR system reset unimplemented\n");
}
if (value & 0x700) {
qemu_log_mask(LOG_UNIMP, "PRIGROUP unimplemented\n");
}
}
break;
case 0xd10: /* System Control. */
Expand Down

0 comments on commit b6fb3a8

Please sign in to comment.