Implement ArReadFSDualWord() routine

Tento commit je obsažen v:
2023-02-07 23:19:22 +01:00
rodič 75c519a70c
revize a32e18b237
2 změnil soubory, kde provedl 25 přidání a 0 odebrání

Zobrazit soubor

@@ -270,6 +270,27 @@ ArReadControlRegister(IN USHORT ControlRegister)
return Value;
}
/**
* Reads dualword from a memory location specified by an offset relative to the beginning of the FS segment.
*
* @param Offset
* Specifies the offset from the beginning of FS segment.
*
* @return Returns the value read from the specified memory location relative to FS segment.
*
* @since XT 1.0
*/
XTCDECL
ULONG
ArReadFSDualWord(ULONG Offset)
{
ULONG Value;
asm volatile("movl %%fs:%a[Offset], %k[Value]"
: [Value] "=r" (Value)
: [Offset] "ir" (Offset));
return Value;
}
/**
* Reads a 64-bit value from the requested Model Specific Register (MSR).
*