From owner-freebsd-hackers Sun Oct 19 01:55:33 1997 Return-Path: Received: (from root@localhost) by hub.freebsd.org (8.8.7/8.8.7) id BAA28615 for hackers-outgoing; Sun, 19 Oct 1997 01:55:33 -0700 (PDT) (envelope-from owner-freebsd-hackers) Received: from trojanhorse.ml.org (mdean.vip.best.com [206.86.94.101]) by hub.freebsd.org (8.8.7/8.8.7) with ESMTP id BAA28609 for ; Sun, 19 Oct 1997 01:55:28 -0700 (PDT) (envelope-from jamil@trojanhorse.ml.org) Received: from localhost (jamil@localhost) by trojanhorse.ml.org (8.8.7/8.8.5) with SMTP id BAA00524; Sun, 19 Oct 1997 01:28:22 -0700 (PDT) Date: Sun, 19 Oct 1997 01:28:22 -0700 (PDT) From: "Jamil J. Weatherbee" To: Mike Smith cc: Peter Dufault , freebsd-hackers@FreeBSD.ORG Subject: Re: Opinions wanted. In-Reply-To: <199710190746.RAA01382@word.smith.net.au> Message-ID: MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII Sender: owner-freebsd-hackers@FreeBSD.ORG X-Loop: FreeBSD.org Precedence: bulk > > > If an 8255 (digital I/O) 8-bit port is opened via open() call by the user > > > as O_RDWR then it becomes an output, > > It makes little sense to model the 8255 like this. It would be much > more sensible to allow open/close and require an ioctl to provide > register access. I would have to disagree with this, here's how I have it configure itself. O_RDWR or O_WRONLY makes it an output O_RDONLY makes it an input To have to ioctl() it for a basic operation like determining if it is an input or output is just extra work when the open flags describe operation precisely anyway. I have completed my work and debugged it (it took much longer than expected). I would now like to request to have some kernel type person look at it and tell me if I have major league screwed up anything (it works fine in all my tests).