Skip to content

Commit

Permalink
libata: remove ATA_PROT_FLAG_DATA
Browse files Browse the repository at this point in the history
Instead we can simply check for PIO or DMA in ata_is_data.

Signed-off-by: Christoph Hellwig <hch@lst.de>
Signed-off-by: Tejun Heo <tj@kernel.org>
  • Loading branch information
Christoph Hellwig authored and Tejun Heo committed Jul 19, 2016
1 parent eb0effd commit d6e50e3
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions include/linux/libata.h
Original file line number Diff line number Diff line change
Expand Up @@ -149,7 +149,6 @@ enum {
/* protocol flags */
ATA_PROT_FLAG_PIO = (1 << 0), /* is PIO */
ATA_PROT_FLAG_DMA = (1 << 1), /* is DMA */
ATA_PROT_FLAG_DATA = ATA_PROT_FLAG_PIO | ATA_PROT_FLAG_DMA,
ATA_PROT_FLAG_NCQ = (1 << 2), /* is NCQ */
ATA_PROT_FLAG_ATAPI = (1 << 3), /* is ATAPI */

Expand Down Expand Up @@ -1087,7 +1086,7 @@ static inline bool ata_is_ncq(u8 prot)

static inline bool ata_is_data(u8 prot)
{
return ata_prot_flags(prot) & ATA_PROT_FLAG_DATA;
return ata_prot_flags(prot) & (ATA_PROT_FLAG_PIO | ATA_PROT_FLAG_DMA);
}

static inline int is_multi_taskfile(struct ata_taskfile *tf)
Expand Down

0 comments on commit d6e50e3

Please sign in to comment.