From: Keir Fraser Date: Thu, 27 Nov 2008 11:24:52 +0000 (+0000) Subject: x86, hpet: check hpet existence X-Git-Tag: archive/raspbian/4.8.0-1+rpi1~1^2~14040^2~20 X-Git-Url: https://dgit.raspbian.org/?a=commitdiff_plain;h=c44f6b31725b2142e963536ff0bd6ebcbfea2161;p=xen.git x86, hpet: check hpet existence 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 --- diff --git a/xen/arch/x86/hpet.c b/xen/arch/x86/hpet.c index d5e84f4ccd..f82221bbe2 100644 --- a/xen/arch/x86/hpet.c +++ b/xen/arch/x86/hpet.c @@ -273,6 +273,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);