summaryrefslogtreecommitdiffstats
path: root/usr.sbin/acpi/acpidump/acpi.c
diff options
context:
space:
mode:
authorpeter <peter@FreeBSD.org>2003-08-02 01:55:03 +0000
committerpeter <peter@FreeBSD.org>2003-08-02 01:55:03 +0000
commitfa1757a15668f4d9956dce95fa668920106bf312 (patch)
tree7d0aae876befd8b20821947c52e9841c80aa39c0 /usr.sbin/acpi/acpidump/acpi.c
parent844a52c0a0bc2f85fa3e515c235551e02a290ccf (diff)
downloadFreeBSD-src-fa1757a15668f4d9956dce95fa668920106bf312.zip
FreeBSD-src-fa1757a15668f4d9956dce95fa668920106bf312.tar.gz
Dump the HPET information block.
What is the HPET I hear you ask? It is the High Precision Event Timer that is supposed to supplement and eventually replace the 8254 timer and the RTC periodic interrupts. Among other things, it is 64 bit (can be run in 32 bit mode for 32 bit cpus), and is suitable as a replacement for the ACPI timer on SMP systems (the specs are much better) and as a replacement for the ITC based synthetic clock for on ia64 systems. It seems IA64 and AMD64 systems tend to have this. It is likely to start showing up in i386 systems if it isn't already on some of them.
Diffstat (limited to 'usr.sbin/acpi/acpidump/acpi.c')
-rw-r--r--usr.sbin/acpi/acpidump/acpi.c25
1 files changed, 25 insertions, 0 deletions
diff --git a/usr.sbin/acpi/acpidump/acpi.c b/usr.sbin/acpi/acpidump/acpi.c
index 97df172..18b8308 100644
--- a/usr.sbin/acpi/acpidump/acpi.c
+++ b/usr.sbin/acpi/acpidump/acpi.c
@@ -296,6 +296,29 @@ acpi_handle_apic(struct ACPIsdt *sdp)
}
static void
+acpi_handle_hpet(struct ACPIsdt *sdp)
+{
+ struct HPETbody *hpetp;
+
+ acpi_print_sdt(sdp);
+ hpetp = (struct HPETbody *) sdp->body;
+ printf(BEGIN_COMMENT);
+ printf("\tHPET Number=%d\n", hpetp->hpet_number);
+ printf("\tADDR=0x%08x\n", hpetp->base_addr);
+ printf("\tHW Rev=0x%x\n", hpetp->block_hwrev);
+ printf("\tComparitors=%d\n", hpetp->block_comparitors);
+ printf("\tCounter Size=%d\n", hpetp->block_counter_size);
+ printf("\tLegacy IRQ routing capable={");
+ if (hpetp->block_legacy_capable)
+ printf("TRUE}\n");
+ else
+ printf("FALSE}\n");
+ printf("\tPCI Vendor ID=0x%04x\n", hpetp->block_pcivendor);
+ printf("\tMinimul Tick=%d\n", hpetp->clock_tick);
+ printf(END_COMMENT);
+}
+
+static void
init_namespace()
{
struct aml_environ env;
@@ -522,6 +545,8 @@ acpi_handle_rsdt(struct ACPIsdt *rsdp)
acpi_handle_facp((struct FACPbody *) sdp->body);
} else if (!memcmp(sdp->signature, "APIC", 4)) {
acpi_handle_apic(sdp);
+ } else if (!memcmp(sdp->signature, "HPET", 4)) {
+ acpi_handle_hpet(sdp);
} else {
acpi_print_sdt(sdp);
}
OpenPOWER on IntegriCloud