Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 130808
b: refs/heads/master
c: 2999b58
h: refs/heads/master
v: v3
  • Loading branch information
Sergei Shtylyov authored and Jeff Garzik committed Feb 3, 2009
1 parent 2b71bb0 commit b138d6e
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 6 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 5eb66fe05f08d515a7377787473bc4e4b1ed5b59
refs/heads/master: 2999b58b795ad81f10e34bdbbfd2742172f247e4
15 changes: 10 additions & 5 deletions trunk/include/linux/ata.h
Original file line number Diff line number Diff line change
Expand Up @@ -731,12 +731,17 @@ static inline int ata_id_current_chs_valid(const u16 *id)

static inline int ata_id_is_cfa(const u16 *id)
{
if (id[ATA_ID_CONFIG] == 0x848A) /* Standard CF */
if (id[ATA_ID_CONFIG] == 0x848A) /* Traditional CF */
return 1;
/* Could be CF hiding as standard ATA */
if (ata_id_major_version(id) >= 3 &&
id[ATA_ID_COMMAND_SET_1] != 0xFFFF &&
(id[ATA_ID_COMMAND_SET_1] & (1 << 2)))
/*
* CF specs don't require specific value in the word 0 anymore and yet
* they forbid to report the ATA version in the word 80 and require the
* CFA feature set support to be indicated in the word 83 in this case.
* Unfortunately, some cards only follow either of this requirements,
* and while those that don't indicate CFA feature support need some
* sort of quirk list, it seems impractical for the ones that do...
*/
if ((id[ATA_ID_COMMAND_SET_2] & 0xC004) == 0x4004)
return 1;
return 0;
}
Expand Down

0 comments on commit b138d6e

Please sign in to comment.