]> err.no Git - linux-2.6/commitdiff
[libata] Prefer SCSI_SENSE_BUFFERSIZE to sizeof()
authorJames Bottomley <James.Bottomley@HansenPartnership.com>
Thu, 17 Jan 2008 17:56:24 +0000 (11:56 -0600)
committerJeff Garzik <jeff@garzik.org>
Wed, 23 Jan 2008 10:24:17 +0000 (05:24 -0500)
Signed-off-by: Jeff Garzik <jeff@garzik.org>
drivers/ata/libata-scsi.c

index 989b7755af3d7e7b6ba492664bc28e4d9838994c..3fd08201bef472d4b38774b545ee76a4592ffe66 100644 (file)
@@ -2331,7 +2331,7 @@ static void atapi_request_sense(struct ata_queued_cmd *qc)
        DPRINTK("ATAPI request sense\n");
 
        /* FIXME: is this needed? */
-       memset(cmd->sense_buffer, 0, sizeof(cmd->sense_buffer));
+       memset(cmd->sense_buffer, 0, SCSI_SENSE_BUFFERSIZE);
 
        ap->ops->tf_read(ap, &qc->tf);