include vmm.inc
mov ebx, VMHandle
mov edi, ThreadHandle
mov edx, RefData
mov ebp, OFFSET32 Client_Reg_Struc
call [RestrictedEventCallback]
Performs programmer-defined processing of a restricted event for a virtual machine or thread. RestrictedEventCallback is a programmer-defined callback function installed by the Call_Restricted_Event service. The callback function can modify the EAX, EBX, ECX, EDX, ESI, EDI, and Flags registers. The callback function must return with interrupts enabled and the direction flag clear (up).
If a timeout occurs, any priority boost is automatically canceled, even if the PEF_Dont_Unboost flag was specified in the Call_Restricted_Event function that initiated the event.
If the PEF_Time_Out bit was set when the event was scheduled, additional information is given in the flags register, as described in Call_Restricted_Event. Such an event callback procedure should begin as follows:
mov hThisEvent, 0 ; (See 'Canceling Events')
; (Must preserve carry!)
jc Event_Timed_Out ; Carry set means event timed out
; Else event processed normally
For additional information about event callbacks, see Event Callbacks.
Call_Restricted_Event, Cancel_Restricted_Event, Client_Reg_Struc, Get_Cur_Thread_Handle, Get_Cur_VM_Handle