aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--include/linux/ata.h9
1 files changed, 9 insertions, 0 deletions
diff --git a/include/linux/ata.h b/include/linux/ata.h
index 8a12d718c169..a26ebd25bac1 100644
--- a/include/linux/ata.h
+++ b/include/linux/ata.h
@@ -667,6 +667,15 @@ static inline int ata_id_has_dword_io(const u16 *id)
667 return 0; 667 return 0;
668} 668}
669 669
670static inline int ata_id_has_unload(const u16 *id)
671{
672 if (ata_id_major_version(id) >= 7 &&
673 (id[ATA_ID_CFSSE] & 0xC000) == 0x4000 &&
674 id[ATA_ID_CFSSE] & (1 << 13))
675 return 1;
676 return 0;
677}
678
670static inline int ata_id_current_chs_valid(const u16 *id) 679static inline int ata_id_current_chs_valid(const u16 *id)
671{ 680{
672 /* For ATA-1 devices, if the INITIALIZE DEVICE PARAMETERS command 681 /* For ATA-1 devices, if the INITIALIZE DEVICE PARAMETERS command