Date: Sat, 10 Feb 2001 22:50:09 +0900 From: non@ever.sanda.gr.jp To: current@FreeBSD.ORG Cc: trevor@jpj.net, akiyama@FreeBSD.ORG Subject: Re: od driver for -CURRENT Message-ID: <20010210225009W.non@ever.sanda.gr.jp> In-Reply-To: <Pine.BSF.4.21.0102100603570.17078-100000@besplex.bde.org> References: <20010209211616W.non@ever.sanda.gr.jp> <Pine.BSF.4.21.0102100603570.17078-100000@besplex.bde.org>
next in thread | previous in thread | raw e-mail | index | archive | help
From: Bruce Evans <bde@zeta.org.au> Date: Sat, 10 Feb 2001 06:24:20 +1100 (EST) > On Fri, 9 Feb 2001 non@ever.sanda.gr.jp wrote: > > From: "Kenneth D. Merry" <ken@kdm.org> > > > Hmm, can you demonstrate the problem? The write-protect check in the od > > > driver is one of the things that the da driver doesn't have. I figured it > > > wouldn't really be necessary, since any attempted writes would be returned > > > with errors. > > > > The problem is you cannot unmount after -rw mount with a write-protected > > medium. > > This is essentially the same bug that causes problems for writing to > write protected media or unwriteable blocks using the block device. Are there any reason device drivers do not check if thier devices are writable or not when they are opened ? I think returning an error value, like `od', is the easiest way to avoid this problem. > I first saw this problem for a floppy driver that I wrote in 1984. It > retried endlessly. Users did not like this :-). I was told not to write-protect floppies when using UNIX :-( // Noriaki Mitsunaga // To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-current" in the body of the message
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20010210225009W.non>