ide: ide_id_has_flush_cache() -> ata_id_flush_enabled()
* Add ata_id_flush_enabled() inline helper to <linux/ata.h>. * ide_id_has_flush_cache() -> ata_id_flush_enabled() The latter one also checks if the command is marked as supported in word 83 and validity of words 83 & 86. Cc: Jeff Garzik <jgarzik@pobox.com> Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
This commit is contained in:
@ -1453,9 +1453,6 @@ extern struct mutex ide_cfg_mtx;
|
||||
extern struct bus_type ide_bus_type;
|
||||
extern struct class *ide_port_class;
|
||||
|
||||
/* check if CACHE FLUSH command is supported (as defined in ATA-6) */
|
||||
#define ide_id_has_flush_cache(id) ((id)[ATA_ID_CFS_ENABLE_2] & 0x1000)
|
||||
|
||||
/* some Maxtor disks have bit 13 defined incorrectly so check bit 10 too */
|
||||
#define ide_id_has_flush_cache_ext(id) \
|
||||
(((id)[ATA_ID_CFS_ENABLE_2] & 0x2400) == 0x2400)
|
||||
|
Reference in New Issue
Block a user