Wine and serial port again

Open forum for end-user questions about Wine. Before asking questions, check out the Wiki as a first step.
Forum Rules
Locked
gladov
Newbie
Newbie
Posts: 4
Joined: Fri Jun 19, 2009 6:43 am

Wine and serial port again

Post by gladov »

Hi all!

I have a very special device connected to my serial port and want to execute a Win32 program to work with the device. I trying to execute it with wine 1.0.1 form debian package. Win32 software starts and says that can not find a device. Under VirtualBox it works fine. This is a part of log with +file,+comm debug flags:

Code: Select all

trace:file:get_dos_device L"COM1" -> "/home/oleg/.wine/dosdevices/com1"
trace:file:get_dos_device L"COM2" -> "/dev/ttyS1"
trace:file:get_dos_device L"COM3" -> "/dev/ttyS2"
trace:file:get_dos_device L"COM4" -> "/dev/ttyS3"
trace:file:wine_nt_to_unix_file_name L"\\??\\c:\\" -> "/home/oleg/.wine/dosdevices/c:/"
trace:file:wine_nt_to_unix_file_name L"\\??\\d:\\" -> "/home/oleg/.wine/dosdevices/d:/"
trace:file:wine_nt_to_unix_file_name L"\\??\\z:\\" -> "/home/oleg/.wine/dosdevices/z:/"
trace:file:CreateFileW L"\\\\.\\COM1" GENERIC_READ GENERIC_WRITE  creation 3 attributes 0x0
trace:file:RtlDosPathNameToNtPathName_U (L"\\\\.\\COM1",0x32e894,(nil),(nil))
trace:file:RtlGetFullPathName_U (L"\\\\.\\COM1" 520 0x32e608 (nil))
attr=00000000 sharing=00000000 disp=1 options=00000050 ea=(nil).0x00000000
trace:file:get_dos_device L"COM1" -> "/home/oleg/.wine/dosdevices/com1"
trace:file:CreateFileW returning 0xdc
trace:comm:SetCommMask handle 0xdc, mask 1
trace:comm:io_control 0xdc IOCTL_SERIAL_SET_WAIT_MASK 0x32e8fc 4 (nil) 0 0x32e8a8
trace:comm:io_control 0xdc IOCTL_SERIAL_SET_QUEUE_SIZE 0x32e8e0 8 (nil) 0 0x32e894
fixme:comm:set_queue_size insize 1024 outsize 2048 unimplemented stub
trace:comm:SetCommTimeouts (0xdc, 0x32e914)
trace:comm:io_control 0xdc IOCTL_SERIAL_SET_TIMEOUTS 0x32e8d0 20 (nil) 0 0x32e878
trace:comm:GetCommState handle 0xdc, ptr 0xe05a04
trace:comm:io_control 0xdc IOCTL_SERIAL_GET_BAUD_RATE (nil) 0 0x32e8dc 4 0x32e878
trace:comm:io_control 0xdc IOCTL_SERIAL_GET_LINE_CONTROL (nil) 0 0x32e8e1 3 0x32e878
trace:comm:io_control 0xdc IOCTL_SERIAL_GET_HANDFLOW (nil) 0 0x32e8c4 16 0x32e878
trace:comm:io_control 0xdc IOCTL_SERIAL_GET_CHARS (nil) 0 0x32e8d6 6 0x32e878
trace:comm:GetCommState OK
trace:comm:dump_dcb bytesize=8 baudrate=9600 fParity=0 Parity=0 stopbits=1
trace:comm:dump_dcb ~IXON IXOFF
trace:comm:dump_dcb fOutxCtsFlow=0 fRtsControl=1
trace:comm:dump_dcb fOutxDsrFlow=0 fDtrControl=1
trace:comm:dump_dcb ~CRTSCTS
trace:comm:dump_dcb bytesize=8 baudrate=115200 fParity=0 Parity=0 stopbits=2
trace:comm:dump_dcb ~IXON ~IXOFF
trace:comm:dump_dcb fOutxCtsFlow=0 fRtsControl=1
trace:comm:dump_dcb fOutxDsrFlow=0 fDtrControl=1
trace:comm:dump_dcb ~CRTSCTS
trace:comm:io_control 0xdc IOCTL_SERIAL_SET_BAUD_RATE 0x32e8e0 4 (nil) 0 0x32e888
trace:comm:io_control 0xdc IOCTL_SERIAL_SET_LINE_CONTROL 0x32e8e5 3 (nil) 0 0x32e888
trace:comm:io_control 0xdc IOCTL_SERIAL_SET_HANDFLOW 0x32e8c8 16 (nil) 0 0x32e888
trace:comm:io_control 0xdc IOCTL_SERIAL_SET_CHARS 0x32e8da 6 (nil) 0 0x32e888
trace:comm:io_control 0xdc IOCTL_SERIAL_GET_COMMSTATUS (nil) 0 0x32e63c 20 0x32e5e4
trace:file:WriteFile 0xdc 0x32e6a8 132 0x32e68c (nil)
trace:comm:io_control 0xdc IOCTL_SERIAL_GET_COMMSTATUS (nil) 0 0x32e63c 20 0x32e5e4
trace:comm:io_control 0xdc IOCTL_SERIAL_GET_COMMSTATUS (nil) 0 0x32e63c 20 0x32e5e4
trace:comm:io_control 0xdc IOCTL_SERIAL_GET_COMMSTATUS (nil) 0 0x32e63c 20 0x32e5e4
trace:file:ReadFile 0xdc 0x32e734 1 0x32e694 (nil)
trace:comm:io_control 0xdc IOCTL_SERIAL_GET_COMMSTATUS (nil) 0 0x32e63c 20 0x32e5e4
trace:file:ReadFile 0xdc 0x32e734 1 0x32e694 (nil)
trace:comm:io_control 0xdc IOCTL_SERIAL_GET_COMMSTATUS (nil) 0 0x32e63c 20 0x32e5e4
trace:file:WriteFile 0xdc 0x32e6a8 132 0x32e68c (nil)
trace:comm:io_control 0xdc IOCTL_SERIAL_GET_COMMSTATUS (nil) 0 0x32e63c 20 0x32e5e4
trace:comm:io_control 0xdc IOCTL_SERIAL_GET_COMMSTATUS (nil) 0 0x32e63c 20 0x32e5e4
trace:file:ReadFile 0xdc 0x32e734 1 0x32e694 (nil)
trace:comm:io_control 0xdc IOCTL_SERIAL_GET_COMMSTATUS (nil) 0 0x32e63c 20 0x32e5e4
trace:file:ReadFile 0xdc 0x32e734 1 0x32e694 (nil)
trace:comm:io_control 0xdc IOCTL_SERIAL_GET_COMMSTATUS (nil) 0 0x32e63c 20 0x32e5e4
trace:file:WriteFile 0xdc 0x32e6a8 132 0x32e68c (nil)
trace:comm:io_control 0xdc IOCTL_SERIAL_GET_COMMSTATUS (nil) 0 0x32e63c 20 0x32e5e4
trace:comm:io_control 0xdc IOCTL_SERIAL_GET_COMMSTATUS (nil) 0 0x32e63c 20 0x32e5e4
trace:file:ReadFile 0xdc 0x32e734 1 0x32e694 (nil)
trace:comm:io_control 0xdc IOCTL_SERIAL_GET_COMMSTATUS (nil) 0 0x32e63c 20 0x32e5e4
trace:file:ReadFile 0xdc 0x32e734 1 0x32e694 (nil)
trace:comm:SetCommMask handle 0xdc, mask 0
trace:comm:io_control 0xdc IOCTL_SERIAL_SET_WAIT_MASK 0x32e934 4 (nil) 0 0x32e8e0
trace:comm:io_control 0xdc IOCTL_SERIAL_PURGE 0x32e934 4 (nil) 0 0x32e8e0
trace:comm:dump_dcb bytesize=8 baudrate=9600 fParity=0 Parity=0 stopbits=1
trace:comm:dump_dcb ~IXON IXOFF
trace:comm:dump_dcb fOutxCtsFlow=0 fRtsControl=1
trace:comm:dump_dcb fOutxDsrFlow=0 fDtrControl=1
trace:comm:dump_dcb ~CRTSCTS
trace:comm:io_control 0xdc IOCTL_SERIAL_SET_BAUD_RATE 0x32e918 4 (nil) 0 0x32e8c0
trace:comm:io_control 0xdc IOCTL_SERIAL_SET_LINE_CONTROL 0x32e91d 3 (nil) 0 0x32e8c0
trace:comm:io_control 0xdc IOCTL_SERIAL_SET_HANDFLOW 0x32e900 16 (nil) 0 0x32e8c0
trace:comm:io_control 0xdc IOCTL_SERIAL_SET_CHARS 0x32e912 6 (nil) 0 0x32e8c0
~/.wine/dosdevices/com1->/dev/ttyS0, permissions are correct.

