Skip to content

Commit 90c313d

Browse files
Niklas CasselDamien Le Moal
authored andcommitted
ata: remove unused helper ata_id_flush_ext_enabled()
Not only is this function unused, but even worse, the bit it is checking is actually used for signaling if the feature is supported, not enabled. Therefore, remove the unused helper function ata_id_flush_ext_enabled(). ata_id_has_flush_ext() is left unmodified, since this extra supported bit (Bit 13 of word 86) is simply a copy of the bit that ata_id_has_flush_ext() already checks (Bit 13 of word 83), see ACS-5 r10: 7.13.6.41 Words 85..87, 120: Commands and feature sets supported or enabled Signed-off-by: Niklas Cassel <[email protected]> Signed-off-by: Damien Le Moal <[email protected]>
1 parent 73eb550 commit 90c313d

File tree

1 file changed

+0
-13
lines changed

1 file changed

+0
-13
lines changed

include/linux/ata.h

Lines changed: 0 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -622,19 +622,6 @@ static inline bool ata_id_has_flush_ext(const u16 *id)
622622
return id[ATA_ID_COMMAND_SET_2] & (1 << 13);
623623
}
624624

625-
static inline bool ata_id_flush_ext_enabled(const u16 *id)
626-
{
627-
if (ata_id_has_flush_ext(id) == 0)
628-
return false;
629-
if ((id[ATA_ID_CSF_DEFAULT] & 0xC000) != 0x4000)
630-
return false;
631-
/*
632-
* some Maxtor disks have bit 13 defined incorrectly
633-
* so check bit 10 too
634-
*/
635-
return (id[ATA_ID_CFS_ENABLE_2] & 0x2400) == 0x2400;
636-
}
637-
638625
static inline u32 ata_id_logical_sector_size(const u16 *id)
639626
{
640627
/* T13/1699-D Revision 6a, Sep 6, 2008. Page 128.

0 commit comments

Comments
 (0)