diff options
author | Bartlomiej Zolnierkiewicz <bzolnier@gmail.com> | 2007-02-16 20:40:23 -0500 |
---|---|---|
committer | Bartlomiej Zolnierkiewicz <bzolnier@gmail.com> | 2007-02-16 20:40:23 -0500 |
commit | a523a1759a8b864ea3a7aff9ea4949dcdc4bc3b6 (patch) | |
tree | 5f146bfc85b7f427fcf9107dec45bffd96caa922 /drivers/ide/mips/au1xxx-ide.c | |
parent | 572543d8b410c9734b530e811139120e36371ebd (diff) |
au1xxx-ide: remove dead code
'speed' is always equal to 'mode' when ide_config_drive_speed() is called
Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
Diffstat (limited to 'drivers/ide/mips/au1xxx-ide.c')
-rw-r--r-- | drivers/ide/mips/au1xxx-ide.c | 15 |
1 files changed, 3 insertions, 12 deletions
diff --git a/drivers/ide/mips/au1xxx-ide.c b/drivers/ide/mips/au1xxx-ide.c index c7854ea57b52..3c4f71afeeba 100644 --- a/drivers/ide/mips/au1xxx-ide.c +++ b/drivers/ide/mips/au1xxx-ide.c | |||
@@ -181,12 +181,6 @@ static int auide_tune_chipset (ide_drive_t *drive, u8 speed) | |||
181 | { | 181 | { |
182 | int mem_sttime; | 182 | int mem_sttime; |
183 | int mem_stcfg; | 183 | int mem_stcfg; |
184 | unsigned long mode; | ||
185 | |||
186 | #ifdef CONFIG_BLK_DEV_IDE_AU1XXX_MDMA2_DBDMA | ||
187 | if (ide_use_dma(drive)) | ||
188 | mode = ide_dma_speed(drive, 0); | ||
189 | #endif | ||
190 | 184 | ||
191 | mem_sttime = 0; | 185 | mem_sttime = 0; |
192 | mem_stcfg = au_readl(MEM_STCFG2); | 186 | mem_stcfg = au_readl(MEM_STCFG2); |
@@ -195,7 +189,7 @@ static int auide_tune_chipset (ide_drive_t *drive, u8 speed) | |||
195 | auide_tune_drive(drive, speed - XFER_PIO_0); | 189 | auide_tune_drive(drive, speed - XFER_PIO_0); |
196 | return 0; | 190 | return 0; |
197 | } | 191 | } |
198 | 192 | ||
199 | switch(speed) { | 193 | switch(speed) { |
200 | #ifdef CONFIG_BLK_DEV_IDE_AU1XXX_MDMA2_DBDMA | 194 | #ifdef CONFIG_BLK_DEV_IDE_AU1XXX_MDMA2_DBDMA |
201 | case XFER_MW_DMA_2: | 195 | case XFER_MW_DMA_2: |
@@ -207,7 +201,6 @@ static int auide_tune_chipset (ide_drive_t *drive, u8 speed) | |||
207 | mem_stcfg &= ~TOECS_MASK; | 201 | mem_stcfg &= ~TOECS_MASK; |
208 | mem_stcfg |= SBC_IDE_MDMA2_TCSOE | SBC_IDE_MDMA2_TOECS; | 202 | mem_stcfg |= SBC_IDE_MDMA2_TCSOE | SBC_IDE_MDMA2_TOECS; |
209 | 203 | ||
210 | mode = XFER_MW_DMA_2; | ||
211 | break; | 204 | break; |
212 | case XFER_MW_DMA_1: | 205 | case XFER_MW_DMA_1: |
213 | mem_sttime = SBC_IDE_TIMING(MDMA1); | 206 | mem_sttime = SBC_IDE_TIMING(MDMA1); |
@@ -218,7 +211,6 @@ static int auide_tune_chipset (ide_drive_t *drive, u8 speed) | |||
218 | mem_stcfg &= ~TOECS_MASK; | 211 | mem_stcfg &= ~TOECS_MASK; |
219 | mem_stcfg |= SBC_IDE_MDMA1_TCSOE | SBC_IDE_MDMA1_TOECS; | 212 | mem_stcfg |= SBC_IDE_MDMA1_TCSOE | SBC_IDE_MDMA1_TOECS; |
220 | 213 | ||
221 | mode = XFER_MW_DMA_1; | ||
222 | break; | 214 | break; |
223 | case XFER_MW_DMA_0: | 215 | case XFER_MW_DMA_0: |
224 | mem_sttime = SBC_IDE_TIMING(MDMA0); | 216 | mem_sttime = SBC_IDE_TIMING(MDMA0); |
@@ -229,14 +221,13 @@ static int auide_tune_chipset (ide_drive_t *drive, u8 speed) | |||
229 | mem_stcfg &= ~TOECS_MASK; | 221 | mem_stcfg &= ~TOECS_MASK; |
230 | mem_stcfg |= SBC_IDE_MDMA0_TCSOE | SBC_IDE_MDMA0_TOECS; | 222 | mem_stcfg |= SBC_IDE_MDMA0_TCSOE | SBC_IDE_MDMA0_TOECS; |
231 | 223 | ||
232 | mode = XFER_MW_DMA_0; | ||
233 | break; | 224 | break; |
234 | #endif | 225 | #endif |
235 | default: | 226 | default: |
236 | return 1; | 227 | return 1; |
237 | } | 228 | } |
238 | 229 | ||
239 | if (ide_config_drive_speed(drive, mode)) | 230 | if (ide_config_drive_speed(drive, speed)) |
240 | return 1; | 231 | return 1; |
241 | 232 | ||
242 | au_writel(mem_sttime,MEM_STTIME2); | 233 | au_writel(mem_sttime,MEM_STTIME2); |