Skip site navigation (1)Skip section navigation (2)
Date:      Sun, 26 Aug 2001 13:29:58 -0600
From:      "Kenneth D. Merry" <ken@kdm.org>
To:        Thomas Quinot <thomas@cuivre.fr.eu.org>
Cc:        stable@FreeBSD.ORG, scsi@FreeBSD.ORG
Subject:   Re: Failure to attach SCSI CD burner
Message-ID:  <20010826132958.A13920@panzer.kdm.org>
In-Reply-To: <20010826204458.A18333@melusine.cuivre.fr.eu.org>; from thomas@cuivre.fr.eu.org on Sun, Aug 26, 2001 at 08:44:58PM %2B0200
References:  <20010825185223.A24294@melusine.cuivre.fr.eu.org> <20010825141549.A8851@panzer.kdm.org> <20010826105444.A65894@melusine.cuivre.fr.eu.org> <20010826122401.A13602@panzer.kdm.org> <20010826204458.A18333@melusine.cuivre.fr.eu.org>

next in thread | previous in thread | raw e-mail | index | archive | help

--tThc/1wpZn/ma/RB
Content-Type: text/plain; charset=iso-8859-1
Content-Disposition: inline
Content-Transfer-Encoding: 8bit

On Sun, Aug 26, 2001 at 20:44:58 +0200, Thomas Quinot wrote:
> Le 2001-08-26, Kenneth D. Merry écrivait :
> 
> > I've attached a patch, please apply it to camcontrol and try the same test
> > again.  This will tell me whether the autosense valid bit is being set.  It
> > looks like the sense information is there, but it may be that the autosense
> > valid bit isn't being set.  That is supposed to be set by the controller
> > driver.
> 
> According to the patched camcontrol, the sense valid bit is set:
> 
> # ./camcontrol cmd 0:2:0 -v -c "25 0 0 0 0 0 0 0 0 0" -i 8 "i4 i4"
> camcontrol: error sending command
> Autosense is valid
> (pass0:sym0:0:2:0): READ CD RECORDED CAPACITY. CDB: 25 0 0 0 0 0 0 0 0 0
> (pass0:sym0:0:2:0): NOT READY asc:4,0
> (pass0:sym0:0:2:0): Logical unit not ready, cause not reportable

Hmm.  Well, try applying the attached patch to sys/cam/scsi/scsi_cd.c and
recompile your kernel.

Then try booting without a CD in the drive and see what is printed.

Ken
-- 
Kenneth Merry
ken@kdm.org

--tThc/1wpZn/ma/RB
Content-Type: text/plain; charset=us-ascii
Content-Disposition: attachment; filename="scsi_cd.c.autosense_test.20010826"

==== //depot/FreeBSD-ken-RELENG_4/src/sys/cam/scsi/scsi_cd.c#4 - /usr/home/ken/perforce/FreeBSD-ken-RELENG_4/src/sys/cam/scsi/scsi_cd.c ====
*** /tmp/tmp.1548.0	Sun Aug 26 13:28:07 2001
--- /usr/home/ken/perforce/FreeBSD-ken-RELENG_4/src/sys/cam/scsi/scsi_cd.c	Sun Aug 26 13:27:35 2001
***************
*** 1699,1707 ****
  
  				if (((csio->ccb_h.flags & CAM_SENSE_PHYS) != 0)
  				 || ((csio->ccb_h.flags & CAM_SENSE_PTR) != 0)
! 				 || ((status & CAM_AUTOSNS_VALID) == 0))
  					have_sense = FALSE;
! 				else
  					have_sense = TRUE;
  
  				if (have_sense) {
--- 1699,1719 ----
  
  				if (((csio->ccb_h.flags & CAM_SENSE_PHYS) != 0)
  				 || ((csio->ccb_h.flags & CAM_SENSE_PTR) != 0)
! 				 || ((status & CAM_AUTOSNS_VALID) == 0)) {
! 					if (status & CAM_AUTOSNS_VALID) {
! 						xpt_print_path(periph->path);
! 						printf("autosense is valid\n");
! 					} else {
! 						xpt_print_path(periph->path);
! 						printf("autosense is NOT "
! 						       "valid\n");
! 					}
! 					xpt_print_path(periph->path);
! 					printf("flags = %#x status = %#x\n",
! 					       csio->ccb_h.flags, status);
! 
  					have_sense = FALSE;
! 				} else
  					have_sense = TRUE;
  
  				if (have_sense) {

--tThc/1wpZn/ma/RB--

To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-stable" in the body of the message




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