[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Qemu-discuss] system_clock_scale unset in hw/intc/armv7m_nvic.c

From: Jakob Bohm
Subject: Re: [Qemu-discuss] system_clock_scale unset in hw/intc/armv7m_nvic.c
Date: Fri, 13 Jan 2017 14:05:09 +0100
User-agent: Mozilla/5.0 (Windows NT 6.3; WOW64; rv:45.0) Gecko/20100101 Thunderbird/45.6.0

On 13/01/2017 13:43, Peter Maydell wrote:
On 13 January 2017 at 12:35, James Hanley <address@hidden> wrote:
How should system_clock_scale be set in hw/intc/armv7m_nvic.c - there is no
API for the global, and I've defaulted the global to SYSTICK_SCALE which
seems to work, but is not obvious.  This was needed as this value was set to
zero and the arm firmware was selecting the external clock source causing
zero to be returned from systick_scale() and the interrupt to run
If I recall correctly, this is an external-to-the-CPU thing
(wired up by the SoC or the board), which suggests that it
ought to be a property on the CPU object (or perhaps on a
currently-nonexistent container object which has the CPU
and the NVIC and the other M profile devices).
If you are going to add this in the future, I would suggest making it
a settable "board" property, since most "boards" are really just
families of somewhat similar SoC chips, and this frequency might thus
(on real hardware) vary even more easily than e.g. the size of the
available RAM.

As the code stands today, I think the answer is that the
board has to set the global -- this is what stellaris.c does.


Jakob Bohm, CIO, Partner, WiseMo A/S.  https://www.wisemo.com
Transformervej 29, 2860 Søborg, Denmark.  Direct +45 31 13 16 10
This public discussion message is non-binding and may contain errors.
WiseMo - Remote Service Management for PCs, Phones and Embedded

reply via email to

[Prev in Thread] Current Thread [Next in Thread]