From owner-freebsd-scsi Mon Sep 7 23:52:29 1998 Return-Path: Received: (from majordom@localhost) by hub.freebsd.org (8.8.8/8.8.8) id XAA11460 for freebsd-scsi-outgoing; Mon, 7 Sep 1998 23:52:29 -0700 (PDT) (envelope-from owner-freebsd-scsi@FreeBSD.ORG) Received: from feral.com (gw100.feral.com [192.67.166.129]) by hub.freebsd.org (8.8.8/8.8.8) with ESMTP id XAA11455 for ; Mon, 7 Sep 1998 23:52:27 -0700 (PDT) (envelope-from mjacob@feral.com) Received: from localhost (mjacob@localhost) by feral.com (8.8.6/8.8.6) with SMTP id XAA05727; Mon, 7 Sep 1998 23:52:18 -0700 Date: Mon, 7 Sep 1998 23:52:18 -0700 (PDT) From: Matthew Jacob X-Sender: mjacob@feral-gw Reply-To: mjacob@feral.com To: "Kenneth D. Merry" cc: scsi@FreeBSD.ORG Subject: Re: right return message for CAM sa driver? In-Reply-To: <199809080329.VAA19256@panzer.plutotech.com> Message-ID: MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII Sender: owner-freebsd-scsi@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.org ENODEV Operation not supported by device seems better in this context than "Device not configured". The device is configured (it's attached and configured)- it's just not ready for operation. Usually this is an EIO error, but if you're going to have other than that, I believe ENXIO is misleading. On Mon, 7 Sep 1998, Kenneth D. Merry wrote: > Matthew Jacob wrote... > > > > A mt rewind on a device that's there but with no tape returns: > > > > quarm.feral.com > root mt -f /dev/rsa0 rewind > > mt: /dev/rsa0: rewind: Device not configured > > > > > > Is that really the right errno we want? > > > It's set in scsi_all.c: > > /* DTL WRSOM */{SST(0x3A, 0x00, SS_NEDEF|ENXIO, > "Medium not present") }, > /* DT WR OM */{SST(0x3A, 0x01, SS_NEDEF|ENXIO, > "Medium not present - tray closed") }, > /* DT WR OM */{SST(0x3A, 0x02, SS_NEDEF|ENXIO, > "Medium not present - tray open") }, > > What would you suggest as an alternative? I'm certainly open to > suggestions. ENXIO gets returned for basically any type of medium not > present error. > > If you want something just for tape drives, we can easily stick a > tape-drive-only error code in the sense code quirk table. > > [ ... ] > > > quarm.feral.com > dmesg | tail -30 > > (sa0:isp0:0:4:0): REWIND. CDB: 1 0 0 0 0 0 > > (sa0:isp0:0:4:0): NOT READY asc:3a,0 > > (sa0:isp0:0:4:0): Medium not present > > (sa0:isp0:0:4:0): REWIND. CDB: 1 0 0 0 0 0 > > (sa0:isp0:0:4:0): NOT READY asc:3a,0 > > (sa0:isp0:0:4:0): Medium not present > [ ... ] > > > Ken > -- > Kenneth Merry > ken@plutotech.com > > To Unsubscribe: send mail to majordomo@FreeBSD.org > with "unsubscribe freebsd-scsi" in the body of the message > To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-scsi" in the body of the message