include vmm.inc VMMcall _GetDescriptor, <Selector, VM, flags> mov ecx, eax ; zero in eax and edx if error or ecx, edx jz error mov [DescDWORD1], edx ; high doubleword of descriptor mov [DescDWORD2], eax ; low doubleword of descriptor |
The _GetDescriptor service retrieves a copy of the descriptor associated with the given LDT or GDT selector.
Selector
Specifies a GDT or LDT selector.
VM
Specifies a handle identifying the virtual machine to which the specified LDT selector belongs. The service ignores this parameter if Selector is a GDT selector. Otherwise, the handle must be valid for LDT selectors.
flags
Specifies the operation flags. This parameter must be set to 0.
The EAX register contains the low doubleword of the descriptor, and the EDX register contain the high doubleword of the descriptor. Both EAX and EDX contain zero to indicate an error, such as an invalid selector or an invalid virtual machine handle.
This service ignores the high 16-bits of the Selector parameter; the 80386 CPU often sets these bits to random values when doubleword operations are performed on segment registers.
This service ignores the RPL bits of the selector.
EAX, EDX