Here we can find a widely known FIXME: "fixme:comm:set_queue_size insize 1024 outsize 2048 unimplemented stub" but I don't think that this is a problem. Requested queue size is quite small to don't fit into a kernel's buffers.
Can anybody say where is a problem?
gladov
Newbie
Newbie
Posts: 4
Joined: Fri Jun 19, 2009 6:43 am

Post by gladov »

Important note. If I start a software with +ntdll debug option than every reading from serial port produces such log:

Code: Select all

trace:file:ReadFile 0xdc 0x32e734 1 0x32e694 (nil)
trace:ntdll:NtReadFile (0xdc,(nil),(nil),(nil),0x32e634,0x32e734,0x00000001,(nil),(nil)),partial stub!
trace:ntdll:NtReadFile = SUCCESS (1)
trace:ntdll:NtDeviceIoControlFile (0xdc,(nil),(nil),(nil),0x32e5e4,0x001b006c,(nil),0x00000000,0x32e63c,0x00000014)
trace:comm:io_control 0xdc IOCTL_SERIAL_GET_COMMSTATUS (nil) 0 0x32e63c 20 0x32e5e4
What does a "partial stub!" means?
austin987
Wine Developer
Wine Developer
Posts: 2383
Joined: Fri Feb 22, 2008 8:19 pm

