• Home
  • History
  • Annotate
  • Raw
  • Download
  • only in /netgear-R7000-V1.0.7.12_1.2.5/components/opensource/linux/linux-2.6.36/drivers/ide/

Lines Matching refs:index

161  * Registers and masks for easy access by drive index:
398 static void __init check_prefetch(ide_drive_t *drive, unsigned int index)
400 u8 b = get_cmd640_reg(prefetch_regs[index]);
402 __set_prefetch_mode(drive, (b & prefetch_masks[index]) ? 0 : 1);
409 static void set_prefetch_mode(ide_drive_t *drive, unsigned int index, int mode)
412 int reg = prefetch_regs[index];
419 b &= ~prefetch_masks[index]; /* enable prefetch */
421 b |= prefetch_masks[index]; /* disable prefetch */
429 static void display_clocks(unsigned int index)
433 active_count = active_counts[index];
436 recovery_count = recovery_counts[index];
441 printk(", clocks=%d/%d/%d\n", setup_counts[index], active_count, recovery_count);
457 static void program_drive_counts(ide_drive_t *drive, unsigned int index)
460 u8 setup_count = setup_counts[index];
461 u8 active_count = active_counts[index];
462 u8 recovery_count = recovery_counts[index];
470 if (index > 1) {
472 unsigned int mate = index ^ 1;
504 setup_count |= __get_cmd640_reg(arttim_regs[index]) & 0x3f;
505 __put_cmd640_reg(arttim_regs[index], setup_count);
506 __put_cmd640_reg(drwtim_regs[index], pack_nibbles(active_count, recovery_count));
513 static void cmd640_set_mode(ide_drive_t *drive, unsigned int index,
560 setup_counts[index] = setup_count;
561 active_counts[index] = active_count;
562 recovery_counts[index] = recovery_count;
572 program_drive_counts(drive, index);
577 unsigned int index = 0, cycle_time;
593 set_prefetch_mode(drive, index, pio & 1);
600 cmd640_set_mode(drive, index, pio, cycle_time);
605 display_clocks(index);