Skip site navigation (1)Skip section navigation (2)
Date:      Tue, 3 Apr 2007 21:07:05 -0700
From:      "Josh Carroll" <josh.carroll@gmail.com>
To:        "Scott Long" <scottl@samsco.org>
Cc:        freebsd-scsi@freebsd.org, bug-followup@freebsd.org, Thomas Quinot <thomas@freebsd.org>
Subject:   Re: kern/103602: drive gets wedged on READ CD CAPACITY if no disc is in
Message-ID:  <8cb6106e0704032107w457026b1t1e04ed11008af48a@mail.gmail.com>
In-Reply-To: <8cb6106e0704030039if46397fvfc993d9c9e19e1fc@mail.gmail.com>
References:  <20070313205731.GB3866@melamine.cuivre.fr.eu.org> <20070326180018.GA23771@melamine.cuivre.fr.eu.org> <460829E9.3080102@samsco.org> <8cb6106e0703261318o120c620ar6b2461802632fc01@mail.gmail.com> <8cb6106e0703262119g5a9afd4m2c3d5665c85c4969@mail.gmail.com> <4608A35E.3010404@samsco.org> <8cb6106e0703262157m7fd0ae96p3bb5368af797dc6b@mail.gmail.com> <460AA9E3.4030106@samsco.org> <8cb6106e0703281531k4c5bebecp5566c64c8f458a74@mail.gmail.com> <8cb6106e0704030039if46397fvfc993d9c9e19e1fc@mail.gmail.com>

next in thread | previous in thread | raw e-mail | index | archive | help
Thinking out of the box, I decided to use sg3_utils on both the
semi-working 7.0-CURRENT kernel I had, and on a Linux Knoppix 5.1 live
CD.

Pretty much every sg utility resulted in a acd0 FAILURE message (I ran
the commands against /dev/cd0 though of course). Here are the various
dmesg messages:

acd0: FAILURE - INQUIRY timed out
acd0: FAILURE - MODE_SENSE_BIG timed out
acd0: FAILURE - READ_CAPACITY timed out
acd0: FAILURE - SEND_KEY timed out
acd0: FAILURE - unknown CMD (0x46) timed out

It seems like every atapi command is timing out when I boot without a
disc in the drive. The only command that semi-worked was sg_turs.
Without a CD in the drive, I get the following output:

    test unit ready cdb: 00 00 00 00 00 00
test unit ready: Probably uninitialized data.
  Try to view as SCSI-1 non-extended sense:
  AdValid=0  Error class=0  Error code=0

 Raw sense data (in hex):
        00 00 00 00 00 00 00 00  00 00 00 00 00 00 00 00
        00 00 00 00 00 00 00 00  00 00 00 00 00 00 00 00

If I insert a CD and run it, I get normal output (e.g. matching that
of what I saw on Knoppix):

    test unit ready cdb: 00 00 00 00 00 00

Perhaps there is a subtle difference with TUR with and without a disc,
which the kernel can sense and take appropriate action? When running
any of these sg* commands in Knoppix with no disc in the drive, I get
a message similar to this:

sg_readcap.no_disc.out:READ CAPACITY (10) failed, device not ready

Interestingly, the sg_vpd command fails to read the serial # as well,
so that is definitely a known bug with this drive I think. Here is the
sg_vpd output on Knoppix:

Supported VPD pages VPD page:
fetching VPD page failed

I don't know if the output of any of these sg commands on Knoppix is
useful (e.g. sg_get_config, sg_modes, sginfo) in terms of finding out
details of the device, but if interested I've posted a tarball of the
outputs here:

http://pflog.net/floyd/sg_output.tgz

Anyway, I thought some of this might be useful. At least I hope :)

Josh



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?8cb6106e0704032107w457026b1t1e04ed11008af48a>