Visit Jeremy's Blog.
Go Back > Forums > Linux Forums > Linux - Software > Linux - Kernel
User Name
Linux - Kernel This forum is for all discussion relating to the Linux kernel.


  Search this Thread
Old 11-19-2006, 07:36 AM   #1
LQ Newbie
Registered: Oct 2005
Posts: 14

Rep: Reputation: 10
HPET example


I am looking for a replacement of the RDTSC instruction as it is no longer useful on the newer multi-core and power-saving CPU's.
The High Precision Event Timer (HPET) seems to a suitable candidate, but I cannot find good coumentation on how to use the API.
I have found an example C program in the kernel documentation, but it does tell how to use it. You have to specify a device name, but which? I have a '/dev/hpet' device on Fedora Core 6, but open() fails on it.

How can you find out if the BIOS supports HPET?
Where can I find good documentation or an example program that shows how to get a RDTSC counter using HPET?

Old 11-19-2006, 08:27 AM   #2
LQ Guru
Registered: Aug 2001
Location: Fargo, ND
Distribution: SuSE AMD64
Posts: 15,733

Rep: Reputation: 671Reputation: 671Reputation: 671Reputation: 671Reputation: 671Reputation: 671
There is an hpet.txt file in the kernel source Documentation. Also, the hpet.c source refers to documentation at the intel site:

A search on the Intel site shows up informaton as well, like this Q&A:

This is probably old information to you. Here is some background information from Microsoft. Interestingly, XP doesn't offer support. Vista will.

It sounds like a hpet timer is detected during bootup using acpi. However, some bioses don't support it. Others like in a Dell Xeon server support it but have it disabled by default in the BIOS settings.


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off

Similar Threads
Thread Thread Starter Forum Replies Last Post
Using hpet for high-res timesource Rian8605 Linux - Software 3 02-20-2006 05:50 PM
Using hpet for high-res timesource Rian8605 Linux - Newbie 6 02-18-2006 11:17 PM
Using hpet for high-res timesource Rian8605 Linux - General 1 02-18-2006 04:35 PM > Forums > Linux Forums > Linux - Software > Linux - Kernel

All times are GMT -5. The time now is 11:05 AM.

Main Menu
Write for LQ is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration