aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--drivers/ide/ide-floppy.c14
1 files changed, 6 insertions, 8 deletions
diff --git a/drivers/ide/ide-floppy.c b/drivers/ide/ide-floppy.c
index 2b4868d95f8b..3b22e066287e 100644
--- a/drivers/ide/ide-floppy.c
+++ b/drivers/ide/ide-floppy.c
@@ -216,15 +216,13 @@ static void idefloppy_blockpc_cmd(struct ide_disk_obj *floppy,
216 ide_init_pc(pc); 216 ide_init_pc(pc);
217 memcpy(pc->c, rq->cmd, sizeof(pc->c)); 217 memcpy(pc->c, rq->cmd, sizeof(pc->c));
218 pc->rq = rq; 218 pc->rq = rq;
219 if (rq->data_len && rq_data_dir(rq) == WRITE) 219 if (rq->data_len) {
220 pc->flags |= PC_FLAG_WRITING;
221 pc->buf = rq->data;
222 if (rq->bio)
223 pc->flags |= PC_FLAG_DMA_OK; 220 pc->flags |= PC_FLAG_DMA_OK;
224 /* 221 if (rq_data_dir(rq) == WRITE)
225 * possibly problematic, doesn't look like ide-floppy correctly 222 pc->flags |= PC_FLAG_WRITING;
226 * handled scattered requests if dma fails... 223 }
227 */ 224 /* pio will be performed by ide_pio_bytes() which handles sg fine */
225 pc->buf = NULL;
228 pc->req_xfer = pc->buf_size = rq->data_len; 226 pc->req_xfer = pc->buf_size = rq->data_len;
229} 227}
230 228