From owner-freebsd-current Mon Dec 1 17:54:46 1997 Return-Path: Received: (from root@localhost) by hub.freebsd.org (8.8.7/8.8.7) id RAA13597 for current-outgoing; Mon, 1 Dec 1997 17:54:46 -0800 (PST) (envelope-from owner-freebsd-current) Received: from dyson.iquest.net (dyson.iquest.net [198.70.144.127]) by hub.freebsd.org (8.8.7/8.8.7) with ESMTP id RAA13591 for ; Mon, 1 Dec 1997 17:54:42 -0800 (PST) (envelope-from toor@dyson.iquest.net) Received: (from root@localhost) by dyson.iquest.net (8.8.7/8.8.8) id UAA08318; Mon, 1 Dec 1997 20:54:35 -0500 (EST) (envelope-from toor) From: "John S. Dyson" Message-Id: <199712020154.UAA08318@dyson.iquest.net> Subject: Re: FYI: usage of new AIO calls In-Reply-To: <199712020132.SAA28471@usr07.primenet.com> from Terry Lambert at "Dec 2, 97 01:32:08 am" To: tlambert@primenet.com (Terry Lambert) Date: Mon, 1 Dec 1997 20:54:34 -0500 (EST) Cc: toor@dyson.iquest.net, current@FreeBSD.ORG X-Mailer: ELM [version 2.4ME+ PL31 (25)] MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Sender: owner-freebsd-current@FreeBSD.ORG X-Loop: FreeBSD.org Precedence: bulk Terry Lambert said: > > For fun (and actually as a result of a comment by Justin Gibbs), I have put > > together a small program that could maybe be used for streaming tape drives > > using the new AIO code. Note that if you try this, it must be used only > > on current kernels on/after 19:00 GMT, Dec 1. > > [ ... ] > > > errval = aio_suspend(&olist[i], 1, NULL); > > errval = aio_error(olist[i]); > > rtval = aio_return(olist[i]); > > errval = aio_write(olist[i]); > > nread = read( fd1, bufaddrs[i], BUFSZ); > > Some questions... > > 1) Why did you 'read' instead of 'aio_read'? > Because that is what I chose to use in my example. aio_read works also. > > 2) Why did you define your own interface instead of using the > SunOS/Solaris/SVR4/SCO interface: > Did I write POSIX IEEE Std 1003.1b-1993? You give me alot of credit, because the functions that I implemented came from there. (refer to pages 151 through 168 of the standards document.) The stuff is also the same as the equivalents in The Open Group X/Open Spec. I really don't think that I invented those interfaces also. -- John dyson@freebsd.org jdyson@nc.com