Skip to content

Commit

Permalink
libata: Fix regression when the NCQ Send and Receive log page is absent
Browse files Browse the repository at this point in the history
Commit 5d3abf8 ("libata: Fall back to unqueued READ LOG EXT if
the DMA variant fails") allowed us to fall back to the unqueued READ
LOG variant if the queued version failed. However, if the device did
not support the page at all we would end up looping due to a merge
snafu.

Ensure we only take the fallback path once.

Signed-off-by: Martin K. Petersen <[email protected]>
Reported-by: Sergey Senozhatsky <[email protected]>
Tested-by: Sergey Senozhatsky <[email protected]>
Signed-off-by: Tejun Heo <[email protected]>
  • Loading branch information
martinkpetersen authored and htejun committed May 21, 2015
1 parent 6ec0a86 commit eab6ee1
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions drivers/ata/libata-eh.c
Original file line number Diff line number Diff line change
Expand Up @@ -1521,6 +1521,7 @@ unsigned int ata_read_log_page(struct ata_device *dev, u8 log,
} else {
tf.command = ATA_CMD_READ_LOG_EXT;
tf.protocol = ATA_PROT_PIO;
dma = false;
}
tf.lbal = log;
tf.lbam = page;
Expand Down

0 comments on commit eab6ee1

Please sign in to comment.