aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/ide/ide-cd.c
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/ide/ide-cd.c')
-rw-r--r--drivers/ide/ide-cd.c9
1 files changed, 5 insertions, 4 deletions
diff --git a/drivers/ide/ide-cd.c b/drivers/ide/ide-cd.c
index ee4d458e2bbf..5e42c19a03e3 100644
--- a/drivers/ide/ide-cd.c
+++ b/drivers/ide/ide-cd.c
@@ -295,7 +295,8 @@ static int cdrom_decode_status(ide_drive_t *drive, int good_stat, int *stat_ret)
295 int stat, err, sense_key; 295 int stat, err, sense_key;
296 296
297 /* Check for errors. */ 297 /* Check for errors. */
298 stat = HWIF(drive)->INB(IDE_STATUS_REG); 298 stat = ide_read_status(drive);
299
299 if (stat_ret) 300 if (stat_ret)
300 *stat_ret = stat; 301 *stat_ret = stat;
301 302
@@ -303,7 +304,7 @@ static int cdrom_decode_status(ide_drive_t *drive, int good_stat, int *stat_ret)
303 return 0; 304 return 0;
304 305
305 /* Get the IDE error register. */ 306 /* Get the IDE error register. */
306 err = HWIF(drive)->INB(IDE_ERROR_REG); 307 err = ide_read_error(drive);
307 sense_key = err >> 4; 308 sense_key = err >> 4;
308 309
309 if (rq == NULL) { 310 if (rq == NULL) {
@@ -692,7 +693,7 @@ int ide_cd_check_ireason(ide_drive_t *drive, int len, int ireason, int rw)
692 /* Some drives (ASUS) seem to tell us that status 693 /* Some drives (ASUS) seem to tell us that status
693 * info is available. just get it and ignore. 694 * info is available. just get it and ignore.
694 */ 695 */
695 (void) HWIF(drive)->INB(IDE_STATUS_REG); 696 (void)ide_read_status(drive);
696 return 0; 697 return 0;
697 } else { 698 } else {
698 /* Drive wants a command packet, or invalid ireason... */ 699 /* Drive wants a command packet, or invalid ireason... */
@@ -1326,7 +1327,7 @@ ide_do_rw_cdrom (ide_drive_t *drive, struct request *rq, sector_t block)
1326 if (blk_fs_request(rq)) { 1327 if (blk_fs_request(rq)) {
1327 if (info->cd_flags & IDE_CD_FLAG_SEEKING) { 1328 if (info->cd_flags & IDE_CD_FLAG_SEEKING) {
1328 unsigned long elapsed = jiffies - info->start_seek; 1329 unsigned long elapsed = jiffies - info->start_seek;
1329 int stat = HWIF(drive)->INB(IDE_STATUS_REG); 1330 int stat = ide_read_status(drive);
1330 1331
1331 if ((stat & SEEK_STAT) != SEEK_STAT) { 1332 if ((stat & SEEK_STAT) != SEEK_STAT) {
1332 if (elapsed < IDECD_SEEK_TIMEOUT) { 1333 if (elapsed < IDECD_SEEK_TIMEOUT) {