summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorLinus Torvalds <torvalds@linux-foundation.org>2008-05-11 18:52:45 +0200
committerLinus Torvalds <torvalds@linux-foundation.org>2008-05-11 18:52:45 +0200
commit633331f389c2d9c631371d09a54626a5e4749452 (patch)
tree6cd80edd1075635c64e612cc48e778e66795ea3a
parentMerge master.kernel.org:/home/rmk/linux-2.6-arm (diff)
parent[libata] revert new check-ready Status register logic (diff)
downloadlinux-633331f389c2d9c631371d09a54626a5e4749452.tar.xz
linux-633331f389c2d9c631371d09a54626a5e4749452.zip
Merge branch 'upstream-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/jgarzik/libata-dev
* 'upstream-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/jgarzik/libata-dev: [libata] revert new check-ready Status register logic
-rw-r--r--include/linux/libata.h9
1 files changed, 3 insertions, 6 deletions
diff --git a/include/linux/libata.h b/include/linux/libata.h
index 7e206da1fbfb..0f17643e0a6e 100644
--- a/include/linux/libata.h
+++ b/include/linux/libata.h
@@ -1384,17 +1384,14 @@ static inline struct ata_port *ata_shost_to_port(struct Scsi_Host *host)
static inline int ata_check_ready(u8 status)
{
- /* Some controllers report 0x77 or 0x7f during intermediate
- * not-ready stages.
- */
- if (status == 0x77 || status == 0x7f)
- return 0;
+ if (!(status & ATA_BUSY))
+ return 1;
/* 0xff indicates either no device or device not ready */
if (status == 0xff)
return -ENODEV;
- return !(status & ATA_BUSY);
+ return 0;
}