diff options
author | Albert Lee <albertcc@tw.ibm.com> | 2006-05-19 11:43:04 +0800 |
---|---|---|
committer | Jeff Garzik <jeff@garzik.org> | 2006-05-20 00:37:01 -0400 |
commit | 3655d1d323386e001c786af10f0a3f39f438f03b (patch) | |
tree | 16fd30cc6d255e5aaad4a5372cb8ec140c5b9736 /include | |
parent | 3d71b3b0b634b1a5ba8632fd9ec998e0e4aedfdb (diff) | |
download | op-kernel-dev-3655d1d323386e001c786af10f0a3f39f438f03b.zip op-kernel-dev-3655d1d323386e001c786af10f0a3f39f438f03b.tar.gz |
[PATCH] libata: Fix the HSM error_mask mapping (was: Re: libata-tj and SMART)
Fix the HSM error_mask mapping.
Changes:
- Better mapping in ac_err_mask()
- In HSM_ST_FIRST ans HSM_ST state, check ATA_ERR|ATA_DF and map it to AC_ERR_DEV instead of AC_ERR_HSM.
- In HSM_ST_FIRST and HSM_ST state, map DRQ=1 ERR=1 to AC_ERR_HSM.
- For PIO data in and DRQ=1 ERR=1, add check after the junk data block is read.
Signed-off-by: Albert Lee <albertcc@tw.ibm.com>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
Diffstat (limited to 'include')
-rw-r--r-- | include/linux/libata.h | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/include/linux/libata.h b/include/linux/libata.h index 2803ab8..c51502c 100644 --- a/include/linux/libata.h +++ b/include/linux/libata.h @@ -1062,7 +1062,7 @@ static inline int ata_try_flush_cache(const struct ata_device *dev) static inline unsigned int ac_err_mask(u8 status) { - if (status & ATA_BUSY) + if (status & (ATA_BUSY | ATA_DRQ)) return AC_ERR_HSM; if (status & (ATA_ERR | ATA_DF)) return AC_ERR_DEV; |