|Subject:||Re: [Qemu-arm] Adding sp804 timer to the virtboard|
|Date:||Fri, 5 Feb 2016 12:04:40 -0500|
On 5 February 2016 at 10:52, Peter Maydell <address@hidden> wrote:
> On 3 February 2016 at 20:57, Jintack Lim <address@hidden> wrote:
>> About the clock property, should I also add the original clock providers
>> such as sp810 and in turn 32k, 1M and smb clocks?
>> Or canI just use apb-pclk, which is an existing clock provider in the
>> virtboard, for all three clocks?
> For a virtual machine the clocks are all irrelevant anyway, I think
> (we don't actually have any kind of 24MHz clock) -- we just provide
> them because the kernel insists that the dtb says something about
> clocks. So I would start by just borrowing the apb-pclk and seeing
> if that works.
Having said that I looked at the code a bit more closely and I think
it's not quite right. By default the sp804 device will have a 1MHz
clock. So you should probably arrange to tell the kernel that via
the device tree, or it will think the clock is running at a different
speed from what it really is. (Or you could set the freq0 and freq1
qdev properties on the device to make it clock at the rate your dt
says it clocks at, but 24MHz would probably mean a lot of overhead
with timer firing.)
|[Prev in Thread]||Current Thread||[Next in Thread]|