Windows Driver: correctly save and restore extended processor state when performing AVX operations on Windows 7 and later. Enhance readability of code handling save/restore of floating point state.

This commit is contained in:
Mounir IDRASSI committed 2017-07-04 02:26:24 +02:00
1 parent c2f6190627
commit 89efcdb8cd
8 files changed
+201 -39

No files matched your search

+20
View File
@@ -260,6 +260,26 @@ typedef int BOOL;
#define FALSE !TRUE
#endif
typedef NTSTATUS (NTAPI *KeSaveExtendedProcessorStateFn) (
__in ULONG64 Mask,
PXSTATE_SAVE XStateSave
);
typedef VOID (NTAPI *KeRestoreExtendedProcessorStateFn) (
PXSTATE_SAVE XStateSave
);
extern NTSTATUS NTAPI KeSaveExtendedProcessorState (
__in ULONG64 Mask,
PXSTATE_SAVE XStateSave
);
extern VOID NTAPI KeRestoreExtendedProcessorState (
PXSTATE_SAVE XStateSave
);
#else /* !TC_WINDOWS_DRIVER */
#if !defined(_UEFI)
#define TCalloc malloc