diff options
Diffstat (limited to 'include/linux/libata.h')
| -rw-r--r-- | include/linux/libata.h | 16 |
1 files changed, 13 insertions, 3 deletions
diff --git a/include/linux/libata.h b/include/linux/libata.h index 0d61357604d5..c6883ba8cba9 100644 --- a/include/linux/libata.h +++ b/include/linux/libata.h | |||
| @@ -672,14 +672,24 @@ static inline unsigned int ata_tag_valid(unsigned int tag) | |||
| 672 | return (tag < ATA_MAX_QUEUE) ? 1 : 0; | 672 | return (tag < ATA_MAX_QUEUE) ? 1 : 0; |
| 673 | } | 673 | } |
| 674 | 674 | ||
| 675 | static inline unsigned int ata_class_present(unsigned int class) | 675 | static inline unsigned int ata_class_enabled(unsigned int class) |
| 676 | { | 676 | { |
| 677 | return class == ATA_DEV_ATA || class == ATA_DEV_ATAPI; | 677 | return class == ATA_DEV_ATA || class == ATA_DEV_ATAPI; |
| 678 | } | 678 | } |
| 679 | 679 | ||
| 680 | static inline unsigned int ata_dev_present(const struct ata_device *dev) | 680 | static inline unsigned int ata_class_disabled(unsigned int class) |
| 681 | { | 681 | { |
| 682 | return ata_class_present(dev->class); | 682 | return class == ATA_DEV_ATA_UNSUP || class == ATA_DEV_ATAPI_UNSUP; |
| 683 | } | ||
| 684 | |||
| 685 | static inline unsigned int ata_dev_enabled(const struct ata_device *dev) | ||
| 686 | { | ||
| 687 | return ata_class_enabled(dev->class); | ||
| 688 | } | ||
| 689 | |||
| 690 | static inline unsigned int ata_dev_disabled(const struct ata_device *dev) | ||
| 691 | { | ||
| 692 | return ata_class_disabled(dev->class); | ||
| 683 | } | 693 | } |
| 684 | 694 | ||
| 685 | static inline u8 ata_chk_status(struct ata_port *ap) | 695 | static inline u8 ata_chk_status(struct ata_port *ap) |
