Re: [PATCH v3 2/3] POSIX Asynchronous I/O support: fhandler files

2018-07-17 Thread Mark Geisert
Corinna Vinschen wrote: On Jul 15 01:20, Mark Geisert wrote: + if (aio) + status = NtReadFile (prw_handle, aiocb->aio_win_event, NULL, NULL, +>aio_win_iosb, buf, count, , NULL); + else + status = NtReadFile (prw_handle, NULL, NULL, NULL, , buf,

Re: [PATCH v3 2/3] POSIX Asynchronous I/O support: fhandler files

2018-07-16 Thread Corinna Vinschen
On Jul 15 01:20, Mark Geisert wrote: > + if (aio) > + status = NtReadFile (prw_handle, aiocb->aio_win_event, NULL, NULL, > + >aio_win_iosb, buf, count, , NULL); > + else > + status = NtReadFile (prw_handle, NULL, NULL, NULL, , buf, count, > +

[PATCH v3 2/3] POSIX Asynchronous I/O support: fhandler files

2018-07-15 Thread Mark Geisert
This code is where the AIO implementation is wired into existing Cygwin mechanisms for file and device I/O: the fhandler* functions. It makes use of an existing internal routine prw_open to supply a "shadow fd" that permits asynchronous operations on a file the user app accesses via its own fd.