- Enable stubs in kdcom to actually be exported (to simplfiy compatibility with KD Branch, which won't be needed soon thanks to a build flag).

- Enable call to KdDebuggerInitialize1 even in trunk, since it doesn't do anything.
- Make i8042prt stop using a reactos-only kernel export hack (KdpServiceDispatcher),and use KdSystemDebugControl instead, which is the NT version and fully-exported.
- Implement a stub KdSystemDebugControl and export it.

svn path=/trunk/; revision=25985
This commit is contained in:
Alex Ionescu 2007-03-04 19:20:03 +00:00
parent 12e7593f24
commit f7577eaeb7
5 changed files with 29 additions and 6 deletions

View file

@ -1,6 +1,7 @@
LIBRARY kdcom.dll
EXPORTS
; Old KD
KdPortGetByte@4
KdPortGetByteEx@8
KdPortInitialize@12
@ -13,3 +14,11 @@ KdPortRestore@0
KdPortSave@0
KdPortDisableInterrupts@0
KdPortEnableInterrupts@0
; New KD
KdDebuggerInitialize0@4
KdDebuggerInitialize1@4
KdSave@4
KdRestore@4
KdReceivePacket@20
KdSendPacket@16

View file

@ -12,6 +12,7 @@
/* INCLUDES ****************************************************************/
#include "i8042prt.h"
#include "kdfuncs.h"
#define NDEBUG
#include <debug.h>
@ -750,10 +751,6 @@ detectsetleds:
}
/* debug stuff */
VOID STDCALL
KdpServiceDispatcher(ULONG Code, PVOID Context1, PVOID Context2);
#define EnterDebugger ((PVOID)0x25)
static VOID STDCALL I8042DebugWorkItem(PDEVICE_OBJECT DeviceObject,
PVOID Context)
{
@ -771,6 +768,6 @@ static VOID STDCALL I8042DebugWorkItem(PDEVICE_OBJECT DeviceObject,
/* We hope kernel would understand this. If
* that's not the case, nothing would happen.
*/
KdpServiceDispatcher(TAG('R', 'o', 's', ' '), (PVOID)Key, NULL);
KdSystemDebugControl(TAG('R', 'o', 's', ' '), (PVOID)Key, 0, NULL, 0, NULL, KernelMode);
#endif /* __REACTOS__ */
}

View file

@ -1172,7 +1172,7 @@ Phase1InitializationDiscard(PVOID Context)
HalReportResourceUsage();
/* Call the debugger DLL once we have KD64 6.0 support */
//KdDebuggerInitialize1(LoaderBlock);
KdDebuggerInitialize1(LoaderBlock);
/* Setup PnP Manager in phase 1 */
if (!PpInitSystem()) KeBugCheck(PP1_INITIALIZATION_FAILED);
@ -1255,3 +1255,5 @@ Phase1Initialization(IN PVOID Context)
MmZeroPageThreadMain(NULL);
}

View file

@ -328,6 +328,20 @@ NtSetDebugFilterState(IN ULONG ComponentId,
return STATUS_SUCCESS;
}
NTSTATUS
NTAPI
KdSystemDebugControl(IN SYSDBG_COMMAND Command,
IN PVOID InputBuffer,
IN ULONG InputBufferLength,
OUT PVOID OutputBuffer,
IN ULONG OutputBufferLength,
IN OUT PULONG ReturnLength,
IN KPROCESSOR_MODE PreviousMode)
{
/* HACK */
return KdpServiceDispatcher(Command, InputBuffer, InputBufferLength);
}
PKDEBUG_ROUTINE KiDebugRoutine = KdpEnterDebuggerException;
/* EOF */

View file

@ -528,6 +528,7 @@ KdEnteredDebugger
KdPollBreakIn@0
KdPowerTransition@4
KdpServiceDispatcher@12
KdSystemDebugControl@28
Ke386CallBios@8
@KeAcquireGuardedMutex@4
@KeAcquireGuardedMutexUnsafe@4