• Home
  • History
  • Annotate
  • Raw
  • Download
  • only in /asus-wl-520gu-7.0.1.45/src/linux/linux/drivers/ide/

Lines Matching defs:drive

40  * ASK@1998-10-31: v0.31 fixed problem with setting to high DMA modes on some drive
184 static void cy82c693_dma_enable (ide_drive_t *drive, int mode, int single)
192 if (mode > drive->id->tDMA) /* to be absolutly sure we have a valid mode */
193 mode = drive->id->tDMA;
195 index = (HWIF(drive)->channel==0) ? CY82_INDEX_CHANNEL0 : CY82_INDEX_CHANNEL1;
203 printk (KERN_INFO "%s (ch=%d, dev=%d): DMA mode is %d (single=%d)\n", drive->name, HWIF(drive)->channel, drive->select.b.unit, (data&0x3), ((data>>2)&1));
212 printk (KERN_INFO "%s (ch=%d, dev=%d): set DMA mode to %d (single=%d)\n", drive->name, HWIF(drive)->channel, drive->select.b.unit, mode, single);
230 printk (KERN_INFO "%s: Set IDE Bus Master TimeOut Register to 0x%X\n", drive->name, data);
237 static int cy82c693_dmaproc(ide_dma_action_t func, ide_drive_t *drive)
240 * if the function is dma on, set dma mode for drive everything
244 struct hd_driveid *id = drive->id;
247 printk (KERN_INFO "dma_on: %s\n", drive->name);
251 /* Enable DMA on any drive that has DMA (multi or single) enabled */
259 cy82c693_dma_enable(drive, (mmode >> 1), 0); /* enable multi */
261 cy82c693_dma_enable(drive, (smode >> 1), 1); /* enable single */
265 return ide_dmaproc(func, drive);
270 * tune ide drive - set PIO mode
272 static void cy82c693_tune_drive (ide_drive_t *drive, byte pio)
274 ide_hwif_t *hwif = HWIF(drive);
280 if (hwif->index > 0) { /* drive is on the secondary channel */
283 printk(KERN_ERR "%s: tune_drive: Cannot find secondary interface!\n", drive->name);
291 if (drive->select.b.unit == 0) {
293 * get master drive registers
306 * set slave drive registers
321 printk (KERN_INFO "%s (ch=%d, dev=%d): PIO timing is (addr=0x%X, ior=0x%X, iow=0x%X, 8bit=0x%X)\n", drive->name, hwif->channel, drive->select.b.unit, addrCtrl, pclk.time_16r, pclk.time_16w, pclk.time_8);
325 pio = ide_get_best_pio_mode(drive, pio, CY82C693_MAX_PIO, NULL);
328 printk (KERN_INFO "%s: Selected PIO mode %d\n", drive->name, pio);
334 if (drive->select.b.unit == 0) {
336 * set master drive
354 * set slave drive
374 printk (KERN_INFO "%s (ch=%d, dev=%d): set PIO timing to (addr=0x%X, ior=0x%X, iow=0x%X, 8bit=0x%X)\n", drive->name, hwif->channel, drive->select.b.unit, addrCtrl, pclk.time_16r, pclk.time_16w, pclk.time_8);