diff options
| author | Peter Maydell <peter.maydell@linaro.org> | 2018-02-15 18:29:37 +0000 |
|---|---|---|
| committer | Peter Maydell <peter.maydell@linaro.org> | 2018-02-15 18:29:49 +0000 |
| commit | 12fbf1a1639ed916fda948718dac0d30b82b954e (patch) | |
| tree | 25d440384ef4fe9f5d3d3f9d34f84d701f769635 /hw/misc/macio/cuda.c | |
| parent | 6eb3a64e2a96f5ced1f7896042b01f002bf0a91f (diff) | |
| download | focaccia-qemu-12fbf1a1639ed916fda948718dac0d30b82b954e.tar.gz focaccia-qemu-12fbf1a1639ed916fda948718dac0d30b82b954e.zip | |
hw/intc/armv7m_nvic: Fix byte-to-interrupt number conversions
In many of the NVIC registers relating to interrupts, we have to convert from a byte offset within a register set into the number of the first interrupt which is affected. We were getting this wrong for: * reads of NVIC_ISPR<n>, NVIC_ISER<n>, NVIC_ICPR<n>, NVIC_ICER<n>, NVIC_IABR<n> -- in all these cases we were missing the "* 8" needed to convert from the byte offset to the interrupt number (since all these registers use one bit per interrupt) * writes of NVIC_IPR<n> had the opposite problem of a spurious "* 8" (since these registers use one byte per interrupt) Signed-off-by: Peter Maydell <peter.maydell@linaro.org> Reviewed-by: Philippe Mathieu-Daudé <f4bug@amsat.org> Message-id: 20180209165810.6668-9-peter.maydell@linaro.org
Diffstat (limited to 'hw/misc/macio/cuda.c')
0 files changed, 0 insertions, 0 deletions