X-Git-Url: https://git.reactos.org/?p=reactos.git;a=blobdiff_plain;f=reactos%2Fhal%2Fhalx86%2Fgeneric%2Fprofil.c;h=b145942d9ab9b3d638c28e6a296588e8d66417a2;hp=53d653a0d1e2058938b9aa2d71e04307c10d9cbf;hb=8d574b3e5a267eb6b83d97f51b34acbf9d413ded;hpb=d59da19b08e81b8b4b65e11c8fc4819f0f761d73 diff --git a/reactos/hal/halx86/generic/profil.c b/reactos/hal/halx86/generic/profil.c index 53d653a0d1e..b145942d9ab 100644 --- a/reactos/hal/halx86/generic/profil.c +++ b/reactos/hal/halx86/generic/profil.c @@ -4,6 +4,7 @@ * FILE: hal/halx86/generic/profil.c * PURPOSE: System Profiling * PROGRAMMERS: Alex Ionescu (alex.ionescu@reactos.org) + * Eric Kohl */ /* INCLUDES ******************************************************************/ @@ -15,14 +16,28 @@ /* FUNCTIONS *****************************************************************/ /* - * @unimplemented + * @implemented */ VOID NTAPI HalStopProfileInterrupt(IN KPROFILE_SOURCE ProfileSource) { - UNIMPLEMENTED; - return; + UCHAR StatusB; + + /* Acquire the CMOS lock */ + HalpAcquireSystemHardwareSpinLock(); + + /* Read Status Register B */ + StatusB = HalpReadCmos(RTC_REGISTER_B); + + /* Disable periodic interrupts */ + StatusB = StatusB & ~RTC_REG_B_PI; + + /* Write new value into Status Register B */ + HalpWriteCmos(RTC_REGISTER_B, StatusB); + + /* Release the CMOS lock */ + HalpReleaseCmosSpinLock(); } /*