On MSVC implement _lgdt, __sgdt, __lldt, __sldt, __ltr and __str as assembly functions, because there is no inline assembly.
The MSVC/ML64 built kernel now boots and WinDbg connects.

svn path=/branches/ros-amd64-bringup/; revision=45433
This commit is contained in:
Timo Kreuzer
2010-02-05 03:05:51 +00:00
parent 2e6b7c8bf1
commit 046981b86f
2 changed files with 44 additions and 25 deletions
@@ -106,36 +106,17 @@ static __inline__ __attribute__((always_inline)) void __str(unsigned short *Dest
#define UNIMPLEMENTED DbgPrint("%s is unimplemented!!!\n", __FUNCTION__);
void FORCEINLINE __lgdt(void *Source)
{
UNIMPLEMENTED;
}
void __lgdt(void *Source);
void FORCEINLINE __sgdt(void *Destination)
{
UNIMPLEMENTED;
}
void __sgdt(void *Destination);
void FORCEINLINE __lldt(unsigned short Value)
{
UNIMPLEMENTED;
}
void __lldt(unsigned short Value);
void FORCEINLINE __sldt(void *Destination)
{
UNIMPLEMENTED;
}
void __sldt(void *Destination);
void FORCEINLINE __ltr(unsigned short Source)
{
UNIMPLEMENTED;
}
void FORCEINLINE __str(unsigned short *Destination)
{
UNIMPLEMENTED;
}
void __ltr(unsigned short Source);
void __str(unsigned short *Destination);
#else
+38
View File
@@ -905,6 +905,44 @@ PUBLIC KiUnexpectedInterrupt
jmp $
.ENDP KiUnexpectedInterrupt
#ifdef _MSC_VER
//void __lgdt(void *Source);
PUBLIC __lgdt
__lgdt:
lgdt fword ptr [rcx]
ret
//void __sgdt(void *Destination);
PUBLIC __sgdt
__sgdt:
sgdt fword ptr [rcx]
ret
// void __lldt(unsigned short Value)
PUBLIC __lldt
__lldt:
lldt cx
ret
//void __sldt(void *Destination);
PUBLIC __sldt
__sldt:
sldt word ptr [rcx]
ret
//void __ltr(unsigned short Source);
PUBLIC __ltr
__ltr:
ltr cx
ret
//void __str(unsigned short *Destination);
PUBLIC __str
__str:
str word ptr [rcx]
ret
#endif
END