From owner-freebsd-hackers Thu Nov 4 11:46:26 1999 Delivered-To: freebsd-hackers@freebsd.org Received: from mailer.syr.edu (mailer.syr.edu [128.230.18.29]) by hub.freebsd.org (Postfix) with ESMTP id CA29B14DA1 for ; Thu, 4 Nov 1999 11:46:09 -0800 (PST) (envelope-from cmsedore@mailbox.syr.edu) Received: from rodan.syr.edu by mailer.syr.edu (LSMTP for Windows NT v1.1a) with SMTP id <0.360BC840@mailer.syr.edu>; Thu, 4 Nov 1999 14:45:18 -0500 Received: from localhost (cmsedore@localhost) by rodan.syr.edu (8.8.7/8.8.7) with ESMTP id OAA09825; Thu, 4 Nov 1999 14:45:13 -0500 (EST) X-Authentication-Warning: rodan.syr.edu: cmsedore owned process doing -bs Date: Thu, 4 Nov 1999 14:45:12 -0500 (EST) From: Christopher Sedore X-Sender: cmsedore@rodan.syr.edu To: "Daniel C. Sobral" Cc: Ricardo Bernardini , freebsd-hackers@FreeBSD.ORG Subject: Re: aio Functions In-Reply-To: <3821B6BD.D48EEB1C@newsguy.com> Message-ID: MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.ORG On Fri, 5 Nov 1999, Daniel C. Sobral wrote: > Ricardo Bernardini wrote: > > > > Well !! That's far more than the things I'm having trouble with!! I'm not > > being able to make ONE asynchronous read. I've tried the aio functions with > > file I/O and it worked fine, I've also tried the socket I/O with read() and > > it worked fine too. But when I issue the read to the async queue an try to > > get its status aio_error returns -1 and sets errno to EINVAL. > > Anyway this is a test program just to become familiar with the fucntions > > before actually using them, so I really need more information about them, > > and the aiocb_t struct. > > Be aware that aio is not implemented for all things that you can get > an fd for. It was originally implemented *only* for files, though I > was under the impression that support for sockets was later added. Is this accurate? I thought that you can do an aio_read() for anything that you can do a read() (except for DTYPE_VNODE descriptors, an aiod just latches onto the process fd table and address space then sets up a uio and calls the *fp->f_ops->fo_read). For the 8 months I've been playing with the aio, the sockets have always been there, but the way that they worked left much to be desired IMHO. -Chris To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message