Skip site navigation (1)Skip section navigation (2)
Date:      Sat, 20 Sep 2003 22:39:42 -0600
From:      "Kenneth D. Merry" <ken@kdm.org>
To:        Thomas Quinot <thomas@FreeBSD.ORG>
Cc:        gibbs@FreeBSD.ORG
Subject:   Re: Missing length specification in scsi_request_sense
Message-ID:  <20030921043942.GB22790@panzer.kdm.org>
In-Reply-To: <20030920110131.GA41062@melusine.cuivre.fr.eu.org>
References:  <20030920110131.GA41062@melusine.cuivre.fr.eu.org>

next in thread | previous in thread | raw e-mail | index | archive | help
On Sat, Sep 20, 2003 at 13:01:31 +0200, Thomas Quinot wrote:
> The CDB built by scsi_request_sense always has a zero length indication,
> preventing correct transfer of sense data during recovery action by
> cam_periph. The following change resolves the problem, please review.
> 
> Thomas.
> 
> Index: scsi/scsi_all.c
> ===================================================================
> RCS file: /home/ncvs/src/sys/cam/scsi/scsi_all.c,v
> retrieving revision 1.42
> diff -u -r1.42 scsi_all.c
> --- scsi/scsi_all.c	10 Jun 2003 18:14:04 -0000	1.42
> +++ scsi/scsi_all.c	20 Sep 2003 10:53:38 -0000
> @@ -2408,6 +2408,7 @@
>  	scsi_cmd = (struct scsi_request_sense *)&csio->cdb_io.cdb_bytes;
>  	bzero(scsi_cmd, sizeof(*scsi_cmd));
>  	scsi_cmd->opcode = REQUEST_SENSE;
> +	scsi_cmd->length = dxfer_len;
>  }
>  
>  void

Looks good, please commit.

Ken
-- 
Kenneth Merry
ken@kdm.org



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