#include <ntoskrnl.h>
#include <debug.h>
Go to the source code of this file.
◆ NDEBUG
◆ KiSwapProcess()
Definition at line 21 of file context.c.
23{
25#ifdef CONFIG_SMP
27
28
32#endif
33
34
35 if (NewProcess->LdtDescriptor.LimitLow != OldProcess->LdtDescriptor.LimitLow)
36 {
37 if (NewProcess->LdtDescriptor.LimitLow)
38 {
40 ((
PULONG)&NewProcess->LdtDescriptor)[0],
41 ((
PULONG)&NewProcess->LdtDescriptor)[1]);
42 Ke386SetLocalDescriptorTable(
KGDT_LDT);
43 }
44 else
45 {
46 Ke386SetLocalDescriptorTable(0);
47 }
48 }
49
50
52
53
54 Ke386SetGs(0);
55
56
57 Pcr->
TSS->IoMapBase = NewProcess->IopmOffset;
58}
__INTRIN_INLINE void __writecr3(unsigned int Data)
VOID KeSetGdtSelector(ULONG Entry, ULONG Value1, ULONG Value2)