diff options
author | Hannes Reinecke <hare@suse.de> | 2016-10-31 21:06:58 +0100 |
---|---|---|
committer | Tejun Heo <tj@kernel.org> | 2016-11-01 18:30:15 +0100 |
commit | e0029dcb5b6e1c23e68f578ce7a3d6c5caba0501 (patch) | |
tree | cd4f4505d77b01875b2c05a27f881ca340a4a943 /drivers/ata/libata-scsi.c | |
parent | mvsas: fix error return code in mvs_task_prep() (diff) | |
download | linux-e0029dcb5b6e1c23e68f578ce7a3d6c5caba0501.tar.xz linux-e0029dcb5b6e1c23e68f578ce7a3d6c5caba0501.zip |
libata-scsi: Fixup ata_gen_passthru_sense()
There's a typo in ata_gen_passthru_sense(), where the first byte
would be overwritten incorrectly later on.
Reported-by: Charles Machalow <csm10495@gmail.com>
Signed-off-by: Hannes Reinecke <hare@suse.com>
Fixes: 11093cb1ef56 ("libata-scsi: generate correct ATA pass-through sense")
Cc: stable@vger.kernel.org # v4.7+
Signed-off-by: Tejun Heo <tj@kernel.org>
Diffstat (limited to 'drivers/ata/libata-scsi.c')
-rw-r--r-- | drivers/ata/libata-scsi.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/ata/libata-scsi.c b/drivers/ata/libata-scsi.c index 9cceb4a875a5..c4eb4ae9c3aa 100644 --- a/drivers/ata/libata-scsi.c +++ b/drivers/ata/libata-scsi.c @@ -1088,7 +1088,7 @@ static void ata_gen_passthru_sense(struct ata_queued_cmd *qc) desc[1] = tf->command; /* status */ desc[2] = tf->device; desc[3] = tf->nsect; - desc[0] = 0; + desc[7] = 0; if (tf->flags & ATA_TFLAG_LBA48) { desc[8] |= 0x80; if (tf->hob_nsect) |