Author: fireball Date: Mon Jun 2 05:21:49 2008 New Revision: 33825
URL: http://svn.reactos.org/svn/reactos?rev=33825&view=rev Log: Stefan Ginsberg stefan__100__@hotmail.com - Remove ExTryToAcquireResourceExclusiveLite from NDK since it's not exported by NT kernel. - Add ObSetSecurityObjectByPointer, RtlInitAnsiStringEx (and implement it, rather straightforward) to NDK. - Uncomment exports in ntoskrnl_i386.def which are already implemented. - Add KeInvalidateAllCaches to ARM's stubs.
Modified: trunk/reactos/include/ndk/exfuncs.h trunk/reactos/include/ndk/obfuncs.h trunk/reactos/include/ndk/rtlfuncs.h trunk/reactos/lib/rtl/unicode.c trunk/reactos/ntoskrnl/include/internal/ex.h trunk/reactos/ntoskrnl/ke/arm/stubs_asm.s trunk/reactos/ntoskrnl/ntoskrnl_i386.def
Modified: trunk/reactos/include/ndk/exfuncs.h URL: http://svn.reactos.org/svn/reactos/trunk/reactos/include/ndk/exfuncs.h?rev=3... ============================================================================== --- trunk/reactos/include/ndk/exfuncs.h [iso-8859-1] (original) +++ trunk/reactos/include/ndk/exfuncs.h [iso-8859-1] Mon Jun 2 05:21:49 2008 @@ -94,16 +94,6 @@ ExfUnblockPushLock( PEX_PUSH_LOCK PushLock, PVOID CurrentWaitBlock -); - -// -// Resource Functions -// -NTKERNELAPI -BOOLEAN -NTAPI -ExTryToAcquireResourceExclusiveLite( - IN PERESOURCE Resource );
//
Modified: trunk/reactos/include/ndk/obfuncs.h URL: http://svn.reactos.org/svn/reactos/trunk/reactos/include/ndk/obfuncs.h?rev=3... ============================================================================== --- trunk/reactos/include/ndk/obfuncs.h [iso-8859-1] (original) +++ trunk/reactos/include/ndk/obfuncs.h [iso-8859-1] Mon Jun 2 05:21:49 2008 @@ -109,6 +109,15 @@ );
NTKERNELAPI +NTSTATUS +NTAPI +ObSetSecurityObjectByPointer( + IN PVOID Object, + IN SECURITY_INFORMATION SecurityInformation, + IN PSECURITY_DESCRIPTOR SecurityDescriptor +); + +NTKERNELAPI BOOLEAN NTAPI ObFindHandleForObject(
Modified: trunk/reactos/include/ndk/rtlfuncs.h URL: http://svn.reactos.org/svn/reactos/trunk/reactos/include/ndk/rtlfuncs.h?rev=... ============================================================================== --- trunk/reactos/include/ndk/rtlfuncs.h [iso-8859-1] (original) +++ trunk/reactos/include/ndk/rtlfuncs.h [iso-8859-1] Mon Jun 2 05:21:49 2008 @@ -1628,8 +1628,6 @@ IN BOOLEAN AllocateDestinationString );
-#endif - NTSYSAPI NTSTATUS NTAPI @@ -1638,6 +1636,8 @@ IN PCUNICODE_STRING SourceString, OUT PUNICODE_STRING DestinationString ); + +#endif
NTSYSAPI BOOLEAN @@ -1754,6 +1754,14 @@ VOID NTAPI RtlInitAnsiString( + PANSI_STRING DestinationString, + PCSZ SourceString +); + +NTSYSAPI +NTSTATUS +NTAPI +RtlInitAnsiStringEx( PANSI_STRING DestinationString, PCSZ SourceString );
Modified: trunk/reactos/lib/rtl/unicode.c URL: http://svn.reactos.org/svn/reactos/trunk/reactos/lib/rtl/unicode.c?rev=33825... ============================================================================== --- trunk/reactos/lib/rtl/unicode.c [iso-8859-1] (original) +++ trunk/reactos/lib/rtl/unicode.c [iso-8859-1] Mon Jun 2 05:21:49 2008 @@ -432,6 +432,30 @@ DestinationString->Buffer = (PCHAR)SourceString; }
+NTSTATUS +NTAPI +RtlInitAnsiStringEx(IN OUT PANSI_STRING DestinationString, + IN PCSZ SourceString) +{ + ULONG DestSize; + + if(SourceString) + { + DestSize = strlen(SourceString); + if (DestSize >= 0xFFFF) return STATUS_NAME_TOO_LONG; + DestinationString->Length = (USHORT)DestSize; + DestinationString->MaximumLength = (USHORT)DestSize + sizeof(CHAR); + } + else + { + DestinationString->Length = 0; + DestinationString->MaximumLength = 0; + } + + DestinationString->Buffer = (PCHAR)SourceString; + return STATUS_SUCCESS; + +} /* * @implemented *
Modified: trunk/reactos/ntoskrnl/include/internal/ex.h URL: http://svn.reactos.org/svn/reactos/trunk/reactos/ntoskrnl/include/internal/e... ============================================================================== --- trunk/reactos/ntoskrnl/include/internal/ex.h [iso-8859-1] (original) +++ trunk/reactos/ntoskrnl/include/internal/ex.h [iso-8859-1] Mon Jun 2 05:21:49 2008 @@ -1001,6 +1001,12 @@
/* OTHER FUNCTIONS **********************************************************/
+BOOLEAN +NTAPI +ExTryToAcquireResourceExclusiveLite( + IN PERESOURCE Resource +); + LONGLONG FASTCALL ExfpInterlockedExchange64(
Modified: trunk/reactos/ntoskrnl/ke/arm/stubs_asm.s URL: http://svn.reactos.org/svn/reactos/trunk/reactos/ntoskrnl/ke/arm/stubs_asm.s... ============================================================================== --- trunk/reactos/ntoskrnl/ke/arm/stubs_asm.s [iso-8859-1] (original) +++ trunk/reactos/ntoskrnl/ke/arm/stubs_asm.s [iso-8859-1] Mon Jun 2 05:21:49 2008 @@ -21,6 +21,7 @@ GENERATE_ARM_STUB KeGetRecommendedSharedDataAlignment GENERATE_ARM_STUB KeIcacheFlushCount GENERATE_ARM_STUB KeInitializeInterrupt +GENERATE_ARM_STUB KeInvalidateAllCaches GENERATE_ARM_STUB KeNumberProcessors GENERATE_ARM_STUB KeQueryActiveProcessors GENERATE_ARM_STUB KeRaiseUserException
Modified: trunk/reactos/ntoskrnl/ntoskrnl_i386.def URL: http://svn.reactos.org/svn/reactos/trunk/reactos/ntoskrnl/ntoskrnl_i386.def?... ============================================================================== --- trunk/reactos/ntoskrnl/ntoskrnl_i386.def [iso-8859-1] (original) +++ trunk/reactos/ntoskrnl/ntoskrnl_i386.def [iso-8859-1] Mon Jun 2 05:21:49 2008 @@ -82,7 +82,7 @@ ExDesktopObjectType ExDisableResourceBoostLite@4 @ExEnterCriticalRegionAndAcquireFastMutexUnsafe@4 -;ExEnterCriticalRegionAndAcquireResourceExclusive +ExEnterCriticalRegionAndAcquireResourceExclusive@4 ;ExEnterCriticalRegionAndAcquireResourceShared ;ExEnterCriticalRegionAndAcquireSharedWaitForExclusive ExEnumHandleTable@16 @@ -137,7 +137,7 @@ ExReinitializeResourceLite@4 @ExReleaseFastMutexUnsafe@4 @ExReleaseFastMutexUnsafeAndLeaveCriticalRegion@4 -;ExReleaseResourceAndLeaveCriticalRegion +@ExReleaseResourceAndLeaveCriticalRegion@4 ExReleaseResourceForThreadLite@8 @ExReleaseResourceLite@4 ExReleaseRundownProtection=@ExfReleaseRundownProtection@4 @@ -158,8 +158,8 @@ ExWaitForRundownProtectionRelease=@ExfWaitForRundownProtectionRelease@4 ExWaitForRundownProtectionReleaseCacheAware=@ExfWaitForRundownProtectionReleaseCacheAware@4 ExWindowStationObjectType DATA -;ExfAcquirePushLockExclusive -;ExfAcquirePushLockShared +@ExfAcquirePushLockExclusive@4 +@ExfAcquirePushLockShared@4 @ExfInterlockedAddUlong@12 @ExfInterlockedCompareExchange64@12 @ExfInterlockedInsertHeadList@12 @@ -167,11 +167,11 @@ @ExfInterlockedPopEntryList@8 @ExfInterlockedPushEntryList@12 @ExfInterlockedRemoveHeadList@8 -;ExfReleasePushLock -;ExfReleasePushLockExclusive -;ExfReleasePushLockShared -;ExfTryToWakePushLock -;ExfUnblockPushLock +@ExfReleasePushLock@4 +@ExfReleasePushLockExclusive@4 +@ExfReleasePushLockShared@4 +@ExfTryToWakePushLock@4 +@ExfUnblockPushLock@8 @Exfi386InterlockedDecrementLong@4 @Exfi386InterlockedExchangeUlong@8 @Exfi386InterlockedIncrementLong@4 @@ -199,7 +199,7 @@ FsRtlCheckOplock FsRtlCopyRead FsRtlCopyWrite -;FsRtlCreateSectionForDataScan +FsRtlCreateSectionForDataScan@40 FsRtlCurrentBatchOplock FsRtlDeleteKeyFromTunnelCache FsRtlDeleteTunnelCache @@ -549,7 +549,7 @@ KeAcquireSpinLockAtDpcLevel@4 ;KeAcquireSpinLockForDpc KeAddSystemServiceTable@20 -;KeAreAllApcsDisabled +KeAreAllApcsDisabled@0 KeAreApcsDisabled@0 KeAttachProcess@4 KeBugCheck@4 @@ -606,8 +606,8 @@ KeInsertQueue@8 KeInsertQueueApc@16 KeInsertQueueDpc@12 -;KeInvalidateAllCaches -;KeIpiGenericCall +KeInvalidateAllCaches@0 +KeIpiGenericCall@8 KeIsAttachedProcess@0 KeIsExecutingDpc@0 ;KeIsWaitListEmpty @@ -682,7 +682,7 @@ ;KeTestSpinLock KeTickCount DATA @KeTryToAcquireGuardedMutex@4 -;KeTryToAcquireSpinLockAtDpcLevel +@KeTryToAcquireSpinLockAtDpcLevel@4 KeUnstackDetachProcess@4 KeUpdateRunTime@4 KeUpdateSystemTime@0 @@ -888,11 +888,11 @@ ObReferenceObjectByHandle@24 ObReferenceObjectByName@32 ObReferenceObjectByPointer@16 -;ObReferenceSecurityDescriptor@8 +ObReferenceSecurityDescriptor@8 ObReleaseObjectSecurity@8 ;ObSetHandleAttributes@12 -;ObSetSecurityDescriptorInfo@24 -;ObSetSecurityObjectByPointer@12 +ObSetSecurityDescriptorInfo@24 +ObSetSecurityObjectByPointer@12 @ObfDereferenceObject@4 @ObfReferenceObject@4 ;PfxFindPrefix @@ -974,7 +974,7 @@ PsImpersonateClient@20 PsInitialSystemProcess DATA PsIsProcessBeingDebugged@4 -;PsIsSystempProcess +;PsIsSystemProcess PsIsSystemThread@4 PsIsThreadImpersonating@4 PsIsThreadTerminating@4 @@ -1018,7 +1018,7 @@ KeRosDumpStackFrames@8 RtlAbsoluteToSelfRelativeSD@12 RtlAddAccessAllowedAce@16 -;RtlAddAccessAllowedAceEx +RtlAddAccessAllowedAceEx@20 RtlAddAce@20 RtlAddAtomToAtomTable@12 RtlAddRange@36 @@ -1140,11 +1140,11 @@ RtlImageDirectoryEntryToData@16 RtlImageNtHeader@4 RtlInitAnsiString@8 -;RtlInitAnsiStringEx +RtlInitAnsiStringEx@8 RtlInitCodePageTable@8 RtlInitString@8 RtlInitUnicodeString@8 -;RtlInitUnicodeStringEx +RtlInitUnicodeStringEx@8 RtlInitializeBitMap@12 RtlInitializeGenericTable@20 RtlInitializeGenericTableAvl@20