OSDN Git Service
(root)
/
uclinux-h8
/
linux.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
0a8348d
)
[PATCH] it821x: fix ide dma setup bug
author
Jens Axboe
<axboe@suse.de>
Fri, 28 Jul 2006 07:02:17 +0000
(09:02 +0200)
committer
Jens Axboe
<axboe@suse.de>
Fri, 28 Jul 2006 07:02:17 +0000
(09:02 +0200)
Only enable dma for a valid speed setting.
Signed-off-by: Jens Axboe <axboe@suse.de>
drivers/ide/pci/it821x.c
patch
|
blob
|
history
diff --git
a/drivers/ide/pci/it821x.c
b/drivers/ide/pci/it821x.c
index
3cb0442
..
e9bad18
100644
(file)
--- a/
drivers/ide/pci/it821x.c
+++ b/
drivers/ide/pci/it821x.c
@@
-498,9
+498,14
@@
static int config_chipset_for_dma (ide_drive_t *drive)
{
u8 speed = ide_dma_speed(drive, it821x_ratemask(drive));
- config_it821x_chipset_for_pio(drive, !speed);
- it821x_tune_chipset(drive, speed);
- return ide_dma_enable(drive);
+ if (speed) {
+ config_it821x_chipset_for_pio(drive, 0);
+ it821x_tune_chipset(drive, speed);
+
+ return ide_dma_enable(drive);
+ }
+
+ return 0;
}
/**