Commit 9ca7cfa4 authored by Sergei Shtylyov's avatar Sergei Shtylyov Committed by Jeff Garzik

libata-core: use ATA_LBA in ata_build_rw_tf()

Since READ/WRITE FPDMA QUEUED commands are 48-bit, bit 6 of the device register
means LBA, the same as for READ/WRITE DMA EXT commands. So use ATA_LBA instead
of the bare number in ata_build_rw_tf()'s branch dedicated to the NCQ commands.
Signed-off-by: default avatarSergei Shtylyov <sshtylyov@ru.mvista.com>
Signed-off-by: default avatarJeff Garzik <jgarzik@redhat.com>
parent f1e70c2c
...@@ -774,7 +774,7 @@ int ata_build_rw_tf(struct ata_taskfile *tf, struct ata_device *dev, ...@@ -774,7 +774,7 @@ int ata_build_rw_tf(struct ata_taskfile *tf, struct ata_device *dev,
tf->lbam = (block >> 8) & 0xff; tf->lbam = (block >> 8) & 0xff;
tf->lbal = block & 0xff; tf->lbal = block & 0xff;
tf->device = 1 << 6; tf->device = ATA_LBA;
if (tf->flags & ATA_TFLAG_FUA) if (tf->flags & ATA_TFLAG_FUA)
tf->device |= 1 << 7; tf->device |= 1 << 7;
} else if (dev->flags & ATA_DFLAG_LBA) { } else if (dev->flags & ATA_DFLAG_LBA) {
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment