Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 68558
b: refs/heads/master
c: 254bb55
h: refs/heads/master
v: v3
  • Loading branch information
Bartlomiej Zolnierkiewicz committed Oct 13, 2007
1 parent ad0d00a commit cc90081
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 19 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: aedea5910ce44fea79e2c517bb22e0006372156f
refs/heads/master: 254bb5503611da57240ed6df1cfe6d7f0f185027
25 changes: 7 additions & 18 deletions trunk/drivers/ide/ppc/pmac.c
Original file line number Diff line number Diff line change
Expand Up @@ -1593,24 +1593,10 @@ pmac_ide_destroy_dmatable (ide_drive_t *drive)
static int
pmac_ide_dma_check(ide_drive_t *drive)
{
int enable = 1;
if (ide_tune_dma(drive))
return 0;

drive->using_dma = 0;

if (drive->media == ide_floppy)
enable = 0;
if ((drive->id->capability & 1) == 0 && !__ide_dma_good_drive(drive))
enable = 0;
if (__ide_dma_bad_drive(drive))
enable = 0;

if (enable) {
u8 mode = ide_max_dma_mode(drive);

if (mode && pmac_ide_tune_chipset(drive, mode) == 0)
drive->using_dma = 1;
}
return 0;
return -1;
}

/*
Expand Down Expand Up @@ -1844,7 +1830,10 @@ pmac_ide_setup_dma(pmac_ide_hwif_t *pmif, ide_hwif_t *hwif)
hwif->mwdma_mask = 0x07;
hwif->swdma_mask = 0x00;
break;
}
}

hwif->autodma = 1;
hwif->drives[1].autodma = hwif->drives[0].autodma = hwif->autodma;
}

#endif /* CONFIG_BLK_DEV_IDEDMA_PMAC */

0 comments on commit cc90081

Please sign in to comment.