TianoCore EDK2 master
Loading...
Searching...
No Matches
WriteMsr64.c
Go to the documentation of this file.
1
10
28UINT64
29EFIAPI
31 IN UINT32 Index,
32 IN UINT64 Value
33 )
34{
35 BOOLEAN Flag;
36
37 Flag = FilterBeforeMsrWrite (Index, &Value);
38 if (Flag) {
39 _asm {
40 mov edx, dword ptr [Value + 4]
41 mov eax, dword ptr [Value + 0]
42 mov ecx, Index
43 wrmsr
44 }
45 }
46
47 FilterAfterMsrWrite (Index, &Value);
48
49 return Value;
50}
UINT64 EFIAPI AsmWriteMsr64(IN UINT32 Index, IN UINT64 Value)
Definition: WriteMsr64.c:30
#define IN
Definition: Base.h:279
VOID EFIAPI FilterAfterMsrWrite(IN UINT32 Index, IN UINT64 *Value)
BOOLEAN EFIAPI FilterBeforeMsrWrite(IN UINT32 Index, IN UINT64 *Value)