diff options
Diffstat (limited to 'drivers/ide/ide-floppy.c')
-rw-r--r-- | drivers/ide/ide-floppy.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/ide/ide-floppy.c b/drivers/ide/ide-floppy.c index 1c460bd56375..650981758f15 100644 --- a/drivers/ide/ide-floppy.c +++ b/drivers/ide/ide-floppy.c | |||
@@ -220,14 +220,14 @@ static void idefloppy_blockpc_cmd(struct ide_disk_obj *floppy, | |||
220 | ide_init_pc(pc); | 220 | ide_init_pc(pc); |
221 | memcpy(pc->c, rq->cmd, sizeof(pc->c)); | 221 | memcpy(pc->c, rq->cmd, sizeof(pc->c)); |
222 | pc->rq = rq; | 222 | pc->rq = rq; |
223 | if (rq->data_len) { | 223 | if (blk_rq_bytes(rq)) { |
224 | pc->flags |= PC_FLAG_DMA_OK; | 224 | pc->flags |= PC_FLAG_DMA_OK; |
225 | if (rq_data_dir(rq) == WRITE) | 225 | if (rq_data_dir(rq) == WRITE) |
226 | pc->flags |= PC_FLAG_WRITING; | 226 | pc->flags |= PC_FLAG_WRITING; |
227 | } | 227 | } |
228 | /* pio will be performed by ide_pio_bytes() which handles sg fine */ | 228 | /* pio will be performed by ide_pio_bytes() which handles sg fine */ |
229 | pc->buf = NULL; | 229 | pc->buf = NULL; |
230 | pc->req_xfer = pc->buf_size = rq->data_len; | 230 | pc->req_xfer = pc->buf_size = blk_rq_bytes(rq); |
231 | } | 231 | } |
232 | 232 | ||
233 | static ide_startstop_t ide_floppy_do_request(ide_drive_t *drive, | 233 | static ide_startstop_t ide_floppy_do_request(ide_drive_t *drive, |