Sorry, this post is long.
I've successfully built a Windows CE 6.0 OS for my x86 "CEPC", and can
download it to my target successfully over ethernet. I can run my simple
"Hello World" applications on the target with no problem.
However, I have been able get the KITL debugger to work in "Polling Mode"
only. (To do that, I modified the kitl_x86.c file to add the
OAL_KITL_FLAGS_POLL to the pKitlArgs->flags setting in the
InitKitlEtherArgs() function.) If I try to use the default "Interrupt Mode"
(that is, without setting the _POLL flag), then my OS image will hang during
the booting stage, with a repeating sequence (every 8 seconds) of 16
ethernet UDP packets being sent from the target to the host, which never
seem to get acknowledged by PB. Each UDP packet's data payload starts with
"EDBG".
Here are the last several messages that are received over the serial
connection to the target:
= = = = = = = = =
<<<EARLIER MESSAGES SNIPPED>>>
EDBG:NE2000Init using I/O range at 0x00000300
EDBG:NE2000:HWRamTest: srambase: 0x00004000, sramsize: 0x00004000, pstart:
0x46
Ne2kDbg:: HWSetMCRegs():: Set all to 0x00
-EDBG:NE2000Init
x86KitlCreateName: Using Device Name 'CEPCLS53401'
OALKitlCreateName: Using Device Name 'CEPCLS53401'
KITL: *** Device Name CEPCLS53401 ***
KITL: using sysintr 0x1A
KITL: DHCP get/renew device IP: 1
VBridge:: built on [Sep 6 2006] time [19:21:34]
VBridgeInit()...TX = [16384] bytes -- Rx = [16384] bytes
Tx buffer [0xA0C18500] to [0xA0C1C500].
Rx buffer [0xA0C1C520] to [0xA0C20520].
VBridge:: NK add MAC: [0-40-5-6C-D0-99]
Connecting to Desktop
KITL: Connected host IP: 1 Port: 1419
KeyIndex 0 = -1
KeyIndex 1 = -1
KeyIndex 2 = -1
KeyIndex 3 = -1
KeyIndex 4 = -1
KeyIndex 5 = -4194305
KeyIndex 6 = -4194305
KeyIndex 7 = -1
+KITLRegisterDfltClient, service:0
+KITLRegisterDfltClient, service:1
Waiting for service 'DBGMSG' to connect..., fUseSysCalls = 0
ProcessAdminMsg: Receive Config message for service DBGMSG
ProcessAdminMsg: Receive Config message for service PPSH
ProcessAdminMsg: Receive Config message for service DBGMSG
!Received config for unrecognized service KDBG
ProcessAdminMsg: Receive Config message for service DBGMSG
ProcessAdminMsg: Receive Config message for service PPSH
!Received config for unrecognized service KDBG
!Received config for unrecognized service KDBG
+KITLRegisterDfltClient, service:2
ProcessAdminMsg: Receive Config message for service KDBG
ProcessAdminMsg: Receive Config message for service KDBG
KdpDeleteBreakpoint: Invalid handle
KdpDeleteBreakpoint: Invalid handle
<<<THE ABOVE MESSAGE REPEATS ABOUT 160 TIMES>>>
KITL: Leaving polling mode... 0x80C08060
KITL Checking client registrations
+RegisterClientPart2: Id 0x00000000
KITL Timer thread started, (hTh: 0x00520002, pTh: 0x83FE3C18)
Closing Handle of Timer Thread
-RegisterClientPart2 returns 1
+RegisterClientPart2: Id 0x00000001
-RegisterClientPart2 returns 1
KITL Creating IST
KITL Interrupt thread started (hTh: 0x005A0002, pTh: 0x83FC1414), using
SYSINTR 26
Enabling adapter ints...
Reserve KITL IRQ: No IRQ reserved, KITL NIC IRQ may be shared with other
devices.
0x680002 (0x102): KITLSend(0): Timed out waiting for ack (AckExpected: 74,
TxSeq: 90)
0x930002 (0x102): KITLSend(0): Timed out waiting for ack (AckExpected: 74,
TxSeq: 90)
0x680002 (0x102): KITLSend(0): Timed out waiting for ack (AckExpected: 74,
TxSeq: 90)
<<<THE ABOVE MESSAGE REPEATS FOREVER, ABOUT EVERY 10 SECONDS>>>
= = = = = = = =
And here are the last several lines of Debug Output text from the Visual
Studio window:
= = = = = = = =
<<<EARLIER MESSAGES SNIPPED>>>
4294767914 PID:400002 TID:680002 OSAXST1: >>> Loading Module 'romfsd.dll'
(0x83FA024C) at address 0xC01B0000-0xC01B6000 in Process 'NK.EXE'
(0x80C23C80)
4294767928 PID:400002 TID:680002 FSDMGR!MountTable_t::RegisterVolumeName:
Registered "ROM" at index 3
4294767929 PID:400002 TID:680002 FSDMGR!MountTable_t::RegisterVolume:
Registered volume at index 3 (Name="ROM", MountFlags=0x71)
4294767992 PID:400002 TID:680002 Succeeded on CheckFile
4294767993 PID:400002 TID:680002 RestoreFile(0x008f0003) called fDelete =
TRUE
4294768145 PID:400002 TID:680002 FSDMGR!STOREMGR_StartBootPhase BootPhase=0
(PrevBootPhase=-1)
4294768146 PID:400002 TID:680002 FSDMGR: File security disabled.
4294768147 PID:400002 TID:680002 FSDMGR!AutoLoadFileSystems:
CurrentBootPhase=0, LoadFlags=1
4294768148 PID:400002 TID:680002 FSDMGR!AutoLoadFileSystem:
CurrentBootPhase=0, RootKey=System\StorageManager\AutoLoad,
FileSystem_t=ObjectStore
4294768149 PID:400002 TID:680002 FILESYS: RAM File System FSD_MountDisk
registering folder "Object Store"
4294768150 PID:400002 TID:680002 FSDMGR!MountTable_t::RegisterVolumeName:
Registered "Object Store" at index 4
4294768150 PID:400002 TID:680002 FSDMGR!MountTable_t::RegisterVolume:
Registered volume at index 4 (Name="", MountFlags=0x46)
4294768152 PID:400002 TID:680002 PCIReg(key:
Drivers\BuiltIn\PCI\Instance\KITL, device: 0/3/0)
4294768175 PID:400002 TID:680002 Override Serial Driver: serial debug output
selected on COM port 1, disabling serial driver for that port.
4294768175 PID:400002 TID:680002 Override Serial Driver: No COM port
selected for serial KITL transport, no override necessary.
4294768176 PID:400002 TID:680002 FSDMGR!STOREMGR_StartBootPhase BootPhase=1
(PrevBootPhase=0)
4294768176 PID:400002 TID:680002 FSDMGR!AutoLoadFileSystems:
CurrentBootPhase=1, LoadFlags=1
<<<THE ABOVE MESSAGE IS THE LAST MESSAGE THAT APPEARS>>>
= = = = = = = =
I have confirmed that the Target>Connectivity Options>Kernel Service
Map>Debugger is set to KdStub, and the Download and Transport settings are
set to Ethernet.
Perhaps my target system has some KITL interrupt/IST issue, perhaps related
to SYSINTR 26? Or perhaps PB is hanging for some different reason, and it
stops acknowledging the packets sent by the target? I had read in other
postings that it could be an MTU size issue on my development workstation; I
haven't investigated this issue yet. But it's interesting that if I switch
to Polling Mode, everything starts up fine and I can execute my applications
on my CE target.
Has anyone seen this problem and then been able to get KITL working in
Interrupt Mode?
I can live with Polling Mode for now (in fact, I don't even know if
Interrupt Mode will improve the performance of my system, since I've never
seen it work before), but I wondered if anyone has found a fix for this
problem.
As always, any guidance is greatly appreciated!
David K