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

[Xen-devel] RE: A question about PIT platform timer

  • To: "Keir Fraser" <keir@xxxxxxxxxxxxx>, <xen-devel@xxxxxxxxxxxxxxxxxxx>
  • From: "Tian, Kevin" <kevin.tian@xxxxxxxxx>
  • Date: Mon, 11 Dec 2006 20:10:23 +0800
  • Delivery-date: Mon, 11 Dec 2006 04:10:25 -0800
  • List-id: Xen developer discussion <xen-devel.lists.xensource.com>
  • Thread-index: AccdA44RYK8xaKWxSleokF0BH7qTYQABEEJ1AAU7KvA=
  • Thread-topic: A question about PIT platform timer

>From: Keir Fraser [mailto:keir@xxxxxxxxxxxxx]
>Sent: 2006年12月11日 17:36
>On 11/12/06 09:05, "Tian, Kevin" <kevin.tian@xxxxxxxxx> wrote:
>> Just note that pit_read_counter is implemented on top of CH2 of PIT,
>> which is known as mode 0 to calibrate TSC earlier. However I see no
>> place to re-initialize it again and it's used as the source of platform
>> timer count (when using_pit==1) immediately. It seems like weird
>> usage since mode0 channel will fall into a loop starting counting down
>> from 0xFFFF forever if nobody re-latches it again, which indicates a
>> 18.2065 Hz source while platform_timer_scale is set as
>> Seems ch0 is what's really wanted... Is it a typo, or any special usage
>> on ch2?
>We use it as a free-running globally-accessible counter of known
>We don't take interrupts from it (in fact we can't even if we wanted to as
>it's not wired up to an IRQ).
> -- Keir

Yes, there's no interrupt from it. But what's the known frequency? 
CALIBRATE_LATCH or CLOCK_TICK_RATE? platform_timer_scale 
is set to the later, and so ch2 needs to work on same frequency or 
else count value will result incorrect offset. However I didn't see such 
setting on ch2. Does I miss something? :-)


Xen-devel mailing list



Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.