diff options
Diffstat (limited to 'drivers/ide/sgiioc4.c')
| -rw-r--r-- | drivers/ide/sgiioc4.c | 9 |
1 files changed, 2 insertions, 7 deletions
diff --git a/drivers/ide/sgiioc4.c b/drivers/ide/sgiioc4.c index 457a762a1f29..d90e8c5af0a2 100644 --- a/drivers/ide/sgiioc4.c +++ b/drivers/ide/sgiioc4.c | |||
| @@ -442,7 +442,7 @@ static int sgiioc4_build_dmatable(ide_drive_t *drive, struct ide_cmd *cmd) | |||
| 442 | printk(KERN_WARNING | 442 | printk(KERN_WARNING |
| 443 | "%s: DMA table too small\n", | 443 | "%s: DMA table too small\n", |
| 444 | drive->name); | 444 | drive->name); |
| 445 | goto use_pio_instead; | 445 | return 0; |
| 446 | } else { | 446 | } else { |
| 447 | u32 bcount = | 447 | u32 bcount = |
| 448 | 0x10000 - (cur_addr & 0xffff); | 448 | 0x10000 - (cur_addr & 0xffff); |
| @@ -477,9 +477,6 @@ static int sgiioc4_build_dmatable(ide_drive_t *drive, struct ide_cmd *cmd) | |||
| 477 | return count; | 477 | return count; |
| 478 | } | 478 | } |
| 479 | 479 | ||
| 480 | use_pio_instead: | ||
| 481 | ide_destroy_dmatable(drive); | ||
| 482 | |||
| 483 | return 0; /* revert to PIO for this request */ | 480 | return 0; /* revert to PIO for this request */ |
| 484 | } | 481 | } |
| 485 | 482 | ||
| @@ -488,11 +485,9 @@ static int sgiioc4_dma_setup(ide_drive_t *drive, struct ide_cmd *cmd) | |||
| 488 | int ddir; | 485 | int ddir; |
| 489 | u8 write = !!(cmd->tf_flags & IDE_TFLAG_WRITE); | 486 | u8 write = !!(cmd->tf_flags & IDE_TFLAG_WRITE); |
| 490 | 487 | ||
| 491 | if (sgiioc4_build_dmatable(drive, cmd) == 0) { | 488 | if (sgiioc4_build_dmatable(drive, cmd) == 0) |
| 492 | /* try PIO instead of DMA */ | 489 | /* try PIO instead of DMA */ |
| 493 | ide_map_sg(drive, cmd); | ||
| 494 | return 1; | 490 | return 1; |
| 495 | } | ||
| 496 | 491 | ||
| 497 | if (write) | 492 | if (write) |
| 498 | /* Writes TO the IOC4 FROM Main Memory */ | 493 | /* Writes TO the IOC4 FROM Main Memory */ |
