From: akpm@linux-foundation.org Date: Wed, 16 Jan 2008 00:01:52 +0000 (-0800) Subject: [libata] Prefer SCSI_SENSE_BUFFERSIZE to sizeof() X-Git-Tag: v2.6.25-rc1~1233^2~12 X-Git-Url: https://err.no/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=cadb7345d92628d46cccd3765cc15cb9cd6abccf;p=linux-2.6 [libata] Prefer SCSI_SENSE_BUFFERSIZE to sizeof() Cc: James Bottomley Cc: Jeff Garzik Signed-off-by: Andrew Morton Signed-off-by: Jeff Garzik --- diff --git a/drivers/ata/libata-scsi.c b/drivers/ata/libata-scsi.c index 15a4c8a203..989b7755af 100644 --- a/drivers/ata/libata-scsi.c +++ b/drivers/ata/libata-scsi.c @@ -2342,7 +2342,7 @@ static void atapi_request_sense(struct ata_queued_cmd *qc) ata_qc_reinit(qc); /* setup sg table and init transfer direction */ - sg_init_one(&qc->sgent, cmd->sense_buffer, sizeof(cmd->sense_buffer)); + sg_init_one(&qc->sgent, cmd->sense_buffer, SCSI_SENSE_BUFFERSIZE); ata_sg_init(qc, &qc->sgent, 1); qc->dma_dir = DMA_FROM_DEVICE;