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.c11
1 files changed, 10 insertions, 1 deletions
diff --git a/drivers/ide/ide-cd.c b/drivers/ide/ide-cd.c
index 2f698c6e913f..a6c847d31b9d 100644
--- a/drivers/ide/ide-cd.c
+++ b/drivers/ide/ide-cd.c
@@ -1066,6 +1066,8 @@ static void cdrom_do_block_pc(ide_drive_t *drive, struct request *rq)
1066static ide_startstop_t ide_cd_do_request(ide_drive_t *drive, struct request *rq, 1066static ide_startstop_t ide_cd_do_request(ide_drive_t *drive, struct request *rq,
1067 sector_t block) 1067 sector_t block)
1068{ 1068{
1069 struct ide_cmd cmd;
1070
1069 ide_debug_log(IDE_DBG_RQ, "cmd: 0x%x, block: %llu", 1071 ide_debug_log(IDE_DBG_RQ, "cmd: 0x%x, block: %llu",
1070 rq->cmd[0], (unsigned long long)block); 1072 rq->cmd[0], (unsigned long long)block);
1071 1073
@@ -1094,7 +1096,14 @@ static ide_startstop_t ide_cd_do_request(ide_drive_t *drive, struct request *rq,
1094 return ide_stopped; 1096 return ide_stopped;
1095 } 1097 }
1096 1098
1097 return ide_issue_pc(drive); 1099 memset(&cmd, 0, sizeof(cmd));
1100
1101 if (rq_data_dir(rq))
1102 cmd.tf_flags |= IDE_TFLAG_WRITE;
1103
1104 cmd.rq = rq;
1105
1106 return ide_issue_pc(drive, &cmd);
1098} 1107}
1099 1108
1100/* 1109/*