qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
* [Qemu-devel] [RFC] armv7m_nvic
@ 2015-06-04 12:45 Liviu Ionescu
  2015-06-04 13:03 ` Peter Maydell
  0 siblings, 1 reply; 5+ messages in thread
From: Liviu Ionescu @ 2015-06-04 12:45 UTC (permalink / raw)
  To: qemu-devel; +Cc: Peter Maydell, Peter Crosthwaite, Alistair Francis

while working on the Cortex-M framework, I noticed that the current armv7m_nvic implementation is a bit old, and, to my opinion, not very fortunately structured.

first, it is named NVIC, but implements not only the NVIC registers, but some other register groups, like SysTick, system control, some IDs.

if the QEMU rule is to implement a physical contiguous memory space (0xE000E000 - 0xE000EFFF) in one file, then probably the file should be named armv7m_scb.c (System Control Block), and it must implement all registers.

the modular alternative (that I generally favour) would be to split the memory space into functional slices (SystemControl, SysTick, NVIC, CPUID, MPU, Debug, SW Triggers, MCUIDs) and implement them as separate objects, probably in separate files.


the changes that I might need in QEMU might also require some updates in the exception processing and might also affect NVIC, so if you have any comments on how the current structure should be improved, I'm open to suggestions.


regards,

Liviu

^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2015-06-04 22:14 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2015-06-04 12:45 [Qemu-devel] [RFC] armv7m_nvic Liviu Ionescu
2015-06-04 13:03 ` Peter Maydell
2015-06-04 18:17   ` Liviu Ionescu
2015-06-04 21:19     ` Peter Maydell
2015-06-04 22:14       ` Liviu Ionescu

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).