Implement HlLoadTaskRegister() for loading TSS segment selector into task register
All checks were successful
ci/woodpecker/push/build Pipeline was successful
All checks were successful
ci/woodpecker/push/build Pipeline was successful
This commit is contained in:
parent
9cbe2d458c
commit
f20ab3e52e
@ -59,6 +59,10 @@ VOID
|
|||||||
HlIoPortOutLong(IN USHORT Port,
|
HlIoPortOutLong(IN USHORT Port,
|
||||||
IN ULONG Value);
|
IN ULONG Value);
|
||||||
|
|
||||||
|
XTCDECL
|
||||||
|
VOID
|
||||||
|
HlLoadTaskRegister(USHORT Source);
|
||||||
|
|
||||||
XTCDECL
|
XTCDECL
|
||||||
ULONG_PTR
|
ULONG_PTR
|
||||||
HlReadControlRegister(IN USHORT ControlRegister);
|
HlReadControlRegister(IN USHORT ControlRegister);
|
||||||
|
@ -59,6 +59,10 @@ VOID
|
|||||||
HlIoPortOutLong(IN USHORT Port,
|
HlIoPortOutLong(IN USHORT Port,
|
||||||
IN ULONG Value);
|
IN ULONG Value);
|
||||||
|
|
||||||
|
XTCDECL
|
||||||
|
VOID
|
||||||
|
HlLoadTaskRegister(USHORT Source);
|
||||||
|
|
||||||
XTCDECL
|
XTCDECL
|
||||||
ULONG_PTR
|
ULONG_PTR
|
||||||
HlReadControlRegister(IN USHORT ControlRegister);
|
HlReadControlRegister(IN USHORT ControlRegister);
|
||||||
|
@ -236,6 +236,25 @@ HlIoPortOutLong(IN USHORT Port,
|
|||||||
"Nd" (Port));
|
"Nd" (Port));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Loads Task Register (TR) with a segment selector that points to TSS.
|
||||||
|
*
|
||||||
|
* @param Source
|
||||||
|
* Supplies the segment selector in the GDT describing the TSS.
|
||||||
|
*
|
||||||
|
* @return This routine does not return any value.
|
||||||
|
*
|
||||||
|
* @since XT 1.0
|
||||||
|
*/
|
||||||
|
XTCDECL
|
||||||
|
VOID
|
||||||
|
HlLoadTaskRegister(USHORT Source)
|
||||||
|
{
|
||||||
|
asm volatile("ltr %0"
|
||||||
|
:
|
||||||
|
: "rm" (Source));
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Reads the specified CPU control register and returns its value.
|
* Reads the specified CPU control register and returns its value.
|
||||||
*
|
*
|
||||||
|
@ -236,6 +236,25 @@ HlIoPortOutLong(IN USHORT Port,
|
|||||||
"Nd" (Port));
|
"Nd" (Port));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Loads Task Register (TR) with a segment selector that points to TSS.
|
||||||
|
*
|
||||||
|
* @param Source
|
||||||
|
* Supplies the segment selector in the GDT describing the TSS.
|
||||||
|
*
|
||||||
|
* @return This routine does not return any value.
|
||||||
|
*
|
||||||
|
* @since XT 1.0
|
||||||
|
*/
|
||||||
|
XTCDECL
|
||||||
|
VOID
|
||||||
|
HlLoadTaskRegister(USHORT Source)
|
||||||
|
{
|
||||||
|
asm volatile("ltr %0"
|
||||||
|
:
|
||||||
|
: "rm" (Source));
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Reads the specified CPU control register and returns its value.
|
* Reads the specified CPU control register and returns its value.
|
||||||
*
|
*
|
||||||
|
Loading…
Reference in New Issue
Block a user