]> xenbits.xensource.com Git - people/vhanquez/xen.git/commitdiff
x86, hpet: check hpet existence
authorKeir Fraser <keir.fraser@citrix.com>
Thu, 27 Nov 2008 13:09:16 +0000 (13:09 +0000)
committerKeir Fraser <keir.fraser@citrix.com>
Thu, 27 Nov 2008 13:09:16 +0000 (13:09 +0000)
Add check on hpet existence which is removed accidentally
in previous changeset (18790). Or else BAD PERIOD error can be seen.

Signed-off-by: Kevin Tian <kevin.tian@intel.com>
xen-unstable changeset:   18838:840b761e07c1f8b6146584df320ddbd6bce07fae
xen-unstable date:        Thu Nov 27 11:24:52 2008 +0000

xen/arch/x86/hpet.c

index 3d7129473dddc29f9080de60a08261a0a4578405..88a38699984ef41235318987ae5eb9c3687524f2 100644 (file)
@@ -275,6 +275,9 @@ u64 hpet_setup(void)
         return hpet_rate;
     system_reset_latch = system_reset_counter;
 
+    if ( hpet_address == 0 )
+        return 0;
+
     set_fixmap_nocache(FIX_HPET_BASE, hpet_address);
 
     hpet_id = hpet_read32(HPET_ID);