Home | Info | Community | Development | myReactOS | Contact Us
ReactOS Development > Doxygeninline_ntcurrentteb.h
Go to the documentation of this file.
00001 #ifndef _INLINE_NT_CURRENTTEB_H_ 00002 #define _INLINE_NT_CURRENTTEB_H_ 00003 00004 #if defined(_M_IX86) 00005 FORCEINLINE struct _TEB * NtCurrentTeb(void) 00006 { 00007 return (struct _TEB *)__readfsdword(0x18); 00008 } 00009 #elif defined(_M_ARM) 00010 00011 // 00012 // NT-ARM is not documented 00013 // 00014 #include <armddk.h> 00015 00016 #elif defined(_M_AMD64) 00017 FORCEINLINE struct _TEB * NtCurrentTeb(void) 00018 { 00019 return (struct _TEB *)__readgsqword(FIELD_OFFSET(NT_TIB, Self)); 00020 } 00021 #elif defined(_M_PPC) 00022 FORCEINLINE struct _TEB * NtCurrentTeb(void) 00023 { 00024 return (struct _TEB *)__readfsdword_winnt(0x18); 00025 } 00026 #else 00027 #error Unsupported architecture 00028 #endif 00029 00030 #endif//_INLINE_NT_CURRENTTEB_H_ Generated on Fri May 25 2012 04:29:21 for ReactOS by
1.7.6.1
|