Mike McCormack writes:
>
> Support for WaitCommEvent. (in Linux)
>
> (bear with me, i'm a bit tired and don't have Linux's source in front
> of me)
>
> To support anything other than EV_RXCHAR and EV_TXEMPTY will require
> some kernel hacking, as the Linux kernel provides no way to be alerted
> on deltas in modem state...
>
> The way i though of to support all the waitable flags of WaitCommEvent
> (EV_CTS, EV_DSR, EV_RLSD, EV_BREAK, etc) was to create three Linux
> ioctls that enable selecting on changes of state in the serial port.
> These would be something like TCIOM_SETMASK, TCIOM_GETMASK,
> TCIOM_GETEVENTS.
>
> Basic sequence would be (in pseudo code):
>
> /* set which events select is responsive to */
> ioctl(fd,TCIOM_SETMASK, &event_mask);
> select(fd,POLLIN); /* wineserver's main select call */
> /* which event triggered select? */
> ioctl(fd,TCIOM_GETEVENTS, &events);
>
> TCIOM_GETMASK would be used in GetCommMask.
>
> This would require changes to linux/drivers/char/n_tty.c, and
> linux/drivers/char/serial.c
>
> Question: i haven't followed Linux 2.3.x development closely. Does
> anybody know of any changes to 2.3.x that could be used to support
> WaitCommEvent?
>
>
Hallo Mike,
thanks for comming back to that issue. I also promised some action on
that subject and even talked to Theodore Tso about that subject when
he was in Darmstadt last summer. But as the kernel was in freeze even
then, I thought I just wait for 2.4...
I suppose you mail Theodore about the needed changes with some
explanation and the patch.
I also have no experience with 2.3/4. And Alan Cox told me that I
should stay with 2.2 for wine developpment to not hunt ghost bugs in
wine cause by the kernel.
> OK, if you've gotten this far, you may be interested in having a look
> at some source code that attempts to implement async I/O as described
> above. If so, mail me. It compiles, but i haven't completed debugging
> yet, so it's not really ready for release...
>
Please send me for reference.
> Sorry for my English... though English is my native language ;-)
>
Sorry for my english too :-)
Bye
Uwe Bonnes [EMAIL PROTECTED]
Institut fuer Kernphysik Schlossgartenstrasse 9 64289 Darmstadt
--------- Tel. 06151 162516 -------- Fax. 06151 164321 ----------