[Bug 30155] SafeDisc v2.05.030 fails due to driver dispatch routine status and irp.IoStatus.u.Status differing (Command & Conquer: Red Alert 2)

wine-bugs at winehq.org wine-bugs at winehq.org
Sun Mar 18 17:02:25 CDT 2018


https://bugs.winehq.org/show_bug.cgi?id=30155

--- Comment #12 from Anastasius Focht <focht at gmx.net> ---
Hello,

--- quote ---
Does the error still exist in wine 3.4?
--- quote ---

Wine's code has been reworked in recent years to match native Windows kernel
I/O manager behaviour more closely (I/O completion process and IRP result
delivery) but the problem is still present, yes.

I might take another shot at this driver in future, albeit low prio.
Not very fun to debug though.

--- snip ---
...
0030:Call
KERNEL32.DeviceIoControl(00000034,ef002407,009b2000,00000514,009b2514,00000c18,0033f324,00000000)
ret=003410d4 
...
0038:trace:ntoskrnl:dispatch_ioctl ioctl ef002407 device 0x11cd30 file 0x11ca40
in_size 4396 out_size 3096

0038:Call ntdll.RtlAllocateHeap(00110000,00000000,00000c18) ret=7ec1681f
0038:Ret  ntdll.RtlAllocateHeap() retval=0011b9e8 ret=7ec1681f

0038:trace:ntoskrnl:IoBuildDeviceIoControlRequest ef002407, 0x11cd30, 0x11cf00,
1300, 0x11b9e8, 3096, 0, (nil), (nil)
0038:trace:ntoskrnl:IoAllocateIrp 1, 0
0038:Call ntdll.RtlAllocateHeap(00110000,00000000,00000094) ret=7ec1921a
0038:Ret  ntdll.RtlAllocateHeap() retval=0011c608 ret=7ec1921a
0038:trace:ntoskrnl:ExAllocatePoolWithTag 148 pool 0 -> 0x11c608

0038:trace:ntoskrnl:IoInitializeIrp 0x11c608, 148, 1
0038:Call ntdll.RtlReAllocateHeap(00110000,00000010,0011cf00,00000514)
ret=7ec16944
0038:Ret  ntdll.RtlReAllocateHeap() retval=0011cf00 ret=7ec16944
0038:Call ntdll.NtGetTickCount() ret=7ec19b33
0038:Ret  ntdll.NtGetTickCount() retval=02349aba ret=7ec19b33

0038:Call driver dispatch 0x780402 (device=0x11cd30,irp=0x11c608)
irp->IoStatus.u.Status=00000000
...
0038:trace:ntoskrnl:__regs_IofCompleteRequest 0x11c608 0
0038:trace:ntoskrnl:IoCompleteRequest 0x11c608 0
irp->IoStatus.u.Status=c0000001
...
0038:trace:ntoskrnl:IoCompleteRequest calling 0x7ec15ea9( 0x11cd30, 0x11c608,
0x48 )
...
0038:trace:ntoskrnl:IoCompleteRequest CompletionRoutine returned 0,
irp->IoStatus.u.Status=c0000001

0030:Ret  KERNEL32.DeviceIoControl() retval=00000000 ret=003410d4 
...
--- snip ---

https://docs.microsoft.com/en-us/windows-hardware/drivers/kernel/different-ways-of-handling-irps-cheat-sheet

Even though the kernel driver doesn't follow the recommendation of matching
return status when completing the IRP in the dispatch routine, there has to be
a reason for irp.IoStatus.u.Status = 0xC0000001 (STATUS_UNSUCCESSFUL).

Regards

-- 
Do not reply to this email, post in Bugzilla using the
above URL to reply.
You are receiving this mail because:
You are watching all bug changes.



More information about the wine-bugs mailing list