Wine and serial port again

Post by austin987 »

On Fri, Jun 19, 2009 at 7:25 AM, gladov<[email protected]> wrote:
Important note. If I start a software with +ntdll debug option than every reading from serial port produces such log:

Code:

trace:file:ReadFile 0xdc 0x32e734 1 0x32e694 (nil)
trace:ntdll:NtReadFile (0xdc,(nil),(nil),(nil),0x32e634,0x32e734,0x00000001,(nil),(nil)),partial stub!
trace:ntdll:NtReadFile = SUCCESS (1)
trace:ntdll:NtDeviceIoControlFile (0xdc,(nil),(nil),(nil),0x32e5e4,0x001b006c,(nil),0x00000000,0x32e63c,0x00000014)
trace:comm:io_control 0xdc IOCTL_SERIAL_GET_COMMSTATUS (nil) 0 0x32e63c 20 0x32e5e4



What does a "partial stub!" means?
It means the function is not fully implemented.

--
-Austin
gladov
Newbie
Newbie
Posts: 4
Joined: Fri Jun 19, 2009 6:43 am

Post by gladov »

It means the function is not fully implemented.
Is it means that my problem is in the ReadFile() function and not in the "fixme:comm:set_queue_size"?
vitamin
Moderator
Moderator
Posts: 6605
Joined: Sat Feb 23, 2008 2:29 pm

Re: Wine and serial port again

Post by vitamin »

gladov wrote:I trying to execute it with wine 1.0.1 form debian package.
Use latest Wine version, not something that's 1/2 year old. There were several patches in that area since then.
gladov
Newbie
Newbie
Posts: 4
Joined: Fri Jun 19, 2009 6:43 am

Post by gladov »

Use latest Wine version, not something that's 1/2 year old. There were several patches in that area since then.
Upgraded to version 1.1.23. Problem still present :(
vitamin
Moderator
Moderator
Posts: 6605
Joined: Sat Feb 23, 2008 2:29 pm

Post by vitamin »

gladov wrote:Upgraded to version 1.1.23. Problem still present :(
Then it's one of not yet fixed bugs.
Locked