From owner-freebsd-scsi Mon Sep 30 14:42:58 1996 Return-Path: owner-freebsd-scsi Received: (from root@localhost) by freefall.freebsd.org (8.7.5/8.7.3) id OAA05167 for freebsd-scsi-outgoing; Mon, 30 Sep 1996 14:42:58 -0700 (PDT) Received: from iafnl.es.iaf.nl (uucp@iafnl.es.iaf.nl [195.108.17.20]) by freefall.freebsd.org (8.7.5/8.7.3) with SMTP id OAA05066 for ; Mon, 30 Sep 1996 14:42:50 -0700 (PDT) Received: by iafnl.es.iaf.nl with UUCP id AA31206 (5.67b/IDA-1.5 for freebsd-scsi@FreeBSD.ORG); Mon, 30 Sep 1996 23:42:32 +0200 Received: (from wilko@localhost) by yedi.iaf.nl (8.7.5/8.6.12) id UAA00673; Mon, 30 Sep 1996 20:43:58 +0100 (MET) From: Wilko Bulte Message-Id: <199609301943.UAA00673@yedi.iaf.nl> Subject: Re: HP T4000s tape drive To: joerg_wunsch@uriah.heep.sax.de Date: Mon, 30 Sep 1996 20:43:58 +0100 (MET) Cc: freebsd-scsi@FreeBSD.ORG, richard@cogsci.ed.ac.uk In-Reply-To: <199609300625.IAA11367@uriah.heep.sax.de> from "J Wunsch" at Sep 30, 96 08:25:42 am X-Mailer: ELM [version 2.4 PL24 ME8a] Mime-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Sender: owner-freebsd-scsi@FreeBSD.ORG X-Loop: FreeBSD.org Precedence: bulk As J Wunsch wrote... > As Richard Tobin wrote: > > > > > ! #define SCSI_2_MAX_DENSITY_CODE 0xff /* SCSI 2 spec is out of date! */ > > > and this? The entire check for a ``max density'' could go. > > > > Well the user passes it in as a u_int32 (in the ioctl) and it gets > > assigned to a u_char (for the scsi_select), so perhaps a range check > > is still appropriate? > > No. It's garbage. There's no use of limiting the density range that > could be passed down to the device. The worst that happens (if a user > specifies a bogus density in the ``mt density'' command) is a SCSI > error that will pop up on the console. We already agreed before that > this test can go away. As an example: my DLT2000 can use 0x81 to switch to compressed mode. Drives should be smart enough to return invalid mode or something similar. Wilko _ ____________________________________________________________________ | / o / / _ Bulte email: wilko@yedi.iaf.nl - Arnhem, The Netherlands |/|/ / / /( (_) Do, or do not. There is no 'try' - Yoda --------------------------------------------------------------------------