From: Bartlomiej Zolnierkiewicz Date: Sat, 17 Feb 2007 01:40:20 +0000 (+0100) Subject: atiixp/jmicron/triflex: fix PIO fallback X-Git-Tag: v2.6.21-rc1~78^2~28 X-Git-Url: http://git.openpandora.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=39baf8a798926eb675c9360d5822ca86ed92866e;p=pandora-kernel.git atiixp/jmicron/triflex: fix PIO fallback * atiixp: if DMA can't be used atiixp_config_drive_for_dma() should return 0, atiixp_dma_check() will tune the correct PIO mode anyway * jmicron: if DMA can't be used config_chipset_for_dma() should return 0, micron_config_drive_for_dma() will tune the correct PIO mode anyway config_jmicron_chipset_for_pio(drive, !speed) doesn't program device transfer mode for speed != 0 (only wastes some CPU cycles on ide_get_best_pio_mode() call) so remove it * triflex: if DMA can't be used triflex_config_drive_for_dma() should return 0, triflex_config_drive_xfer_rate() will tune correct PIO mode anyway Above changes also fix (theoretical) issue when ->speedproc fails to set device transfer mode (i.e. when ide_config_drive_speed() fails to program it) but one of DMA transfer modes is already enabled on the device by the BIOS. In such scenario ide_dma_enable() will incorrectly return true statement and ->ide_dma_check will try to enable DMA on the device. Signed-off-by: Bartlomiej Zolnierkiewicz --- Reading git-diff-tree failed