Home
last modified time | relevance | path

Searched refs:drive (Results 1 – 200 of 462) sorted by relevance

123

/linux-4.4.14/drivers/ide/
Dide-dma.c91 ide_startstop_t ide_dma_intr(ide_drive_t *drive) in ide_dma_intr() argument
93 ide_hwif_t *hwif = drive->hwif; in ide_dma_intr()
97 drive->waiting_for_dma = 0; in ide_dma_intr()
98 dma_stat = hwif->dma_ops->dma_end(drive); in ide_dma_intr()
99 ide_dma_unmap_sg(drive, cmd); in ide_dma_intr()
102 if (OK_STAT(stat, DRIVE_READY, drive->bad_wstat | ATA_DRQ)) { in ide_dma_intr()
105 ide_finish_cmd(drive, cmd, stat); in ide_dma_intr()
107 ide_complete_rq(drive, 0, in ide_dma_intr()
112 drive->name, __func__, dma_stat); in ide_dma_intr()
114 return ide_error(drive, "dma_intr", stat); in ide_dma_intr()
[all …]
Dide-disk.c55 static void ide_tf_set_cmd(ide_drive_t *drive, struct ide_cmd *cmd, u8 dma) in ide_tf_set_cmd() argument
67 if (drive->mult_count) { in ide_tf_set_cmd()
81 static ide_startstop_t __ide_do_rw_disk(ide_drive_t *drive, struct request *rq, in __ide_do_rw_disk() argument
84 ide_hwif_t *hwif = drive->hwif; in __ide_do_rw_disk()
86 u8 lba48 = !!(drive->dev_flags & IDE_DFLAG_LBA48); in __ide_do_rw_disk()
87 u8 dma = !!(drive->dev_flags & IDE_DFLAG_USING_DMA); in __ide_do_rw_disk()
103 if (drive->dev_flags & IDE_DFLAG_LBA) { in __ide_do_rw_disk()
105 pr_debug("%s: LBA=0x%012llx\n", drive->name, in __ide_do_rw_disk()
135 track = (int)block / drive->sect; in __ide_do_rw_disk()
136 sect = (int)block % drive->sect + 1; in __ide_do_rw_disk()
[all …]
Dide-atapi.c27 static inline int dev_is_idecd(ide_drive_t *drive) in dev_is_idecd() argument
29 return drive->media == ide_cdrom || drive->media == ide_optical; in dev_is_idecd()
36 int ide_check_atapi_device(ide_drive_t *drive, const char *s) in ide_check_atapi_device() argument
38 u16 *id = drive->id; in ide_check_atapi_device()
51 if (drive->media == ide_floppy && device_type == 5 && in ide_check_atapi_device()
59 s, drive->name, protocol); in ide_check_atapi_device()
60 else if ((drive->media == ide_floppy && device_type != 0) || in ide_check_atapi_device()
61 (drive->media == ide_tape && device_type != 1)) in ide_check_atapi_device()
63 s, drive->name, device_type); in ide_check_atapi_device()
66 s, drive->name); in ide_check_atapi_device()
[all …]
Dide-gd.c40 if (ide_device_get(idkp->drive)) in ide_disk_get()
51 ide_drive_t *drive = idkp->drive; in ide_disk_put() local
55 ide_device_put(drive); in ide_disk_put()
59 sector_t ide_gd_capacity(ide_drive_t *drive) in ide_gd_capacity() argument
61 return drive->capacity64; in ide_gd_capacity()
66 static void ide_gd_remove(ide_drive_t *drive) in ide_gd_remove() argument
68 struct ide_disk_obj *idkp = drive->driver_data; in ide_gd_remove()
71 ide_proc_unregister_driver(drive, idkp->driver); in ide_gd_remove()
74 drive->disk_ops->flush(drive); in ide_gd_remove()
84 ide_drive_t *drive = idkp->drive; in ide_disk_release() local
[all …]
Dide-eh.c7 static ide_startstop_t ide_ata_error(ide_drive_t *drive, struct request *rq, in ide_ata_error() argument
10 ide_hwif_t *hwif = drive->hwif; in ide_ata_error()
13 ((stat & ATA_DF) && (drive->dev_flags & IDE_DFLAG_NOWERR) == 0)) { in ide_ata_error()
19 if ((drive->dev_flags & IDE_DFLAG_LBA) && in ide_ata_error()
25 drive->crc_count++; in ide_ata_error()
37 int nsect = drive->mult_count ? drive->mult_count : 1; in ide_ata_error()
39 ide_pad_transfer(drive, READ, nsect * SECTOR_SIZE); in ide_ata_error()
43 ide_kill_rq(drive, rq); in ide_ata_error()
52 return ide_do_reset(drive); in ide_ata_error()
56 drive->special_flags |= IDE_SFLAG_RECALIBRATE; in ide_ata_error()
[all …]
Dide-io.c57 int ide_end_rq(ide_drive_t *drive, struct request *rq, int error, in ide_end_rq() argument
64 if ((drive->dev_flags & IDE_DFLAG_DMA_PIO_RETRY) && in ide_end_rq()
65 drive->retry_pio <= 3) { in ide_end_rq()
66 drive->dev_flags &= ~IDE_DFLAG_DMA_PIO_RETRY; in ide_end_rq()
67 ide_dma_on(drive); in ide_end_rq()
74 void ide_complete_cmd(ide_drive_t *drive, struct ide_cmd *cmd, u8 stat, u8 err) in ide_complete_cmd() argument
76 const struct ide_tp_ops *tp_ops = drive->hwif->tp_ops; in ide_complete_cmd()
87 tp_ops->input_data(drive, cmd, data, 2); in ide_complete_cmd()
93 ide_tf_readback(drive, cmd); in ide_complete_cmd()
99 drive->name); in ide_complete_cmd()
[all …]
Dide-probe.c51 static void generic_id(ide_drive_t *drive) in generic_id() argument
53 u16 *id = drive->id; in generic_id()
55 id[ATA_ID_CUR_CYLS] = id[ATA_ID_CYLS] = drive->cyl; in generic_id()
56 id[ATA_ID_CUR_HEADS] = id[ATA_ID_HEADS] = drive->head; in generic_id()
57 id[ATA_ID_CUR_SECTORS] = id[ATA_ID_SECTORS] = drive->sect; in generic_id()
60 static void ide_disk_init_chs(ide_drive_t *drive) in ide_disk_init_chs() argument
62 u16 *id = drive->id; in ide_disk_init_chs()
65 if (!drive->cyl || !drive->head || !drive->sect) { in ide_disk_init_chs()
66 drive->cyl = drive->bios_cyl = id[ATA_ID_CYLS]; in ide_disk_init_chs()
67 drive->head = drive->bios_head = id[ATA_ID_HEADS]; in ide_disk_init_chs()
[all …]
Dide-floppy.c62 static int ide_floppy_callback(ide_drive_t *drive, int dsc) in ide_floppy_callback() argument
64 struct ide_disk_obj *floppy = drive->driver_data; in ide_floppy_callback()
65 struct ide_atapi_pc *pc = drive->pc; in ide_floppy_callback()
71 if (drive->failed_pc == pc) in ide_floppy_callback()
72 drive->failed_pc = NULL; in ide_floppy_callback()
88 if (drive->failed_pc) in ide_floppy_callback()
90 drive->failed_pc->c[0]); in ide_floppy_callback()
117 floppy->drive->name, pc->c[0], floppy->sense_key, in ide_floppy_report_error()
122 static ide_startstop_t ide_floppy_issue_pc(ide_drive_t *drive, in ide_floppy_issue_pc() argument
126 struct ide_disk_obj *floppy = drive->driver_data; in ide_floppy_issue_pc()
[all …]
Dide-tape.c141 ide_drive_t *drive; member
244 if (ide_device_get(tape->drive)) in ide_tape_get()
256 ide_drive_t *drive = tape->drive; in ide_tape_put() local
260 ide_device_put(drive); in ide_tape_put()
268 static void idetape_analyze_error(ide_drive_t *drive) in idetape_analyze_error() argument
270 idetape_tape_t *tape = drive->driver_data; in idetape_analyze_error()
271 struct ide_atapi_pc *pc = drive->failed_pc; in idetape_analyze_error()
272 struct request *rq = drive->hwif->rq; in idetape_analyze_error()
326 static int ide_tape_callback(ide_drive_t *drive, int dsc) in ide_tape_callback() argument
328 idetape_tape_t *tape = drive->driver_data; in ide_tape_callback()
[all …]
Dide-iops.c30 void SELECT_MASK(ide_drive_t *drive, int mask) in SELECT_MASK() argument
32 const struct ide_port_ops *port_ops = drive->hwif->port_ops; in SELECT_MASK()
35 port_ops->maskproc(drive, mask); in SELECT_MASK()
38 u8 ide_read_error(ide_drive_t *drive) in ide_read_error() argument
42 drive->hwif->tp_ops->tf_read(drive, &tf, IDE_VALID_ERROR); in ide_read_error()
105 int __ide_wait_stat(ide_drive_t *drive, u8 good, u8 bad, in __ide_wait_stat() argument
108 ide_hwif_t *hwif = drive->hwif; in __ide_wait_stat()
164 int ide_wait_stat(ide_startstop_t *startstop, ide_drive_t *drive, u8 good, in ide_wait_stat() argument
171 if (drive->max_failures && (drive->failures > drive->max_failures)) { in ide_wait_stat()
176 err = __ide_wait_stat(drive, good, bad, timeout, &stat); in ide_wait_stat()
[all …]
Dide-xfer-mode.c62 static u8 ide_get_best_pio_mode(ide_drive_t *drive, u8 mode_wanted, u8 max_mode) in ide_get_best_pio_mode() argument
64 u16 *id = drive->id; in ide_get_best_pio_mode()
70 if ((drive->hwif->host_flags & IDE_HFLAG_PIO_NO_BLACKLIST) == 0) in ide_get_best_pio_mode()
74 printk(KERN_INFO "%s: is on PIO blacklist\n", drive->name); in ide_get_best_pio_mode()
101 drive->name); in ide_get_best_pio_mode()
110 int ide_pio_need_iordy(ide_drive_t *drive, const u8 pio) in ide_pio_need_iordy() argument
116 if (pio == 0 && (drive->hwif->port_flags & IDE_PFLAG_PROBING)) in ide_pio_need_iordy()
118 return ata_id_pio_need_iordy(drive->id, pio); in ide_pio_need_iordy()
122 int ide_set_pio_mode(ide_drive_t *drive, const u8 mode) in ide_set_pio_mode() argument
124 ide_hwif_t *hwif = drive->hwif; in ide_set_pio_mode()
[all …]
Dide-cd.c65 if (ide_device_get(cd->drive)) in ide_cd_get()
77 ide_drive_t *drive = cd->drive; in ide_cd_put() local
81 ide_device_put(drive); in ide_cd_put()
90 static void cdrom_saw_media_change(ide_drive_t *drive) in cdrom_saw_media_change() argument
92 drive->dev_flags |= IDE_DFLAG_MEDIA_CHANGED; in cdrom_saw_media_change()
93 drive->atapi_flags &= ~IDE_AFLAG_TOC_VALID; in cdrom_saw_media_change()
96 static int cdrom_log_sense(ide_drive_t *drive, struct request *rq) in cdrom_log_sense() argument
98 struct request_sense *sense = &drive->sense_data; in cdrom_log_sense()
134 cdrom_saw_media_change(drive); in cdrom_log_sense()
143 static void cdrom_analyze_sense_data(ide_drive_t *drive, in cdrom_analyze_sense_data() argument
[all …]
Dide-cd_ioctl.c30 ide_drive_t *drive = cdi->handle; in ide_cdrom_release_real() local
33 drive->atapi_flags &= ~IDE_AFLAG_TOC_VALID; in ide_cdrom_release_real()
43 ide_drive_t *drive = cdi->handle; in ide_cdrom_drive_status() local
51 stat = cdrom_check_status(drive, &sense); in ide_cdrom_drive_status()
91 ide_drive_t *drive = cdi->handle; in ide_cdrom_check_events_real() local
95 (void) cdrom_check_status(drive, NULL); in ide_cdrom_check_events_real()
96 retval = (drive->dev_flags & IDE_DFLAG_MEDIA_CHANGED) ? 1 : 0; in ide_cdrom_check_events_real()
97 drive->dev_flags &= ~IDE_DFLAG_MEDIA_CHANGED; in ide_cdrom_check_events_real()
107 int cdrom_eject(ide_drive_t *drive, int ejectflag, in cdrom_eject() argument
110 struct cdrom_info *cd = drive->driver_data; in cdrom_eject()
[all …]
Dide-pm.c7 ide_drive_t *drive = to_ide_device(dev); in generic_ide_suspend() local
8 ide_drive_t *pair = ide_get_pair_dev(drive); in generic_ide_suspend()
9 ide_hwif_t *hwif = drive->hwif; in generic_ide_suspend()
16 if ((drive->dn & 1) == 0 || pair == NULL) in generic_ide_suspend()
21 rq = blk_get_request(drive->queue, READ, __GFP_RECLAIM); in generic_ide_suspend()
29 ret = blk_execute_rq(drive->queue, NULL, rq, 0); in generic_ide_suspend()
34 if ((drive->dn & 1) || pair == NULL) in generic_ide_suspend()
73 ide_drive_t *drive = to_ide_device(dev); in generic_ide_resume() local
74 ide_drive_t *pair = ide_get_pair_dev(drive); in generic_ide_resume()
75 ide_hwif_t *hwif = drive->hwif; in generic_ide_resume()
[all …]
Dide.c71 int ide_device_get(ide_drive_t *drive) in ide_device_get() argument
76 if (!get_device(&drive->gendev)) in ide_device_get()
79 host_dev = drive->hwif->host->dev[0]; in ide_device_get()
83 put_device(&drive->gendev); in ide_device_get()
98 void ide_device_put(ide_drive_t *drive) in ide_device_put() argument
101 struct device *host_dev = drive->hwif->host->dev[0]; in ide_device_put()
106 put_device(&drive->gendev); in ide_device_put()
117 ide_drive_t *drive = to_ide_device(dev); in ide_uevent() local
119 add_uevent_var(env, "MEDIA=%s", ide_media_string(drive)); in ide_uevent()
120 add_uevent_var(env, "DRIVENAME=%s", drive->name); in ide_uevent()
[all …]
Dide-taskfile.c27 void ide_tf_readback(ide_drive_t *drive, struct ide_cmd *cmd) in ide_tf_readback() argument
29 ide_hwif_t *hwif = drive->hwif; in ide_tf_readback()
35 tp_ops->tf_read(drive, &cmd->tf, cmd->valid.in.tf); in ide_tf_readback()
40 tp_ops->tf_read(drive, &cmd->hob, cmd->valid.in.hob); in ide_tf_readback()
57 int taskfile_lib_get_identify(ide_drive_t *drive, u8 *buf) in taskfile_lib_get_identify() argument
63 if (drive->media == ide_disk) in taskfile_lib_get_identify()
71 return ide_raw_taskfile(drive, &cmd, buf, 1); in taskfile_lib_get_identify()
78 ide_startstop_t do_rw_taskfile(ide_drive_t *drive, struct ide_cmd *orig_cmd) in do_rw_taskfile() argument
80 ide_hwif_t *hwif = drive->hwif; in do_rw_taskfile()
89 drive->mult_count == 0) { in do_rw_taskfile()
[all …]
Dide-devsets.c10 static int set_io_32bit(ide_drive_t *drive, int arg) in set_io_32bit() argument
12 if (drive->dev_flags & IDE_DFLAG_NO_IO_32BIT) in set_io_32bit()
18 drive->io_32bit = arg; in set_io_32bit()
25 static int set_ksettings(ide_drive_t *drive, int arg) in set_ksettings() argument
31 drive->dev_flags |= IDE_DFLAG_KEEP_SETTINGS; in set_ksettings()
33 drive->dev_flags &= ~IDE_DFLAG_KEEP_SETTINGS; in set_ksettings()
40 static int set_using_dma(ide_drive_t *drive, int arg) in set_using_dma() argument
48 if (ata_id_has_dma(drive->id) == 0) in set_using_dma()
51 if (drive->hwif->dma_ops == NULL) in set_using_dma()
57 if (ide_set_dma(drive)) in set_using_dma()
[all …]
Dht6560b.c47 static inline u8 HT_CONFIG(ide_drive_t *drive) in HT_CONFIG() argument
49 return ((unsigned long)ide_get_drivedata(drive) & 0xff00) >> 8; in HT_CONFIG()
97 static inline u8 HT_TIMING(ide_drive_t *drive) in HT_TIMING() argument
99 return (unsigned long)ide_get_drivedata(drive) & 0x00ff; in HT_TIMING()
114 static void ht6560b_dev_select(ide_drive_t *drive) in ht6560b_dev_select() argument
116 ide_hwif_t *hwif = drive->hwif; in ht6560b_dev_select()
124 select = HT_CONFIG(drive); in ht6560b_dev_select()
125 timing = HT_TIMING(drive); in ht6560b_dev_select()
131 if (drive->media != ide_disk || in ht6560b_dev_select()
132 (drive->dev_flags & IDE_DFLAG_PRESENT) == 0) in ht6560b_dev_select()
[all …]
Dide-floppy_ioctl.c36 static int ide_floppy_get_format_capacities(ide_drive_t *drive, in ide_floppy_get_format_capacities() argument
40 struct ide_disk_obj *floppy = drive->driver_data; in ide_floppy_get_format_capacities()
53 if (ide_queue_pc_tail(drive, floppy->disk, pc, pc_buf, pc->req_xfer)) { in ide_floppy_get_format_capacities()
119 static int ide_floppy_get_sfrp_bit(ide_drive_t *drive, struct ide_atapi_pc *pc) in ide_floppy_get_sfrp_bit() argument
121 struct ide_disk_obj *floppy = drive->driver_data; in ide_floppy_get_sfrp_bit()
124 drive->atapi_flags &= ~IDE_AFLAG_SRFP; in ide_floppy_get_sfrp_bit()
129 if (ide_queue_pc_tail(drive, floppy->disk, pc, buf, pc->req_xfer)) in ide_floppy_get_sfrp_bit()
133 drive->atapi_flags |= IDE_AFLAG_SRFP; in ide_floppy_get_sfrp_bit()
138 static int ide_floppy_format_unit(ide_drive_t *drive, struct ide_atapi_pc *pc, in ide_floppy_format_unit() argument
141 struct ide_disk_obj *floppy = drive->driver_data; in ide_floppy_format_unit()
[all …]
Dqd65xx.c92 static void qd65xx_dev_select(ide_drive_t *drive) in qd65xx_dev_select() argument
94 u8 index = (( (QD_TIMREG(drive)) & 0x80 ) >> 7) | in qd65xx_dev_select()
95 (QD_TIMREG(drive) & 0x02); in qd65xx_dev_select()
97 if (timings[index] != QD_TIMING(drive)) in qd65xx_dev_select()
98 outb(timings[index] = QD_TIMING(drive), QD_TIMREG(drive)); in qd65xx_dev_select()
100 outb(drive->select | ATA_DEVICE_OBS, drive->hwif->io_ports.device_addr); in qd65xx_dev_select()
150 static int qd_find_disk_type (ide_drive_t *drive, in qd_find_disk_type() argument
154 char *m = (char *)&drive->id[ATA_ID_PROD]; in qd_find_disk_type()
165 printk(KERN_DEBUG "%s: listed !\n", drive->name); in qd_find_disk_type()
180 static void qd_set_timing (ide_drive_t *drive, u8 timing) in qd_set_timing() argument
[all …]
Dsl82c105.c42 static unsigned int get_pio_timings(ide_drive_t *drive, u8 pio) in get_pio_timings() argument
49 cmd_off = (ide_pio_cycle_time(drive, pio) - 30 * cmd_on + 29) / 30; in get_pio_timings()
57 if (ide_pio_need_iordy(drive, pio)) in get_pio_timings()
66 static void sl82c105_set_pio_mode(ide_hwif_t *hwif, ide_drive_t *drive) in sl82c105_set_pio_mode() argument
69 unsigned long timings = (unsigned long)ide_get_drivedata(drive); in sl82c105_set_pio_mode()
70 int reg = 0x44 + drive->dn * 4; in sl82c105_set_pio_mode()
72 const u8 pio = drive->pio_mode - XFER_PIO_0; in sl82c105_set_pio_mode()
74 drv_ctrl = get_pio_timings(drive, pio); in sl82c105_set_pio_mode()
82 ide_set_drivedata(drive, (void *)timings); in sl82c105_set_pio_mode()
87 printk(KERN_DEBUG "%s: selected %s (%dns) (%04X)\n", drive->name, in sl82c105_set_pio_mode()
[all …]
Dide-ioctls.c19 int ide_setting_ioctl(ide_drive_t *drive, struct block_device *bdev, in ide_setting_ioctl() argument
37 err = ds->get(drive); in ide_setting_ioctl()
49 err = ide_devset_execute(drive, ds, arg); in ide_setting_ioctl()
57 static int ide_get_identity_ioctl(ide_drive_t *drive, unsigned int cmd, in ide_get_identity_ioctl() argument
64 if ((drive->dev_flags & IDE_DFLAG_ID_READ) == 0) { in ide_get_identity_ioctl()
76 memcpy(id, drive->id, size); in ide_get_identity_ioctl()
87 static int ide_get_nice_ioctl(ide_drive_t *drive, unsigned long arg) in ide_get_nice_ioctl() argument
89 return put_user((!!(drive->dev_flags & IDE_DFLAG_DSC_OVERLAP) in ide_get_nice_ioctl()
91 (!!(drive->dev_flags & IDE_DFLAG_NICE1) in ide_get_nice_ioctl()
95 static int ide_set_nice_ioctl(ide_drive_t *drive, unsigned long arg) in ide_set_nice_ioctl() argument
[all …]
Dide-park.c9 static void issue_park_cmd(ide_drive_t *drive, unsigned long timeout) in issue_park_cmd() argument
11 ide_hwif_t *hwif = drive->hwif; in issue_park_cmd()
12 struct request_queue *q = drive->queue; in issue_park_cmd()
18 if (drive->dev_flags & IDE_DFLAG_PARKED) { in issue_park_cmd()
19 int reset_timer = time_before(timeout, drive->sleep); in issue_park_cmd()
22 drive->sleep = timeout; in issue_park_cmd()
61 ide_startstop_t ide_do_park_unpark(ide_drive_t *drive, struct request *rq) in ide_do_park_unpark() argument
68 drive->sleep = *(unsigned long *)rq->special; in ide_do_park_unpark()
69 drive->dev_flags |= IDE_DFLAG_SLEEPING; in ide_do_park_unpark()
85 return do_rw_taskfile(drive, &cmd); in ide_do_park_unpark()
[all …]
Dide-proc.c119 ide_drive_t *drive = (ide_drive_t *)m->private; in ide_identify_proc_show() local
122 if (!drive) { in ide_identify_proc_show()
130 if (taskfile_lib_get_identify(drive, buf) == 0) { in ide_identify_proc_show()
192 static int ide_read_setting(ide_drive_t *drive, in ide_read_setting() argument
199 val = ds->get(drive); in ide_read_setting()
222 static int ide_write_setting(ide_drive_t *drive, in ide_write_setting() argument
234 return ide_devset_execute(drive, ds, val); in ide_write_setting()
239 static int set_xfer_rate (ide_drive_t *drive, int arg) in set_xfer_rate() argument
254 return ide_no_data_taskfile(drive, &cmd); in set_xfer_rate()
285 ide_drive_t *drive = (ide_drive_t *) m->private; in ide_settings_proc_show() local
[all …]
Dit821x.c112 static void it821x_program(ide_drive_t *drive, u16 timing) in it821x_program() argument
114 ide_hwif_t *hwif = drive->hwif; in it821x_program()
138 static void it821x_program_udma(ide_drive_t *drive, u16 timing) in it821x_program_udma() argument
140 ide_hwif_t *hwif = drive->hwif; in it821x_program_udma()
144 u8 unit = drive->dn & 1, conf; in it821x_program_udma()
168 static void it821x_clock_strategy(ide_drive_t *drive) in it821x_clock_strategy() argument
170 ide_hwif_t *hwif = drive->hwif; in it821x_clock_strategy()
173 ide_drive_t *pair = ide_get_pair_dev(drive); in it821x_clock_strategy()
175 u8 unit = drive->dn & 1, v; in it821x_clock_strategy()
225 it821x_program_udma(drive, itdev->udma[unit]); in it821x_clock_strategy()
[all …]
Dide-lib.c18 void ide_toggle_bounce(ide_drive_t *drive, int on) in ide_toggle_bounce() argument
24 } else if (on && drive->media == ide_disk) { in ide_toggle_bounce()
25 struct device *dev = drive->hwif->dev; in ide_toggle_bounce()
31 if (drive->queue) in ide_toggle_bounce()
32 blk_queue_bounce_limit(drive->queue, addr); in ide_toggle_bounce()
51 static void ide_dump_sector(ide_drive_t *drive) in ide_dump_sector() argument
55 u8 lba48 = !!(drive->dev_flags & IDE_DFLAG_LBA48); in ide_dump_sector()
65 ide_tf_readback(drive, &cmd); in ide_dump_sector()
75 static void ide_dump_ata_error(ide_drive_t *drive, u8 err) in ide_dump_ata_error() argument
94 struct request *rq = drive->hwif->rq; in ide_dump_ata_error()
[all …]
Dcs5536.c92 static void cs5536_program_dtc(ide_drive_t *drive, u8 tim) in cs5536_program_dtc() argument
94 struct pci_dev *pdev = to_pci_dev(drive->hwif->dev); in cs5536_program_dtc()
95 int dshift = (drive->dn & 1) ? IDE_D1_SHIFT : IDE_D0_SHIFT; in cs5536_program_dtc()
132 static void cs5536_set_pio_mode(ide_hwif_t *hwif, ide_drive_t *drive) in cs5536_set_pio_mode() argument
147 ide_drive_t *pair = ide_get_pair_dev(drive); in cs5536_set_pio_mode()
148 int cshift = (drive->dn & 1) ? IDE_CAST_D1_SHIFT : IDE_CAST_D0_SHIFT; in cs5536_set_pio_mode()
149 unsigned long timings = (unsigned long)ide_get_drivedata(drive); in cs5536_set_pio_mode()
151 const u8 pio = drive->pio_mode - XFER_PIO_0; in cs5536_set_pio_mode()
159 ide_set_drivedata(drive, (void *)timings); in cs5536_set_pio_mode()
161 cs5536_program_dtc(drive, drv_timings[pio]); in cs5536_set_pio_mode()
[all …]
Dit8172.c40 static void it8172_set_pio_mode(ide_hwif_t *hwif, ide_drive_t *drive) in it8172_set_pio_mode() argument
45 const u8 pio = drive->pio_mode - XFER_PIO_0; in it8172_set_pio_mode()
65 drive_enables &= drive->dn ? 0xc006 : 0xc060; in it8172_set_pio_mode()
66 if (drive->media == ide_disk) in it8172_set_pio_mode()
68 drive_enables |= 0x0004 << (drive->dn * 4); in it8172_set_pio_mode()
69 if (ide_pio_need_iordy(drive, pio)) in it8172_set_pio_mode()
71 drive_enables |= 0x0002 << (drive->dn * 4); in it8172_set_pio_mode()
73 drive_timing &= drive->dn ? 0x00003f00 : 0x000fc000; in it8172_set_pio_mode()
74 drive_timing |= timings[pio] << (drive->dn * 6 + 8); in it8172_set_pio_mode()
80 static void it8172_set_dma_mode(ide_hwif_t *hwif, ide_drive_t *drive) in it8172_set_dma_mode() argument
[all …]
Dsis5513.c187 static u8 sis_ata133_get_base(ide_drive_t *drive) in sis_ata133_get_base() argument
189 struct pci_dev *dev = to_pci_dev(drive->hwif->dev); in sis_ata133_get_base()
194 return ((reg54 & 0x40000000) ? 0x70 : 0x40) + drive->dn * 4; in sis_ata133_get_base()
197 static void sis_ata16_program_timings(ide_drive_t *drive, const u8 mode) in sis_ata16_program_timings() argument
199 struct pci_dev *dev = to_pci_dev(drive->hwif->dev); in sis_ata16_program_timings()
201 u8 drive_pci = 0x40 + drive->dn * 2; in sis_ata16_program_timings()
220 static void sis_ata100_program_timings(ide_drive_t *drive, const u8 mode) in sis_ata100_program_timings() argument
222 struct pci_dev *dev = to_pci_dev(drive->hwif->dev); in sis_ata100_program_timings()
223 u8 t1, drive_pci = 0x40 + drive->dn * 2; in sis_ata100_program_timings()
243 static void sis_ata133_program_timings(ide_drive_t *drive, const u8 mode) in sis_ata133_program_timings() argument
[all …]
Dide-dma-sff.c20 int config_drive_for_dma(ide_drive_t *drive) in config_drive_for_dma() argument
22 ide_hwif_t *hwif = drive->hwif; in config_drive_for_dma()
23 u16 *id = drive->id; in config_drive_for_dma()
25 if (drive->media != ide_disk) { in config_drive_for_dma()
47 if (ide_dma_good_drive(drive)) in config_drive_for_dma()
82 void ide_dma_host_set(ide_drive_t *drive, int on) in ide_dma_host_set() argument
84 ide_hwif_t *hwif = drive->hwif; in ide_dma_host_set()
85 u8 unit = drive->dn & 1; in ide_dma_host_set()
114 int ide_build_dmatable(ide_drive_t *drive, struct ide_cmd *cmd) in ide_build_dmatable() argument
116 ide_hwif_t *hwif = drive->hwif; in ide_build_dmatable()
[all …]
Dtrm290.c145 static void trm290_prepare_drive (ide_drive_t *drive, unsigned int use_dma) in trm290_prepare_drive() argument
147 ide_hwif_t *hwif = drive->hwif; in trm290_prepare_drive()
164 if (drive->dev_flags & IDE_DFLAG_PRESENT) { in trm290_prepare_drive()
174 static void trm290_dev_select(ide_drive_t *drive) in trm290_dev_select() argument
176 trm290_prepare_drive(drive, !!(drive->dev_flags & IDE_DFLAG_USING_DMA)); in trm290_dev_select()
178 outb(drive->select | ATA_DEVICE_OBS, drive->hwif->io_ports.device_addr); in trm290_dev_select()
181 static int trm290_dma_check(ide_drive_t *drive, struct ide_cmd *cmd) in trm290_dma_check() argument
192 static int trm290_dma_setup(ide_drive_t *drive, struct ide_cmd *cmd) in trm290_dma_setup() argument
194 ide_hwif_t *hwif = drive->hwif; in trm290_dma_setup()
197 count = ide_build_dmatable(drive, cmd); in trm290_dma_setup()
[all …]
Dsgiioc4.c120 static int sgiioc4_clearirq(ide_drive_t *drive) in sgiioc4_clearirq() argument
123 ide_hwif_t *hwif = drive->hwif; in sgiioc4_clearirq()
160 __func__, drive->name, pci_stat_cmd_reg); in sgiioc4_clearirq()
162 __func__, drive->name, in sgiioc4_clearirq()
177 static void sgiioc4_dma_start(ide_drive_t *drive) in sgiioc4_dma_start() argument
179 ide_hwif_t *hwif = drive->hwif; in sgiioc4_dma_start()
203 static int sgiioc4_dma_end(ide_drive_t *drive) in sgiioc4_dma_end() argument
206 ide_hwif_t *hwif = drive->hwif; in sgiioc4_dma_end()
219 __func__, drive->name, ioc4_dma); in sgiioc4_dma_end()
239 drive->name); in sgiioc4_dma_end()
[all …]
Dide-sysfs.c4 char *ide_media_string(ide_drive_t *drive) in ide_media_string() argument
6 switch (drive->media) { in ide_media_string()
25 ide_drive_t *drive = to_ide_device(dev); in media_show() local
26 return sprintf(buf, "%s\n", ide_media_string(drive)); in media_show()
33 ide_drive_t *drive = to_ide_device(dev); in drivename_show() local
34 return sprintf(buf, "%s\n", drive->name); in drivename_show()
41 ide_drive_t *drive = to_ide_device(dev); in modalias_show() local
42 return sprintf(buf, "ide:m-%s\n", ide_media_string(drive)); in modalias_show()
49 ide_drive_t *drive = to_ide_device(dev); in model_show() local
50 return sprintf(buf, "%s\n", (char *)&drive->id[ATA_ID_PROD]); in model_show()
[all …]
Dsc1200.c81 static void sc1200_tunepio(ide_drive_t *drive, u8 pio) in sc1200_tunepio() argument
83 ide_hwif_t *hwif = drive->hwif; in sc1200_tunepio()
91 pci_write_config_dword(pdev, basereg + ((drive->dn & 1) << 3), in sc1200_tunepio()
104 static u8 sc1200_udma_filter(ide_drive_t *drive) in sc1200_udma_filter() argument
106 ide_hwif_t *hwif = drive->hwif; in sc1200_udma_filter()
107 ide_drive_t *mate = ide_get_pair_dev(drive); in sc1200_udma_filter()
126 static void sc1200_set_dma_mode(ide_hwif_t *hwif, ide_drive_t *drive) in sc1200_set_dma_mode() argument
132 const u8 mode = drive->dma_mode; in sc1200_set_dma_mode()
158 if ((drive->dn & 1) == 0) { in sc1200_set_dma_mode()
171 static int sc1200_dma_end(ide_drive_t *drive) in sc1200_dma_end() argument
[all …]
Dtc86c001.c17 static void tc86c001_set_mode(ide_hwif_t *hwif, ide_drive_t *drive) in tc86c001_set_mode() argument
19 unsigned long scr_port = hwif->config_data + (drive->dn ? 0x02 : 0x00); in tc86c001_set_mode()
21 const u8 speed = drive->dma_mode; in tc86c001_set_mode()
45 static void tc86c001_set_pio_mode(ide_hwif_t *hwif, ide_drive_t *drive) in tc86c001_set_pio_mode() argument
47 drive->dma_mode = drive->pio_mode; in tc86c001_set_pio_mode()
48 tc86c001_set_mode(hwif, drive); in tc86c001_set_pio_mode()
65 static int tc86c001_timer_expiry(ide_drive_t *drive) in tc86c001_timer_expiry() argument
67 ide_hwif_t *hwif = drive->hwif; in tc86c001_timer_expiry()
76 unsigned long twcr_port = sc_base + (drive->dn ? 0x06 : 0x04); in tc86c001_timer_expiry()
80 "attempting recovery...\n", drive->name); in tc86c001_timer_expiry()
[all …]
Dpdc202xx_old.c24 static void pdc202xx_set_mode(ide_hwif_t *hwif, ide_drive_t *drive) in pdc202xx_set_mode() argument
27 u8 drive_pci = 0x60 + (drive->dn << 2); in pdc202xx_set_mode()
28 const u8 speed = drive->dma_mode; in pdc202xx_set_mode()
61 if (ide_pio_need_iordy(drive, speed - XFER_PIO_0)) in pdc202xx_set_mode()
63 if (drive->media == ide_disk) in pdc202xx_set_mode()
79 static void pdc202xx_set_pio_mode(ide_hwif_t *hwif, ide_drive_t *drive) in pdc202xx_set_pio_mode() argument
81 drive->dma_mode = drive->pio_mode; in pdc202xx_set_pio_mode()
82 pdc202xx_set_mode(hwif, drive); in pdc202xx_set_pio_mode()
146 static void pdc202xx_dma_start(ide_drive_t *drive) in pdc202xx_dma_start() argument
148 if (drive->current_speed > XFER_UDMA_2) in pdc202xx_dma_start()
[all …]
Dtx4939ide.c107 static void tx4939ide_set_pio_mode(ide_hwif_t *hwif, ide_drive_t *drive) in tx4939ide_set_pio_mode() argument
109 int is_slave = drive->dn; in tx4939ide_set_pio_mode()
111 const u8 pio = drive->pio_mode - XFER_PIO_0; in tx4939ide_set_pio_mode()
115 pair = ide_get_pair_dev(drive); in tx4939ide_set_pio_mode()
128 static void tx4939ide_set_dma_mode(ide_hwif_t *hwif, ide_drive_t *drive) in tx4939ide_set_dma_mode() argument
131 const u8 mode = drive->dma_mode; in tx4939ide_set_dma_mode()
138 if (drive->dn) { in tx4939ide_set_dma_mode()
174 static void tx4939ide_clear_irq(ide_drive_t *drive) in tx4939ide_clear_irq() argument
184 if (drive->waiting_for_dma) in tx4939ide_clear_irq()
186 hwif = drive->hwif; in tx4939ide_clear_irq()
[all …]
Dcmd640.c379 static void __set_prefetch_mode(ide_drive_t *drive, int mode) in __set_prefetch_mode() argument
383 drive->dev_flags |= IDE_DFLAG_NO_UNMASK; in __set_prefetch_mode()
384 drive->dev_flags &= ~IDE_DFLAG_UNMASK; in __set_prefetch_mode()
386 drive->dev_flags &= ~IDE_DFLAG_NO_IO_32BIT; in __set_prefetch_mode()
388 drive->dev_flags &= ~IDE_DFLAG_NO_UNMASK; in __set_prefetch_mode()
389 drive->dev_flags |= IDE_DFLAG_NO_IO_32BIT; in __set_prefetch_mode()
390 drive->io_32bit = 0; in __set_prefetch_mode()
399 static void __init check_prefetch(ide_drive_t *drive, unsigned int index) in check_prefetch() argument
403 __set_prefetch_mode(drive, (b & prefetch_masks[index]) ? 0 : 1); in check_prefetch()
410 static void set_prefetch_mode(ide_drive_t *drive, unsigned int index, int mode) in set_prefetch_mode() argument
[all …]
Dns87415.c64 static void superio_tf_read(ide_drive_t *drive, struct ide_taskfile *tf, in superio_tf_read() argument
67 struct ide_io_ports *io_ports = &drive->hwif->io_ports; in superio_tf_read()
83 static void ns87415_dev_select(ide_drive_t *drive);
122 static void ns87415_prepare_drive (ide_drive_t *drive, unsigned int use_dma) in ns87415_prepare_drive() argument
124 ide_hwif_t *hwif = drive->hwif; in ns87415_prepare_drive()
135 if (drive->dev_flags & IDE_DFLAG_PRESENT) in ns87415_prepare_drive()
141 bit = 1 << (20 + (drive->dn & 1) + (hwif->channel << 1)); in ns87415_prepare_drive()
142 other = 1 << (20 + (1 - (drive->dn & 1)) + (hwif->channel << 1)); in ns87415_prepare_drive()
170 static void ns87415_dev_select(ide_drive_t *drive) in ns87415_dev_select() argument
172 ns87415_prepare_drive(drive, in ns87415_dev_select()
[all …]
Dit8213.c26 static void it8213_set_pio_mode(ide_hwif_t *hwif, ide_drive_t *drive) in it8213_set_pio_mode() argument
29 int is_slave = drive->dn & 1; in it8213_set_pio_mode()
37 const u8 pio = drive->pio_mode - XFER_PIO_0; in it8213_set_pio_mode()
51 if (drive->media != ide_disk) in it8213_set_pio_mode()
53 if (ide_pio_need_iordy(drive, pio)) in it8213_set_pio_mode()
83 static void it8213_set_dma_mode(ide_hwif_t *hwif, ide_drive_t *drive) in it8213_set_dma_mode() argument
87 int a_speed = 3 << (drive->dn * 4); in it8213_set_dma_mode()
88 int u_flag = 1 << drive->dn; in it8213_set_dma_mode()
89 int v_flag = 0x01 << drive->dn; in it8213_set_dma_mode()
90 int w_flag = 0x10 << drive->dn; in it8213_set_dma_mode()
[all …]
Dide-acpi.c225 static int do_drive_get_GTF(ide_drive_t *drive, in do_drive_get_GTF() argument
238 if (!drive->acpidata->obj_handle) { in do_drive_get_GTF()
239 DEBPRINT("No ACPI object found for %s\n", drive->name); in do_drive_get_GTF()
249 status = acpi_evaluate_object(drive->acpidata->obj_handle, "_GTF", in do_drive_get_GTF()
306 static int do_drive_set_taskfiles(ide_drive_t *drive, in do_drive_set_taskfiles() argument
338 err = ide_no_data_taskfile(drive, &cmd); in do_drive_set_taskfiles()
361 int ide_acpi_exec_tfs(ide_drive_t *drive) in ide_acpi_exec_tfs() argument
368 DEBPRINT("call get_GTF, drive=%s port=%d\n", drive->name, drive->dn); in ide_acpi_exec_tfs()
370 ret = do_drive_get_GTF(drive, &gtf_length, &gtf_address, &obj_loc); in ide_acpi_exec_tfs()
376 DEBPRINT("call set_taskfiles, drive=%s\n", drive->name); in ide_acpi_exec_tfs()
[all …]
Dsiimage.c114 static inline unsigned long siimage_seldev(ide_drive_t *drive, int r) in siimage_seldev() argument
116 ide_hwif_t *hwif = drive->hwif; in siimage_seldev()
118 u8 unit = drive->dn & 1; in siimage_seldev()
195 static u8 sil_pata_udma_filter(ide_drive_t *drive) in sil_pata_udma_filter() argument
197 ide_hwif_t *hwif = drive->hwif; in sil_pata_udma_filter()
223 static u8 sil_sata_udma_filter(ide_drive_t *drive) in sil_sata_udma_filter() argument
225 char *m = (char *)&drive->id[ATA_ID_PROD]; in sil_sata_udma_filter()
239 static void sil_set_pio_mode(ide_hwif_t *hwif, ide_drive_t *drive) in sil_set_pio_mode() argument
245 ide_drive_t *pair = ide_get_pair_dev(drive); in sil_set_pio_mode()
248 unsigned long addr = siimage_seldev(drive, 0x04); in sil_set_pio_mode()
[all …]
Dalim15x3.c51 static void ali_fifo_control(ide_hwif_t *hwif, ide_drive_t *drive, int on) in ali_fifo_control() argument
56 int shift = 4 * (drive->dn & 1); in ali_fifo_control()
64 static void ali_program_timings(ide_hwif_t *hwif, ide_drive_t *drive, in ali_program_timings() argument
70 u8 unit = drive->dn & 1, udma; in ali_program_timings()
102 static void ali_set_pio_mode(ide_hwif_t *hwif, ide_drive_t *drive) in ali_set_pio_mode() argument
104 ide_drive_t *pair = ide_get_pair_dev(drive); in ali_set_pio_mode()
109 ide_timing_compute(drive, drive->pio_mode, &t, T, 1); in ali_set_pio_mode()
126 ali_fifo_control(hwif, drive, (drive->media == ide_disk) ? 0x05 : 0x00); in ali_set_pio_mode()
128 ali_program_timings(hwif, drive, &t, 0); in ali_set_pio_mode()
143 static u8 ali_udma_filter(ide_drive_t *drive) in ali_udma_filter() argument
[all …]
Dslc90e66.c21 static void slc90e66_set_pio_mode(ide_hwif_t *hwif, ide_drive_t *drive) in slc90e66_set_pio_mode() argument
24 int is_slave = drive->dn & 1; in slc90e66_set_pio_mode()
31 const u8 pio = drive->pio_mode - XFER_PIO_0; in slc90e66_set_pio_mode()
46 if (drive->media == ide_disk) in slc90e66_set_pio_mode()
48 if (ide_pio_need_iordy(drive, pio)) in slc90e66_set_pio_mode()
75 static void slc90e66_set_dma_mode(ide_hwif_t *hwif, ide_drive_t *drive) in slc90e66_set_dma_mode() argument
79 int sitre = 0, a_speed = 7 << (drive->dn * 4); in slc90e66_set_dma_mode()
80 int u_speed = 0, u_flag = 1 << drive->dn; in slc90e66_set_dma_mode()
82 const u8 speed = drive->dma_mode; in slc90e66_set_dma_mode()
91 u_speed = (speed - XFER_UDMA_0) << (drive->dn * 4); in slc90e66_set_dma_mode()
[all …]
Dhpt366.c534 static int check_in_drive_list(ide_drive_t *drive, const char **list) in check_in_drive_list() argument
536 char *m = (char *)&drive->id[ATA_ID_PROD]; in check_in_drive_list()
557 static u8 hpt3xx_udma_filter(ide_drive_t *drive) in hpt3xx_udma_filter() argument
559 ide_hwif_t *hwif = drive->hwif; in hpt3xx_udma_filter()
566 check_in_drive_list(drive, bad_ata66_4)) in hpt3xx_udma_filter()
570 check_in_drive_list(drive, bad_ata66_3)) in hpt3xx_udma_filter()
575 check_in_drive_list(drive, bad_ata100_5)) in hpt3xx_udma_filter()
580 check_in_drive_list(drive, bad_ata100_5)) in hpt3xx_udma_filter()
586 if (ata_id_is_sata(drive->id)) in hpt3xx_udma_filter()
593 return check_in_drive_list(drive, bad_ata33) ? 0x00 : mask; in hpt3xx_udma_filter()
[all …]
Dcmd64x.c54 static void cmd64x_program_timings(ide_drive_t *drive, u8 mode) in cmd64x_program_timings() argument
56 ide_hwif_t *hwif = drive->hwif; in cmd64x_program_timings()
57 struct pci_dev *dev = to_pci_dev(drive->hwif->dev); in cmd64x_program_timings()
68 ide_timing_compute(drive, mode, &t, T, 0); in cmd64x_program_timings()
88 pci_write_config_byte(dev, drwtim_regs[drive->dn], in cmd64x_program_timings()
98 ide_drive_t *pair = ide_get_pair_dev(drive); in cmd64x_program_timings()
120 (void) pci_read_config_byte (dev, arttim_regs[drive->dn], &arttim); in cmd64x_program_timings()
125 (void) pci_write_config_byte(dev, arttim_regs[drive->dn], arttim); in cmd64x_program_timings()
133 static void cmd64x_set_pio_mode(ide_hwif_t *hwif, ide_drive_t *drive) in cmd64x_set_pio_mode() argument
135 const u8 pio = drive->pio_mode - XFER_PIO_0; in cmd64x_set_pio_mode()
[all …]
Daec62xx.c84 static void aec6210_set_mode(ide_hwif_t *hwif, ide_drive_t *drive) in aec6210_set_mode() argument
92 const u8 speed = drive->dma_mode; in aec6210_set_mode()
97 pci_read_config_word(dev, 0x40|(2*drive->dn), &d_conf); in aec6210_set_mode()
100 pci_write_config_word(dev, 0x40|(2*drive->dn), d_conf); in aec6210_set_mode()
105 tmp1 = ((0x00 << (2*drive->dn)) | (ultra & ~(3 << (2*drive->dn)))); in aec6210_set_mode()
107 tmp2 = ((ultra_conf << (2*drive->dn)) | (tmp1 & ~(3 << (2*drive->dn)))); in aec6210_set_mode()
112 static void aec6260_set_mode(ide_hwif_t *hwif, ide_drive_t *drive) in aec6260_set_mode() argument
117 u8 unit = drive->dn & 1; in aec6260_set_mode()
120 const u8 speed = drive->dma_mode; in aec6260_set_mode()
125 pci_read_config_byte(dev, 0x40|drive->dn, &drive_conf); in aec6260_set_mode()
[all …]
Datiixp.c51 static void atiixp_set_pio_mode(ide_hwif_t *hwif, ide_drive_t *drive) in atiixp_set_pio_mode() argument
55 int timing_shift = (drive->dn ^ 1) * 8; in atiixp_set_pio_mode()
58 const u8 pio = drive->pio_mode - XFER_PIO_0; in atiixp_set_pio_mode()
63 pio_mode_data &= ~(0x07 << (drive->dn * 4)); in atiixp_set_pio_mode()
64 pio_mode_data |= (pio << (drive->dn * 4)); in atiixp_set_pio_mode()
85 static void atiixp_set_dma_mode(ide_hwif_t *hwif, ide_drive_t *drive) in atiixp_set_dma_mode() argument
89 int timing_shift = (drive->dn ^ 1) * 8; in atiixp_set_dma_mode()
93 const u8 speed = drive->dma_mode; in atiixp_set_dma_mode()
101 tmp16 &= ~(0x07 << (drive->dn * 4)); in atiixp_set_dma_mode()
102 tmp16 |= ((speed & 0x07) << (drive->dn * 4)); in atiixp_set_dma_mode()
[all …]
Dpmac.c409 ((void __iomem *)((drive)->hwif->io_ports.data_addr + (x)))
416 static void pmac_ide_apply_timings(ide_drive_t *drive) in pmac_ide_apply_timings() argument
418 ide_hwif_t *hwif = drive->hwif; in pmac_ide_apply_timings()
421 if (drive->dn & 1) in pmac_ide_apply_timings()
433 static void pmac_ide_kauai_apply_timings(ide_drive_t *drive) in pmac_ide_kauai_apply_timings() argument
435 ide_hwif_t *hwif = drive->hwif; in pmac_ide_kauai_apply_timings()
438 if (drive->dn & 1) { in pmac_ide_kauai_apply_timings()
452 pmac_ide_do_update_timings(ide_drive_t *drive) in pmac_ide_do_update_timings() argument
454 ide_hwif_t *hwif = drive->hwif; in pmac_ide_do_update_timings()
460 pmac_ide_kauai_apply_timings(drive); in pmac_ide_do_update_timings()
[all …]
Dpiix.c68 static void piix_set_pio_mode(ide_hwif_t *hwif, ide_drive_t *drive) in piix_set_pio_mode() argument
71 int is_slave = drive->dn & 1; in piix_set_pio_mode()
79 const u8 pio = drive->pio_mode - XFER_PIO_0; in piix_set_pio_mode()
99 if (drive->media == ide_disk) in piix_set_pio_mode()
101 if (ide_pio_need_iordy(drive, pio)) in piix_set_pio_mode()
137 static void piix_set_dma_mode(ide_hwif_t *hwif, ide_drive_t *drive) in piix_set_dma_mode() argument
141 int a_speed = 3 << (drive->dn * 4); in piix_set_dma_mode()
142 int u_flag = 1 << drive->dn; in piix_set_dma_mode()
143 int v_flag = 0x01 << drive->dn; in piix_set_dma_mode()
144 int w_flag = 0x10 << drive->dn; in piix_set_dma_mode()
[all …]
Dide-disk_proc.c9 static int smart_enable(ide_drive_t *drive) in smart_enable() argument
22 return ide_no_data_taskfile(drive, &cmd); in smart_enable()
25 static int get_smart_data(ide_drive_t *drive, u8 *buf, u8 sub_cmd) in get_smart_data() argument
40 return ide_raw_taskfile(drive, &cmd, buf, 1); in get_smart_data()
45 ide_drive_t *drive = (ide_drive_t *) m->private; in idedisk_cache_proc_show() local
47 if (drive->dev_flags & IDE_DFLAG_ID_READ) in idedisk_cache_proc_show()
48 seq_printf(m, "%i\n", drive->id[ATA_ID_BUF_SIZE] / 2); in idedisk_cache_proc_show()
69 ide_drive_t*drive = (ide_drive_t *)m->private; in idedisk_capacity_proc_show() local
71 seq_printf(m, "%llu\n", (long long)ide_gd_capacity(drive)); in idedisk_capacity_proc_show()
88 static int __idedisk_proc_show(struct seq_file *m, ide_drive_t *drive, u8 sub_cmd) in __idedisk_proc_show() argument
[all …]
Dcs5520.c60 static void cs5520_set_pio_mode(ide_hwif_t *hwif, ide_drive_t *drive) in cs5520_set_pio_mode() argument
63 int controller = drive->dn > 1 ? 1 : 0; in cs5520_set_pio_mode()
64 const u8 pio = drive->pio_mode - XFER_PIO_0; in cs5520_set_pio_mode()
75 pci_write_config_byte(pdev, 0x64 + 4*controller + (drive->dn&1), in cs5520_set_pio_mode()
79 pci_write_config_byte(pdev, 0x66 + 4*controller + (drive->dn&1), in cs5520_set_pio_mode()
84 static void cs5520_set_dma_mode(ide_hwif_t *hwif, ide_drive_t *drive) in cs5520_set_dma_mode() argument
88 drive->pio_mode = XFER_PIO_0 + 0; in cs5520_set_dma_mode()
89 cs5520_set_pio_mode(hwif, drive); in cs5520_set_dma_mode()
Dau1xxx-ide.c93 static void au1xxx_input_data(ide_drive_t *drive, struct ide_cmd *cmd, in au1xxx_input_data() argument
96 auide_insw(drive->hwif->io_ports.data_addr, buf, (len + 1) / 2); in au1xxx_input_data()
99 static void au1xxx_output_data(ide_drive_t *drive, struct ide_cmd *cmd, in au1xxx_output_data() argument
102 auide_outsw(drive->hwif->io_ports.data_addr, buf, (len + 1) / 2); in au1xxx_output_data()
106 static void au1xxx_set_pio_mode(ide_hwif_t *hwif, ide_drive_t *drive) in au1xxx_set_pio_mode() argument
110 switch (drive->pio_mode - XFER_PIO_0) { in au1xxx_set_pio_mode()
167 static void auide_set_dma_mode(ide_hwif_t *hwif, ide_drive_t *drive) in auide_set_dma_mode() argument
171 switch (drive->dma_mode) { in auide_set_dma_mode()
215 static int auide_build_dmatable(ide_drive_t *drive, struct ide_cmd *cmd) in auide_build_dmatable() argument
217 ide_hwif_t *hwif = drive->hwif; in auide_build_dmatable()
[all …]
Dserverworks.c55 static int check_in_drive_lists (ide_drive_t *drive, const char **list) in check_in_drive_lists() argument
57 char *m = (char *)&drive->id[ATA_ID_PROD]; in check_in_drive_lists()
65 static u8 svwks_udma_filter(ide_drive_t *drive) in svwks_udma_filter() argument
67 struct pci_dev *dev = to_pci_dev(drive->hwif->dev); in svwks_udma_filter()
81 if (mode > 2 && check_in_drive_lists(drive, svwks_bad_ata100)) in svwks_udma_filter()
109 static void svwks_set_pio_mode(ide_hwif_t *hwif, ide_drive_t *drive) in svwks_set_pio_mode() argument
115 const u8 pio = drive->pio_mode - XFER_PIO_0; in svwks_set_pio_mode()
117 pci_write_config_byte(dev, drive_pci[drive->dn], pio_modes[pio]); in svwks_set_pio_mode()
124 csb_pio &= ~(0x0f << (4 * drive->dn)); in svwks_set_pio_mode()
125 csb_pio |= (pio << (4 * drive->dn)); in svwks_set_pio_mode()
[all …]
Dtriflex.c37 static void triflex_set_mode(ide_hwif_t *hwif, ide_drive_t *drive) in triflex_set_mode() argument
42 u8 channel_offset = hwif->channel ? 0x74 : 0x70, unit = drive->dn & 1; in triflex_set_mode()
46 switch (drive->dma_mode) { in triflex_set_mode()
84 static void triflex_set_pio_mode(ide_hwif_t *hwif, ide_drive_t *drive) in triflex_set_pio_mode() argument
86 drive->dma_mode = drive->pio_mode; in triflex_set_pio_mode()
87 triflex_set_mode(hwif, drive); in triflex_set_pio_mode()
Dide-io-std.c77 void ide_dev_select(ide_drive_t *drive) in ide_dev_select() argument
79 ide_hwif_t *hwif = drive->hwif; in ide_dev_select()
80 u8 select = drive->select | ATA_DEVICE_OBS; in ide_dev_select()
89 void ide_tf_load(ide_drive_t *drive, struct ide_taskfile *tf, u8 valid) in ide_tf_load() argument
91 ide_hwif_t *hwif = drive->hwif; in ide_tf_load()
116 void ide_tf_read(ide_drive_t *drive, struct ide_taskfile *tf, u8 valid) in ide_tf_read() argument
118 ide_hwif_t *hwif = drive->hwif; in ide_tf_read()
164 void ide_input_data(ide_drive_t *drive, struct ide_cmd *cmd, void *buf, in ide_input_data() argument
167 ide_hwif_t *hwif = drive->hwif; in ide_input_data()
171 u8 io_32bit = drive->io_32bit; in ide_input_data()
[all …]
Dcs5535.c76 static void cs5535_set_speed(ide_drive_t *drive, const u8 speed) in cs5535_set_speed() argument
79 u8 unit = drive->dn & 1; in cs5535_set_speed()
83 ide_drive_t *pair = ide_get_pair_dev(drive); in cs5535_set_speed()
138 static void cs5535_set_dma_mode(ide_hwif_t *hwif, ide_drive_t *drive) in cs5535_set_dma_mode() argument
140 cs5535_set_speed(drive, drive->dma_mode); in cs5535_set_dma_mode()
151 static void cs5535_set_pio_mode(ide_hwif_t *hwif, ide_drive_t *drive) in cs5535_set_pio_mode() argument
153 cs5535_set_speed(drive, drive->pio_mode); in cs5535_set_pio_mode()
Dcs5530.c53 static void cs5530_set_pio_mode(ide_hwif_t *hwif, ide_drive_t *drive) in cs5530_set_pio_mode() argument
57 const u8 pio = drive->pio_mode - XFER_PIO_0; in cs5530_set_pio_mode()
59 outl(cs5530_pio_timings[format][pio], basereg + ((drive->dn & 1)<<3)); in cs5530_set_pio_mode()
81 static u8 cs5530_udma_filter(ide_drive_t *drive) in cs5530_udma_filter() argument
83 ide_hwif_t *hwif = drive->hwif; in cs5530_udma_filter()
84 ide_drive_t *mate = ide_get_pair_dev(drive); in cs5530_udma_filter()
103 static void cs5530_set_dma_mode(ide_hwif_t *hwif, ide_drive_t *drive) in cs5530_set_dma_mode() argument
108 switch (drive->dma_mode) { in cs5530_set_dma_mode()
119 if ((drive-> dn & 1) == 0) { /* are we configuring drive0? */ in cs5530_set_dma_mode()
Dcy82c693.c56 static void cy82c693_set_dma_mode(ide_hwif_t *hwif, ide_drive_t *drive) in cy82c693_set_dma_mode() argument
58 const u8 mode = drive->dma_mode; in cy82c693_set_dma_mode()
83 static void cy82c693_set_pio_mode(ide_hwif_t *hwif, ide_drive_t *drive) in cy82c693_set_pio_mode() argument
93 if (drive->dn > 1) { /* drive is on the secondary channel */ in cy82c693_set_pio_mode()
98 drive->name); in cy82c693_set_pio_mode()
103 ide_timing_compute(drive, drive->pio_mode, &t, T, 1); in cy82c693_set_pio_mode()
111 if ((drive->dn & 1) == 0) { in cy82c693_set_pio_mode()
144 if (drive->dn > 1) in cy82c693_set_pio_mode()
Dicside.c167 static void icside_maskproc(ide_drive_t *drive, int mask) in icside_maskproc() argument
169 ide_hwif_t *hwif = drive->hwif; in icside_maskproc()
237 static void icside_set_dma_mode(ide_hwif_t *hwif, ide_drive_t *drive) in icside_set_dma_mode() argument
241 const u8 xfer_mode = drive->dma_mode; in icside_set_dma_mode()
269 if (use_dma_info && drive->id[ATA_ID_EIDE_DMA_TIME] > cycle_time) in icside_set_dma_mode()
270 cycle_time = drive->id[ATA_ID_EIDE_DMA_TIME]; in icside_set_dma_mode()
272 ide_set_drivedata(drive, (void *)cycle_time); in icside_set_dma_mode()
275 drive->name, ide_xfer_verbose(xfer_mode), in icside_set_dma_mode()
284 static void icside_dma_host_set(ide_drive_t *drive, int on) in icside_dma_host_set() argument
288 static int icside_dma_end(ide_drive_t *drive) in icside_dma_end() argument
[all …]
Dfalconide.c66 static void falconide_input_data(ide_drive_t *drive, struct ide_cmd *cmd, in falconide_input_data() argument
69 unsigned long data_addr = drive->hwif->io_ports.data_addr; in falconide_input_data()
71 if (drive->media == ide_disk && cmd && (cmd->tf_flags & IDE_TFLAG_FS)) { in falconide_input_data()
79 static void falconide_output_data(ide_drive_t *drive, struct ide_cmd *cmd, in falconide_output_data() argument
82 unsigned long data_addr = drive->hwif->io_ports.data_addr; in falconide_output_data()
84 if (drive->media == ide_disk && cmd && (cmd->tf_flags & IDE_TFLAG_FS)) { in falconide_output_data()
Dqd65xx.h34 static inline u8 QD_TIMING(ide_drive_t *drive) in QD_TIMING() argument
36 return (unsigned long)ide_get_drivedata(drive) & 0x00ff; in QD_TIMING()
39 static inline u8 QD_TIMREG(ide_drive_t *drive) in QD_TIMREG() argument
41 return ((unsigned long)ide_get_drivedata(drive) & 0xff00) >> 8; in QD_TIMREG()
Dq40ide.c73 static void q40ide_input_data(ide_drive_t *drive, struct ide_cmd *cmd, in q40ide_input_data() argument
76 unsigned long data_addr = drive->hwif->io_ports.data_addr; in q40ide_input_data()
78 if (drive->media == ide_disk && cmd && (cmd->tf_flags & IDE_TFLAG_FS)) { in q40ide_input_data()
86 static void q40ide_output_data(ide_drive_t *drive, struct ide_cmd *cmd, in q40ide_output_data() argument
89 unsigned long data_addr = drive->hwif->io_ports.data_addr; in q40ide_output_data()
91 if (drive->media == ide_disk && cmd && (cmd->tf_flags & IDE_TFLAG_FS)) { in q40ide_output_data()
Dopti621.c65 static void opti621_set_pio_mode(ide_hwif_t *hwif, ide_drive_t *drive) in opti621_set_pio_mode() argument
67 ide_drive_t *pair = ide_get_pair_dev(drive); in opti621_set_pio_mode()
69 unsigned long mode = drive->pio_mode, pair_mode; in opti621_set_pio_mode()
83 ide_set_drivedata(drive, (void *)mode); in opti621_set_pio_mode()
113 write_reg(drive->dn & 1, MISC_REG); in opti621_set_pio_mode()
Dali14xx.c112 static void ali14xx_set_pio_mode(ide_hwif_t *hwif, ide_drive_t *drive) in ali14xx_set_pio_mode() argument
119 const u8 pio = drive->pio_mode - XFER_PIO_0; in ali14xx_set_pio_mode()
123 time1 = ide_pio_cycle_time(drive, pio); in ali14xx_set_pio_mode()
132 drive->name, pio, time1, time2, param1, param2, param3, param4); in ali14xx_set_pio_mode()
135 driveNum = (drive->hwif->index << 1) + (drive->dn & 1); in ali14xx_set_pio_mode()
Dtx4938ide.c59 static void tx4938ide_set_pio_mode(ide_hwif_t *hwif, ide_drive_t *drive) in tx4938ide_set_pio_mode() argument
62 u8 safe = drive->pio_mode - XFER_PIO_0; in tx4938ide_set_pio_mode()
65 pair = ide_get_pair_dev(drive); in tx4938ide_set_pio_mode()
74 static void tx4938ide_input_data_swap(ide_drive_t *drive, struct ide_cmd *cmd, in tx4938ide_input_data_swap() argument
77 unsigned long port = drive->hwif->io_ports.data_addr; in tx4938ide_input_data_swap()
86 static void tx4938ide_output_data_swap(ide_drive_t *drive, struct ide_cmd *cmd, in tx4938ide_output_data_swap() argument
89 unsigned long port = drive->hwif->io_ports.data_addr; in tx4938ide_output_data_swap()
Dide-timings.c81 u16 ide_pio_cycle_time(ide_drive_t *drive, u8 pio) in ide_pio_cycle_time() argument
83 u16 *id = drive->id; in ide_pio_cycle_time()
88 if (ata_id_has_iordy(drive->id)) in ide_pio_cycle_time()
144 int ide_timing_compute(ide_drive_t *drive, u8 speed, in ide_timing_compute() argument
147 u16 *id = drive->id; in ide_timing_compute()
192 ide_timing_compute(drive, drive->pio_mode, &p, T, UT); in ide_timing_compute()
Damd74xx.c82 static void amd_set_drive(ide_hwif_t *hwif, ide_drive_t *drive) in amd_set_drive() argument
85 ide_drive_t *peer = ide_get_pair_dev(drive); in amd_set_drive()
89 const u8 speed = drive->dma_mode; in amd_set_drive()
94 ide_timing_compute(drive, speed, &t, T, UT); in amd_set_drive()
104 amd_set_speed(dev, drive->dn, udma_mask, &t); in amd_set_drive()
111 static void amd_set_pio_mode(ide_hwif_t *hwif, ide_drive_t *drive) in amd_set_pio_mode() argument
113 drive->dma_mode = drive->pio_mode; in amd_set_pio_mode()
114 amd_set_drive(hwif, drive); in amd_set_pio_mode()
Dpalm_bk3710.c191 static void palm_bk3710_set_dma_mode(ide_hwif_t *hwif, ide_drive_t *drive) in palm_bk3710_set_dma_mode() argument
193 int is_slave = drive->dn & 1; in palm_bk3710_set_dma_mode()
195 const u8 xferspeed = drive->dma_mode; in palm_bk3710_set_dma_mode()
202 drive->id[ATA_ID_EIDE_DMA_MIN], in palm_bk3710_set_dma_mode()
207 static void palm_bk3710_set_pio_mode(ide_hwif_t *hwif, ide_drive_t *drive) in palm_bk3710_set_pio_mode() argument
210 int is_slave = drive->dn & 1; in palm_bk3710_set_pio_mode()
213 const u8 pio = drive->pio_mode - XFER_PIO_0; in palm_bk3710_set_pio_mode()
218 cycle_time = ide_pio_cycle_time(drive, pio); in palm_bk3710_set_pio_mode()
219 mate = ide_get_pair_dev(drive); in palm_bk3710_set_pio_mode()
Dide-disk_ioctl.c18 int ide_disk_ioctl(ide_drive_t *drive, struct block_device *bdev, fmode_t mode, in ide_disk_ioctl() argument
24 err = ide_setting_ioctl(drive, bdev, cmd, arg, ide_disk_ioctl_settings); in ide_disk_ioctl()
28 err = generic_ide_ioctl(drive, bdev, cmd, arg); in ide_disk_ioctl()
Dide-4drives.c14 static void ide_4drives_init_dev(ide_drive_t *drive) in ide_4drives_init_dev() argument
16 if (drive->hwif->channel) in ide_4drives_init_dev()
17 drive->select ^= 0x20; in ide_4drives_init_dev()
Dumc8672.c107 static void umc_set_pio_mode(ide_hwif_t *hwif, ide_drive_t *drive) in umc_set_pio_mode() argument
111 const u8 pio = drive->pio_mode - XFER_PIO_0; in umc_set_pio_mode()
114 drive->name, pio, pio_to_umc[pio]); in umc_set_pio_mode()
120 current_speeds[drive->name[2] - 'a'] = pio_to_umc[pio]; in umc_set_pio_mode()
Dvia82cxxx.c179 static void via_set_drive(ide_hwif_t *hwif, ide_drive_t *drive) in via_set_drive() argument
181 ide_drive_t *peer = ide_get_pair_dev(drive); in via_set_drive()
187 const u8 speed = drive->dma_mode; in via_set_drive()
199 ide_timing_compute(drive, speed, &t, T, UT); in via_set_drive()
206 via_set_speed(hwif, drive->dn, &t); in via_set_drive()
217 static void via_set_pio_mode(ide_hwif_t *hwif, ide_drive_t *drive) in via_set_pio_mode() argument
219 drive->dma_mode = drive->pio_mode; in via_set_pio_mode()
220 via_set_drive(hwif, drive); in via_set_pio_mode()
Dpdc202xx_new.c133 static void pdcnew_set_dma_mode(ide_hwif_t *hwif, ide_drive_t *drive) in pdcnew_set_dma_mode() argument
136 u8 adj = (drive->dn & 1) ? 0x08 : 0x00; in pdcnew_set_dma_mode()
137 const u8 speed = drive->dma_mode; in pdcnew_set_dma_mode()
171 static void pdcnew_set_pio_mode(ide_hwif_t *hwif, ide_drive_t *drive) in pdcnew_set_pio_mode() argument
174 u8 adj = (drive->dn & 1) ? 0x08 : 0x00; in pdcnew_set_pio_mode()
175 const u8 pio = drive->pio_mode - XFER_PIO_0; in pdcnew_set_pio_mode()
192 static void pdcnew_reset(ide_drive_t *drive) in pdcnew_reset() argument
198 drive->hwif->channel ? "Secondary" : "Primary"); in pdcnew_reset()
Dide-floppy_proc.c10 ide_drive_t*drive = (ide_drive_t *)m->private; in idefloppy_capacity_proc_show() local
12 seq_printf(m, "%llu\n", (long long)ide_gd_capacity(drive)); in idefloppy_capacity_proc_show()
Ddtc2278.c71 static void dtc2278_set_pio_mode(ide_hwif_t *hwif, ide_drive_t *drive) in dtc2278_set_pio_mode() argument
75 if (drive->pio_mode >= XFER_PIO_3) { in dtc2278_set_pio_mode()
Djmicron.c83 static void jmicron_set_pio_mode(ide_hwif_t *hwif, ide_drive_t *drive) in jmicron_set_pio_mode() argument
95 static void jmicron_set_dma_mode(ide_hwif_t *hwif, ide_drive_t *drive) in jmicron_set_dma_mode() argument
Dgayle.c71 static void gayle_a1200_clear_irq(ide_drive_t *drive) in gayle_a1200_clear_irq() argument
73 ide_hwif_t *hwif = drive->hwif; in gayle_a1200_clear_irq()
Dide-pci-generic.c36 static void netcell_quirkproc(ide_drive_t *drive) in netcell_quirkproc() argument
39 drive->id[ATA_ID_CSF_DEFAULT] |= 0x4000; in netcell_quirkproc()
Dbuddha.c113 static void xsurf_clear_irq(ide_drive_t *drive) in xsurf_clear_irq() argument
118 z_writeb(0, drive->hwif->io_ports.irq_addr); in xsurf_clear_irq()
/linux-4.4.14/drivers/block/
Damiflop.c125 #define SELMASK(drive) (1 << (3 + (drive & 3))) argument
239 static inline int try_fdc(int drive) in try_fdc() argument
241 drive &= 3; in try_fdc()
242 return ((fdc_busy < 0) || (fdc_busy == drive)); in try_fdc()
245 static void get_fdc(int drive) in get_fdc() argument
249 drive &= 3; in get_fdc()
251 printk("get_fdc: drive %d fdc_busy %d fdc_nested %d\n",drive,fdc_busy,fdc_nested); in get_fdc()
254 wait_event(fdc_wait, try_fdc(drive)); in get_fdc()
255 fdc_busy = drive; in get_fdc()
274 static void fd_select (int drive) in fd_select() argument
[all …]
Dfloppy.c308 #define UDP (&drive_params[drive])
309 #define UDRS (&drive_state[drive])
310 #define UDRWE (&write_errors[drive])
311 #define UFDCS (&fdc_state[FDC(drive)])
601 static inline bool drive_no_geom(int drive) in drive_no_geom() argument
603 return !current_type[drive] && !ITYPE(UDRS->fd_device); in drive_no_geom()
607 static inline int fd_eject(int drive) in fd_eject() argument
669 static void __reschedule_timeout(int drive, const char *message) in __reschedule_timeout() argument
673 if (drive == current_reqD) in __reschedule_timeout()
674 drive = current_drive; in __reschedule_timeout()
[all …]
Dataflop.c226 #define UD unit[drive]
227 #define UDT unit[drive].disktype
284 #define IS_BUFFERED(drive,side,track) \ argument
285 (BufferDrive == (drive) && BufferSide == (side) && BufferTrack == (track))
343 static void fd_select_drive( int drive );
349 static int do_format(int drive, int type, struct atari_format_descr *desc);
350 static void do_fd_action( int drive );
364 static void setup_req_params( int drive );
368 static void fd_probe( int drive );
369 static int fd_test_drive_present( int drive );
[all …]
Dswim.c780 int drive = (*part & 3); in floppy_find() local
782 if (drive > swd->floppy_count) in floppy_find()
786 return get_disk(swd->unit[drive].disk); in floppy_find()
815 int drive; in swim_floppy_init() local
836 for (drive = 0; drive < swd->floppy_count; drive++) { in swim_floppy_init()
837 swd->unit[drive].disk = alloc_disk(1); in swim_floppy_init()
838 if (swd->unit[drive].disk == NULL) { in swim_floppy_init()
842 swd->unit[drive].swd = swd; in swim_floppy_init()
852 for (drive = 0; drive < swd->floppy_count; drive++) { in swim_floppy_init()
853 swd->unit[drive].disk->flags = GENHD_FL_REMOVABLE; in swim_floppy_init()
[all …]
Dhd.c290 static int controller_ready(unsigned int drive, unsigned int head) in controller_ready() argument
297 outb_p(0xA0 | (drive<<4) | head, HD_CURRENT); in controller_ready()
699 int drive; in hd_init() local
735 for (drive = 0 ; drive < NR_HD ; drive++) { in hd_init()
737 struct hd_i_struct *p = &hd_info[drive]; in hd_init()
741 disk->first_minor = drive << 6; in hd_init()
743 sprintf(disk->disk_name, "hd%c", 'a'+drive); in hd_init()
747 p->unit = drive; in hd_init()
748 hd_gendisk[drive] = disk; in hd_init()
769 for (drive = 0; drive < NR_HD; drive++) in hd_init()
[all …]
/linux-4.4.14/arch/arm64/boot/dts/qcom/
Dmsm8916-pins.dtsi23 drive-strength = <16>;
35 drive-strength = <2>;
47 drive-strength = <16>;
59 drive-strength = <2>;
75 drive-strength = <12>;
80 drive-strength = <2>;
93 drive-strength = <2>;
109 drive-strength = <12>;
114 drive-strength = <2>;
127 drive-strength = <2>;
[all …]
/linux-4.4.14/drivers/gpu/drm/nouveau/nvkm/subdev/bios/
Di2c.c95 info->drive = DCB_I2C_UNUSED; in dcb_i2c_parse()
102 info->drive = nvbios_rd08(bios, ent + 0); in dcb_i2c_parse()
106 info->drive = nvbios_rd08(bios, ent + 1); in dcb_i2c_parse()
109 info->drive = nvbios_rd08(bios, ent + 0) & 0x0f; in dcb_i2c_parse()
119 info->drive = (nvbios_rd16(bios, ent + 0) & 0x01f) >> 0; in dcb_i2c_parse()
120 if (info->drive == 0x1f) in dcb_i2c_parse()
121 info->drive = DCB_I2C_UNUSED; in dcb_i2c_parse()
146 info->drive = nvbios_rd08(bios, ent + 4); in dcb_i2c_parse()
147 if (!info->drive) info->drive = 0x3f; in dcb_i2c_parse()
152 info->drive = nvbios_rd08(bios, ent + 6); in dcb_i2c_parse()
[all …]
/linux-4.4.14/include/linux/
Dide.h839 static int get_##name(ide_drive_t *drive) \
841 return drive->field; \
845 static int set_##name(ide_drive_t *drive, int arg) \
847 drive->field = arg; \
852 static int get_##name(ide_drive_t *drive) \
854 return !!(drive->dev_flags & flag); \
858 static int set_##name(ide_drive_t *drive, int arg) \
861 drive->dev_flags |= flag; \
863 drive->dev_flags &= ~flag; \
952 static inline void ide_proc_unregister_device(ide_drive_t *drive) { ; } in ide_proc_unregister_device() argument
[all …]
/linux-4.4.14/drivers/gpu/drm/nouveau/nvkm/subdev/i2c/
Dbusnv04.c31 u8 drive; member
40 u8 val = nvkm_rdvgac(device, 0, bus->drive); in nv04_i2c_bus_drive_scl()
43 nvkm_wrvgac(device, 0, bus->drive, val | 0x01); in nv04_i2c_bus_drive_scl()
51 u8 val = nvkm_rdvgac(device, 0, bus->drive); in nv04_i2c_bus_drive_sda()
54 nvkm_wrvgac(device, 0, bus->drive, val | 0x01); in nv04_i2c_bus_drive_sda()
83 nv04_i2c_bus_new(struct nvkm_i2c_pad *pad, int id, u8 drive, u8 sense, in nv04_i2c_bus_new() argument
93 bus->drive = drive; in nv04_i2c_bus_new()
Dbusnv50.c90 nv50_i2c_bus_new(struct nvkm_i2c_pad *pad, int id, u8 drive, in nv50_i2c_bus_new() argument
100 if (drive >= ARRAY_SIZE(addr)) { in nv50_i2c_bus_new()
101 nvkm_warn(&pad->i2c->subdev, "bus %d unknown\n", drive); in nv50_i2c_bus_new()
110 bus->addr = addr[drive]; in nv50_i2c_bus_new()
Dpad.h23 int (*bus_new_0)(struct nvkm_i2c_pad *, int id, u8 drive, u8 sense,
25 int (*bus_new_4)(struct nvkm_i2c_pad *, int id, u8 drive,
28 int (*aux_new_6)(struct nvkm_i2c_pad *, int id, u8 drive,
Dbusnv4e.c74 nv4e_i2c_bus_new(struct nvkm_i2c_pad *pad, int id, u8 drive, in nv4e_i2c_bus_new() argument
84 bus->addr = 0x600800 + drive; in nv4e_i2c_bus_new()
Dbusgf119.c83 gf119_i2c_bus_new(struct nvkm_i2c_pad *pad, int id, u8 drive, in gf119_i2c_bus_new() argument
93 bus->addr = 0x00d014 + (drive * 0x20); in gf119_i2c_bus_new()
Dbase.c271 ccbE.drive, ccbE.sense, ccbE.share, ccbE.auxch); in nvkm_i2c_new_()
291 ccbE.drive, in nvkm_i2c_new_()
298 ccbE.drive != DCB_I2C_UNUSED))) { in nvkm_i2c_new_()
300 ccbE.drive, &bus); in nvkm_i2c_new_()
/linux-4.4.14/arch/arm/boot/dts/
Dimx28.dtsi217 fsl,drive-strength = <MXS_DRIVE_4mA>;
228 fsl,drive-strength = <MXS_DRIVE_4mA>;
241 fsl,drive-strength = <MXS_DRIVE_4mA>;
265 fsl,drive-strength = <MXS_DRIVE_4mA>;
276 fsl,drive-strength = <MXS_DRIVE_12mA>;
287 fsl,drive-strength = <MXS_DRIVE_4mA>;
298 fsl,drive-strength = <MXS_DRIVE_4mA>;
311 fsl,drive-strength = <MXS_DRIVE_4mA>;
322 fsl,drive-strength = <MXS_DRIVE_4mA>;
333 fsl,drive-strength = <MXS_DRIVE_4mA>;
[all …]
Dimx28-cfa10049.dts30 fsl,drive-strength = <MXS_DRIVE_4mA>;
41 fsl,drive-strength = <MXS_DRIVE_4mA>;
51 fsl,drive-strength = <MXS_DRIVE_4mA>;
61 fsl,drive-strength = <MXS_DRIVE_4mA>;
72 fsl,drive-strength = <MXS_DRIVE_4mA>;
82 fsl,drive-strength = <MXS_DRIVE_4mA>;
95 fsl,drive-strength = <MXS_DRIVE_8mA>;
109 fsl,drive-strength = <MXS_DRIVE_8mA>;
136 fsl,drive-strength = <MXS_DRIVE_4mA>;
149 fsl,drive-strength = <MXS_DRIVE_4mA>;
[all …]
Dsun7i-a20.dtsi873 allwinner,drive = <SUN4I_PINCTRL_10_MA>;
880 allwinner,drive = <SUN4I_PINCTRL_10_MA>;
887 allwinner,drive = <SUN4I_PINCTRL_10_MA>;
894 allwinner,drive = <SUN4I_PINCTRL_10_MA>;
901 allwinner,drive = <SUN4I_PINCTRL_10_MA>;
908 allwinner,drive = <SUN4I_PINCTRL_10_MA>;
915 allwinner,drive = <SUN4I_PINCTRL_10_MA>;
922 allwinner,drive = <SUN4I_PINCTRL_10_MA>;
929 allwinner,drive = <SUN4I_PINCTRL_10_MA>;
936 allwinner,drive = <SUN4I_PINCTRL_10_MA>;
[all …]
Dimx23.dtsi145 fsl,drive-strength = <MXS_DRIVE_4mA>;
158 fsl,drive-strength = <MXS_DRIVE_4mA>;
169 fsl,drive-strength = <MXS_DRIVE_4mA>;
195 fsl,drive-strength = <MXS_DRIVE_4mA>;
206 fsl,drive-strength = <MXS_DRIVE_12mA>;
219 fsl,drive-strength = <MXS_DRIVE_8mA>;
239 fsl,drive-strength = <MXS_DRIVE_8mA>;
257 fsl,drive-strength = <MXS_DRIVE_4mA>;
294 fsl,drive-strength = <MXS_DRIVE_4mA>;
307 fsl,drive-strength = <MXS_DRIVE_8mA>;
[all …]
Dimx28-eukrea-mbmx28lc.dtsi200 fsl,drive-strength = <MXS_DRIVE_4mA>;
210 fsl,drive-strength = <MXS_DRIVE_4mA>;
223 fsl,drive-strength = <MXS_DRIVE_4mA>;
233 fsl,drive-strength = <MXS_DRIVE_4mA>;
243 fsl,drive-strength = <MXS_DRIVE_4mA>;
253 fsl,drive-strength = <MXS_DRIVE_4mA>;
263 fsl,drive-strength = <MXS_DRIVE_4mA>;
273 fsl,drive-strength = <MXS_DRIVE_4mA>;
Dhi3620-hi4511.dts346 pinctrl-single,drive-strength = <0x30 0xf0>;
360 pinctrl-single,drive-strength = <0x30 0xf0>;
455 pinctrl-single,drive-strength = <0x30 0xf0>;
464 pinctrl-single,drive-strength = <0x30 0xf0>;
473 pinctrl-single,drive-strength = <0x30 0xf0>;
482 pinctrl-single,drive-strength = <0x30 0xf0>;
492 pinctrl-single,drive-strength = <0x30 0xf0>;
503 pinctrl-single,drive-strength = <0x30 0xf0>;
513 pinctrl-single,drive-strength = <0x30 0xf0>;
521 pinctrl-single,drive-strength = <0x30 0xf0>;
[all …]
Dsun4i-a10.dtsi796 allwinner,drive = <SUN4I_PINCTRL_10_MA>;
803 allwinner,drive = <SUN4I_PINCTRL_10_MA>;
810 allwinner,drive = <SUN4I_PINCTRL_10_MA>;
817 allwinner,drive = <SUN4I_PINCTRL_10_MA>;
824 allwinner,drive = <SUN4I_PINCTRL_10_MA>;
831 allwinner,drive = <SUN4I_PINCTRL_10_MA>;
838 allwinner,drive = <SUN4I_PINCTRL_10_MA>;
845 allwinner,drive = <SUN4I_PINCTRL_10_MA>;
856 allwinner,drive = <SUN4I_PINCTRL_10_MA>;
864 allwinner,drive = <SUN4I_PINCTRL_30_MA>;
[all …]
Dimx28-cfa10036.dts31 fsl,drive-strength = <MXS_DRIVE_4mA>;
41 fsl,drive-strength = <MXS_DRIVE_4mA>;
51 fsl,drive-strength = <MXS_DRIVE_4mA>;
62 fsl,drive-strength = <0>;
Dsun7i-a20-orangepi-mini.dts167 allwinner,drive = <SUN4I_PINCTRL_10_MA>;
174 allwinner,drive = <SUN4I_PINCTRL_10_MA>;
181 allwinner,drive = <SUN4I_PINCTRL_10_MA>;
188 allwinner,drive = <SUN4I_PINCTRL_10_MA>;
195 allwinner,drive = <SUN4I_PINCTRL_10_MA>;
202 allwinner,drive = <SUN4I_PINCTRL_10_MA>;
209 allwinner,drive = <SUN4I_PINCTRL_10_MA>;
Dimx28-cfa10055.dts34 fsl,drive-strength = <MXS_DRIVE_8mA>;
61 fsl,drive-strength = <MXS_DRIVE_4mA>;
74 fsl,drive-strength = <MXS_DRIVE_4mA>;
84 fsl,drive-strength = <MXS_DRIVE_4mA>;
Dimx28-tx28.dts510 fsl,drive-strength = <MXS_DRIVE_4mA>;
521 fsl,drive-strength = <MXS_DRIVE_4mA>;
530 fsl,drive-strength = <MXS_DRIVE_4mA>;
562 fsl,drive-strength = <MXS_DRIVE_4mA>;
572 fsl,drive-strength = <MXS_DRIVE_4mA>;
589 fsl,drive-strength = <MXS_DRIVE_4mA>;
598 fsl,drive-strength = <MXS_DRIVE_4mA>;
612 fsl,drive-strength = <MXS_DRIVE_8mA>;
621 fsl,drive-strength = <MXS_DRIVE_4mA>;
632 fsl,drive-strength = <MXS_DRIVE_12mA>;
[all …]
Dimx28-cfa10056.dts33 fsl,drive-strength = <MXS_DRIVE_8mA>;
46 fsl,drive-strength = <MXS_DRIVE_4mA>;
56 fsl,drive-strength = <MXS_DRIVE_4mA>;
Dimx28-apx4devkit.dts51 fsl,drive-strength = <MXS_DRIVE_4mA>;
64 fsl,drive-strength = <MXS_DRIVE_4mA>;
79 fsl,drive-strength = <MXS_DRIVE_8mA>;
88 fsl,drive-strength = <MXS_DRIVE_12mA>;
Dsun7i-a20-bananapro.dts187 allwinner,drive = <SUN4I_PINCTRL_10_MA>;
194 allwinner,drive = <SUN4I_PINCTRL_10_MA>;
201 allwinner,drive = <SUN4I_PINCTRL_10_MA>;
208 allwinner,drive = <SUN4I_PINCTRL_10_MA>;
215 allwinner,drive = <SUN4I_PINCTRL_10_MA>;
222 allwinner,drive = <SUN4I_PINCTRL_10_MA>;
Dsun7i-a20-orangepi.dts152 allwinner,drive = <SUN4I_PINCTRL_10_MA>;
159 allwinner,drive = <SUN4I_PINCTRL_10_MA>;
166 allwinner,drive = <SUN4I_PINCTRL_10_MA>;
173 allwinner,drive = <SUN4I_PINCTRL_10_MA>;
180 allwinner,drive = <SUN4I_PINCTRL_10_MA>;
187 allwinner,drive = <SUN4I_PINCTRL_10_MA>;
Dsun5i-a13-utoo-p66.dts164 allwinner,drive = <SUN4I_PINCTRL_10_MA>;
171 allwinner,drive = <SUN4I_PINCTRL_10_MA>;
178 allwinner,drive = <SUN4I_PINCTRL_10_MA>;
185 allwinner,drive = <SUN4I_PINCTRL_10_MA>;
192 allwinner,drive = <SUN4I_PINCTRL_10_MA>;
199 allwinner,drive = <SUN4I_PINCTRL_10_MA>;
Dsun7i-a20-cubietruck.dts211 allwinner,drive = <SUN4I_PINCTRL_10_MA>;
218 allwinner,drive = <SUN4I_PINCTRL_10_MA>;
225 allwinner,drive = <SUN4I_PINCTRL_10_MA>;
232 allwinner,drive = <SUN4I_PINCTRL_10_MA>;
239 allwinner,drive = <SUN4I_PINCTRL_10_MA>;
246 allwinner,drive = <SUN4I_PINCTRL_10_MA>;
Dsun5i-a13-olinuxino.dts170 allwinner,drive = <SUN4I_PINCTRL_10_MA>;
177 allwinner,drive = <SUN4I_PINCTRL_20_MA>;
184 allwinner,drive = <SUN4I_PINCTRL_10_MA>;
191 allwinner,drive = <SUN4I_PINCTRL_10_MA>;
198 allwinner,drive = <SUN4I_PINCTRL_10_MA>;
Dimx28-cfa10057.dts31 fsl,drive-strength = <MXS_DRIVE_4mA>;
58 fsl,drive-strength = <MXS_DRIVE_4mA>;
71 fsl,drive-strength = <MXS_DRIVE_4mA>;
Dsun7i-a20-olinuxino-lime2.dts207 allwinner,drive = <SUN4I_PINCTRL_10_MA>;
214 allwinner,drive = <SUN4I_PINCTRL_20_MA>;
221 allwinner,drive = <SUN4I_PINCTRL_10_MA>;
228 allwinner,drive = <SUN4I_PINCTRL_10_MA>;
235 allwinner,drive = <SUN4I_PINCTRL_10_MA>;
Dsun5i-a10s-olinuxino-micro.dts207 allwinner,drive = <SUN4I_PINCTRL_10_MA>;
214 allwinner,drive = <SUN4I_PINCTRL_10_MA>;
221 allwinner,drive = <SUN4I_PINCTRL_20_MA>;
228 allwinner,drive = <SUN4I_PINCTRL_10_MA>;
235 allwinner,drive = <SUN4I_PINCTRL_10_MA>;
Dsun5i-a10s.dtsi204 allwinner,drive = <SUN4I_PINCTRL_10_MA>;
211 allwinner,drive = <SUN4I_PINCTRL_10_MA>;
222 allwinner,drive = <SUN4I_PINCTRL_10_MA>;
233 allwinner,drive = <SUN4I_PINCTRL_10_MA>;
241 allwinner,drive = <SUN4I_PINCTRL_30_MA>;
Dsun5i-q8-common.dtsi106 allwinner,drive = <SUN4I_PINCTRL_10_MA>;
113 allwinner,drive = <SUN4I_PINCTRL_10_MA>;
120 allwinner,drive = <SUN4I_PINCTRL_10_MA>;
127 allwinner,drive = <SUN4I_PINCTRL_10_MA>;
Dsun6i-a31s-sinovoip-bpi-m2.dts158 allwinner,drive = <SUN4I_PINCTRL_10_MA>;
165 allwinner,drive = <SUN4I_PINCTRL_10_MA>;
172 allwinner,drive = <SUN4I_PINCTRL_10_MA>;
181 allwinner,drive = <SUN4I_PINCTRL_10_MA>;
Dsun4i-a10-olinuxino-lime.dts173 allwinner,drive = <SUN4I_PINCTRL_10_MA>;
180 allwinner,drive = <SUN4I_PINCTRL_20_MA>;
187 allwinner,drive = <SUN4I_PINCTRL_10_MA>;
194 allwinner,drive = <SUN4I_PINCTRL_10_MA>;
Dsunxi-common-regulators.dtsi52 allwinner,drive = <SUN4I_PINCTRL_10_MA>;
59 allwinner,drive = <SUN4I_PINCTRL_10_MA>;
66 allwinner,drive = <SUN4I_PINCTRL_10_MA>;
73 allwinner,drive = <SUN4I_PINCTRL_10_MA>;
Dsun7i-a20-olinuxino-lime.dts158 allwinner,drive = <SUN4I_PINCTRL_10_MA>;
165 allwinner,drive = <SUN4I_PINCTRL_20_MA>;
172 allwinner,drive = <SUN4I_PINCTRL_10_MA>;
179 allwinner,drive = <SUN4I_PINCTRL_10_MA>;
Dsun9i-a80-optimus.dts132 allwinner,drive = <SUN4I_PINCTRL_10_MA>;
139 allwinner,drive = <SUN4I_PINCTRL_10_MA>;
146 allwinner,drive = <SUN4I_PINCTRL_10_MA>;
153 allwinner,drive = <SUN4I_PINCTRL_10_MA>;
Dsun6i-a31.dtsi653 allwinner,drive = <SUN4I_PINCTRL_10_MA>;
660 allwinner,drive = <SUN4I_PINCTRL_10_MA>;
667 allwinner,drive = <SUN4I_PINCTRL_10_MA>;
674 allwinner,drive = <SUN4I_PINCTRL_10_MA>;
682 allwinner,drive = <SUN4I_PINCTRL_30_MA>;
690 allwinner,drive = <SUN4I_PINCTRL_30_MA>;
698 allwinner,drive = <SUN4I_PINCTRL_30_MA>;
708 allwinner,drive = <SUN4I_PINCTRL_30_MA>;
719 allwinner,drive = <SUN4I_PINCTRL_10_MA>;
734 * might need a higher signal drive strength
[all …]
Dsun8i-a23-a33.dtsi360 allwinner,drive = <SUN4I_PINCTRL_10_MA>;
368 allwinner,drive = <SUN4I_PINCTRL_30_MA>;
376 allwinner,drive = <SUN4I_PINCTRL_30_MA>;
386 allwinner,drive = <SUN4I_PINCTRL_30_MA>;
393 allwinner,drive = <SUN4I_PINCTRL_10_MA>;
400 allwinner,drive = <SUN4I_PINCTRL_10_MA>;
407 allwinner,drive = <SUN4I_PINCTRL_10_MA>;
414 allwinner,drive = <SUN4I_PINCTRL_10_MA>;
666 allwinner,drive = <SUN4I_PINCTRL_20_MA>;
673 allwinner,drive = <SUN4I_PINCTRL_10_MA>;
Dimx28-cfa10037.dts30 fsl,drive-strength = <MXS_DRIVE_4mA>;
40 fsl,drive-strength = <MXS_DRIVE_4mA>;
Dsun7i-a20-pcduino3-nano.dts153 allwinner,drive = <SUN4I_PINCTRL_10_MA>;
160 allwinner,drive = <SUN4I_PINCTRL_10_MA>;
167 allwinner,drive = <SUN4I_PINCTRL_10_MA>;
174 allwinner,drive = <SUN4I_PINCTRL_10_MA>;
Dqcom-msm8960-cdp.dts303 drive-strength = <12>;
309 drive-strength = <12>;
315 drive-strength = <12>;
322 drive-strength = <12>;
Dsun5i-a10s-mk802.dts94 allwinner,drive = <SUN4I_PINCTRL_10_MA>;
101 allwinner,drive = <SUN4I_PINCTRL_10_MA>;
108 allwinner,drive = <SUN4I_PINCTRL_10_MA>;
Dimx28-apf28dev.dts53 fsl,drive-strength = <MXS_DRIVE_4mA>;
66 fsl,drive-strength = <MXS_DRIVE_4mA>;
76 fsl,drive-strength = <MXS_DRIVE_4mA>;
Dimx28-duckbill.dts44 fsl,drive-strength = <MXS_DRIVE_4mA>;
55 fsl,drive-strength = <MXS_DRIVE_4mA>;
Dsun5i-a10s-r7-tv-dongle.dts106 allwinner,drive = <SUN4I_PINCTRL_10_MA>;
113 allwinner,drive = <SUN4I_PINCTRL_20_MA>;
120 allwinner,drive = <SUN4I_PINCTRL_10_MA>;
Ddove-cubox.dts97 silabs,drive-strength = <8>;
105 silabs,drive-strength = <8>;
Dsun7i-a20-i12-tvbox.dts203 allwinner,drive = <SUN4I_PINCTRL_10_MA>;
210 allwinner,drive = <SUN4I_PINCTRL_10_MA>;
217 allwinner,drive = <SUN4I_PINCTRL_10_MA>;
224 allwinner,drive = <SUN4I_PINCTRL_10_MA>;
Dsun7i-a20-bananapi.dts180 allwinner,drive = <SUN4I_PINCTRL_10_MA>;
187 allwinner,drive = <SUN4I_PINCTRL_10_MA>;
194 allwinner,drive = <SUN4I_PINCTRL_10_MA>;
201 allwinner,drive = <SUN4I_PINCTRL_10_MA>;
Dsun7i-a20-olinuxino-micro.dts232 allwinner,drive = <SUN4I_PINCTRL_10_MA>;
239 allwinner,drive = <SUN4I_PINCTRL_20_MA>;
246 allwinner,drive = <SUN4I_PINCTRL_10_MA>;
253 allwinner,drive = <SUN4I_PINCTRL_10_MA>;
Dimx28-evk.dts82 fsl,drive-strength = <MXS_DRIVE_4mA>;
92 fsl,drive-strength = <MXS_DRIVE_4mA>;
103 fsl,drive-strength = <MXS_DRIVE_4mA>;
116 fsl,drive-strength = <MXS_DRIVE_4mA>;
Dsun7i-a20-hummingbird.dts193 allwinner,drive = <SUN4I_PINCTRL_10_MA>;
200 allwinner,drive = <SUN4I_PINCTRL_10_MA>;
207 allwinner,drive = <SUN4I_PINCTRL_10_MA>;
214 allwinner,drive = <SUN4I_PINCTRL_10_MA>;
Dimx23-olinuxino.dts46 fsl,drive-strength = <MXS_DRIVE_4mA>;
56 fsl,drive-strength = <MXS_DRIVE_4mA>;
Dsun6i-a31-i7.dts114 allwinner,drive = <SUN4I_PINCTRL_10_MA>;
121 allwinner,drive = <SUN4I_PINCTRL_10_MA>;
128 allwinner,drive = <SUN4I_PINCTRL_10_MA>;
Dsun5i-a13-olinuxino-micro.dts116 allwinner,drive = <SUN4I_PINCTRL_10_MA>;
123 allwinner,drive = <SUN4I_PINCTRL_20_MA>;
130 allwinner,drive = <SUN4I_PINCTRL_10_MA>;
Dsun6i-a31-m9.dts114 allwinner,drive = <SUN4I_PINCTRL_10_MA>;
121 allwinner,drive = <SUN4I_PINCTRL_10_MA>;
128 allwinner,drive = <SUN4I_PINCTRL_10_MA>;
Dsun5i-a10s-auxtek-t004.dts117 allwinner,drive = <SUN4I_PINCTRL_10_MA>;
124 allwinner,drive = <SUN4I_PINCTRL_10_MA>;
131 allwinner,drive = <SUN4I_PINCTRL_20_MA>;
Dsun6i-a31-mele-a1000g-quad.dts114 allwinner,drive = <SUN4I_PINCTRL_10_MA>;
121 allwinner,drive = <SUN4I_PINCTRL_10_MA>;
128 allwinner,drive = <SUN4I_PINCTRL_10_MA>;
Dimx28-m28cu3.dts78 fsl,drive-strength = <MXS_DRIVE_4mA>;
93 fsl,drive-strength = <MXS_DRIVE_4mA>;
104 fsl,drive-strength = <MXS_DRIVE_4mA>;
Dimx28-cfa10058.dts31 fsl,drive-strength = <MXS_DRIVE_4mA>;
44 fsl,drive-strength = <MXS_DRIVE_4mA>;
Dsun6i-a31-colombus.dts134 allwinner,drive = <SUN4I_PINCTRL_10_MA>;
141 allwinner,drive = <SUN4I_PINCTRL_10_MA>;
148 allwinner,drive = <SUN4I_PINCTRL_10_MA>;
Dsun5i.dtsi516 allwinner,drive = <SUN4I_PINCTRL_10_MA>;
523 allwinner,drive = <SUN4I_PINCTRL_10_MA>;
530 allwinner,drive = <SUN4I_PINCTRL_10_MA>;
538 allwinner,drive = <SUN4I_PINCTRL_30_MA>;
547 allwinner,drive = <SUN4I_PINCTRL_30_MA>;
554 allwinner,drive = <SUN4I_PINCTRL_10_MA>;
561 allwinner,drive = <SUN4I_PINCTRL_10_MA>;
568 allwinner,drive = <SUN4I_PINCTRL_10_MA>;
/linux-4.4.14/arch/x86/boot/
Dmtools.conf.in5 # Actual floppy drive
6 drive a:
10 drive v:
14 drive w:
/linux-4.4.14/Documentation/ioctl/
Dcdrom.txt21 CDROMSTOP Stop the cdrom drive
22 CDROMSTART Start the cdrom drive
38 CDROMRESET hard-reset the drive
39 CDROMVOLREAD Get the drive's volume setting
65 CDROM_SEND_PACKET send a packet to the drive
108 ENOSYS cd drive not audio-capable.
122 ENOSYS cd drive not audio-capable.
138 ENOSYS cd drive not audio-capable.
162 ENOSYS cd drive not audio-capable.
184 ENOSYS cd drive not audio-capable.
[all …]
Dhdio.txt36 HDIO_DRIVE_TASK execute task and special drive command
37 HDIO_DRIVE_CMD execute a special drive command
106 EINVAL if the device is not a disk drive or floppy drive,
115 drive geometry is an abstraction which is actually subject
117 are the "bios" values -- presumably the values the drive had
141 The value of the drive's current unmask setting
177 controls how many sectors the drive will transfer per
191 sectors the drive will transfer per interrupt.
230 returns the first 142 bytes of drive identity information.
245 ATA drive identity information. For full description, see
[all …]
/linux-4.4.14/Documentation/ABI/testing/
Dsysfs-bus-pci-devices-cciss5 Description: Displays the SCSI INQUIRY page 0 model for logical drive
13 drive Y of controller X.
20 drive Y of controller X.
26 Description: Displays the SCSI INQUIRY page 0 vendor for logical drive
40 drive topology changes.
47 drive Y of controller X.
53 Description: Displays the RAID level of logical drive Y of
60 Description: Displays the usage count (number of opens) of logical drive Y
Dsysfs-class-scsi_tape17 to and from the tape drive to complete. This includes all
19 drive. An example of other SCSI commands would be tape
33 The number of I/O requests issued to the tape drive other
43 Shows the total number of bytes requested from the tape drive.
55 drive.
74 Shows the total number of bytes written to the tape drive.
86 drive.
/linux-4.4.14/Documentation/cdrom/
Dide-cd13 interface. If your drive uses one of those proprietary interfaces,
16 attach to the parallel port. In addition, there is at least one drive
74 3. The CDROM drive should be connected to the host on an IDE
79 where each device can be a hard drive, a CDROM drive, a floppy drive,
80 or a tape drive. The two devices on an interface are called `master'
81 and `slave'; this is usually selectable via a jumper on the drive.
89 If you want your CDROM drive to be found automatically by the
92 the CDROM drive is the only device on the IDE interface, it should
99 4. Boot the system. If the drive is recognized, you should see a
102 hdb: NEC CD-ROM DRIVE:260, ATAPI CDROM drive
[all …]
Dcdrom-standard.tex53 devices; the way a particular drive reacts to a `standard' $ioctl()$
67 When the \cdrom\ was developed, the interface between the \cdrom\ drive
75 most of the `NoName' manufacturers). In cases where a new drive really
90 capabilities of a particular drive, in an {\fo ad hoc\/} manner. More
106 of the low-level device drivers for each \cdrom\ drive. By adding this
125 more than one \cdrom\ drive, possibly of mixed types. It is important
128 drive. In the months that I was busy writing a \linux\ driver for it,
132 16 speed \cdrom\ drive, and 24 speed drives are common.
145 drive behavior, and to provide a common set of services to the various
206 This structure contains information about a particular \cdrom\ drive,
[all …]
/linux-4.4.14/Documentation/laptops/
Ddisk-shock-protection.txt21 Issuing this command should cause the drive to switch to idle mode and
25 the internal hard drive and park its heads on the ramp when critical
43 of the respective drive off the platter and block all I/O operations
61 For example, do the following in order to park the heads of drive
96 the same port as the hard drive, it generally *should* recover just
100 instead of /dev/sda), then parking the heads of one drive (drive X)
101 will generally not affect the mode of operation of another drive
102 (drive Y) on the same port as described above. It is only when a port
103 reset is required to recover from an exception on drive Y that further
104 I/O operations on that drive (and the reset itself) will be delayed
[all …]
/linux-4.4.14/Documentation/ide/
DChangeLog.ide-floppy.1996-20023 * ALPHA patches to this driver on an EASYSTOR LS-120 ATAPI floppy drive.
24 * bit. My LS-120 drive barfs on
39 * If drive does not support format progress indication
44 * Ver 0.91 Dec 11 99 Added IOMEGA Clik! drive support by
48 * Ver 0.93 Oct 24 00 Fixed bugs for Clik! drive
59 * drive before the drive was actually ready.
Dide.txt2 Information regarding the Enhanced IDE drive in Linux 2.6
22 *** drive for which the "prefetch" mode of the CMD640 is turned on.
26 *** For the CMD640, linux disables "32bit I/O" (hdparm -c1) on any drive
96 If the auto-probing during boot time confuses a drive (ie. the drive works
98 for each drive for which you'd like the drive to skip the hardware
109 for both units, though success is more likely when the drive is jumpered
116 If for some reason your cdrom drive is *not* found at boot time, you can force
124 For example, a GW2000 system might have a hard drive on the primary
125 interface (/dev/hda) and an IDE cdrom drive on the secondary interface
126 (/dev/hdc). To mount a CD in the cdrom drive, one would use something like:
[all …]
DChangeLog.ide-cd.1994-200434 * showed up if the drive returned data in 512 byte
56 * some drive not ready errors.
85 * 3.07a Feb 11, 1996 -- check drive->id for NULL before dereferencing, to fix
86 * problem with "hde=cdrom" with no drive present. -ml
122 * -- Add some probes of drive capability during setup.
132 * to fix the drive door locking problems.
138 * 4.05 Nov 20, 1997 -- Modified to print more drive info on init
196 * drive in transfer size limit.
241 * - Fixed a problem with WPI CDS-32X drive - it
/linux-4.4.14/drivers/pinctrl/
Dpinctrl-digicolor.c177 u8 drive; in dc_gpio_direction_input() local
181 drive = readb_relaxed(pmap->regs + reg_off); in dc_gpio_direction_input()
182 drive &= ~BIT(bit_off); in dc_gpio_direction_input()
183 writeb_relaxed(drive, pmap->regs + reg_off); in dc_gpio_direction_input()
197 u8 drive; in dc_gpio_direction_output() local
203 drive = readb_relaxed(pmap->regs + reg_off); in dc_gpio_direction_output()
204 drive |= BIT(bit_off); in dc_gpio_direction_output()
205 writeb_relaxed(drive, pmap->regs + reg_off); in dc_gpio_direction_output()
/linux-4.4.14/Documentation/devicetree/bindings/pinctrl/
Dqcom,ipq8064-pinctrl.txt25 parameters, such as pull-up, drive strength, etc.
40 pins, function, bias-disable, bias-pull-down, bias-pull,up, drive-strength,
47 Supports mux, bias, and drive-strength
50 Supports bias and drive-strength
85 drive-strength = <4>;
91 drive-strength = <2>;
Dqcom,msm8974-pinctrl.txt25 parameters, such as pull-up, drive strength, etc.
39 pins, function, bias-disable, bias-pull-down, bias-pull,up, drive-strength.
47 Supports mux, bias and drive-strength
50 Supports bias and drive-strength
102 drive-strength = <4>;
108 drive-strength = <2>;
Dallwinner,sunxi-pinctrl.txt6 the pins includes drive strength and pull-up.
31 configuration, drive strength and pullups. If one of these options is
40 - allwinner,drive: Integer. Represents the current sent to the pin
61 allwinner,drive = <0>;
68 allwinner,drive = <0>;
Dqcom,pmic-gpio.txt155 - qcom,drive-strength:
158 Definition: Selects the drive strength for the specified pins. Value
159 drive strengths are:
166 - drive-push-pull:
171 - drive-open-drain:
176 - drive-open-source:
212 drive-push-pull;
213 qcom,drive-strength = <PMIC_GPIO_STRENGTH_NO>;
Dimg,tz1090-pinctrl.txt16 parameters, such as pull-up, drive strength, etc.
47 - drive-strength: Integer, control drive strength of pins in mA.
115 These all support function, and some support drive configs.
124 drive-strength: supported.
152 drive-strength: supported.
154 drive groups:
157 and drive-strength.
185 These are just convenient groupings of pins and don't support any drive
Dqcom,apq8064-pinctrl.txt25 parameters, such as pull-up, drive strength, etc.
40 pins, function, bias-disable, bias-pull-down, bias-pull,up, drive-strength,
78 drive-strength = <4>;
84 drive-strength = <2>;
Dimg,tz1090-pdc-pinctrl.txt16 parameters, such as pull-up, drive strength, etc.
47 - drive-strength: Integer, control drive strength of pins in mA.
81 drive groups:
84 drive-strength, low-power-enable, and low-power-disable.
Dqcom,msm8660-pinctrl.txt25 parameters, such as pull-up, drive strength, etc.
40 pins, function, bias-disable, bias-pull-down, bias-pull,up, drive-strength,
80 drive-strength = <8>;
86 drive-strength = <2>;
Dpinctrl-bindings.txt4 such as pull-up/down, tri-state, drive-strength etc are designated as pin
183 drive-push-pull - drive actively high and low
184 drive-open-drain - drive with open drain
185 drive-open-source - drive with open source
186 drive-strength - sink or source at most X mA
230 - drive-strength takes as argument the target strength in mA.
Dbrcm,cygnus-gpio.txt52 - drive-strength:
53 Valid drive strength values include 2, 4, 6, 8, 10, 12, 14, 16 (mA)
68 drive-strength = <16>;
Dqcom,msm8960-pinctrl.txt54 parameters, such as pull-up, drive strength, etc.
145 - drive-strength:
148 Definition: Selects the drive strength for the specified pins, in mA.
171 drive-strength = <4>;
177 drive-strength = <2>;
Dqcom,apq8084-pinctrl.txt54 parameters, such as pull-up, drive strength, etc.
143 - drive-strength:
146 Definition: Selects the drive strength for the specified pins, in mA.
169 drive-strength = <4>;
175 drive-strength = <2>;
Dqcom,msm8916-pinctrl.txt54 parameters, such as pull-up, drive strength, etc.
151 - drive-strength:
154 Definition: Selects the drive strength for the specified pins, in mA.
176 drive-strength = <4>;
182 drive-strength = <2>;
Dnvidia,tegra20-pinmux.txt16 parameters, such as pull-up, tristate, drive strength, etc.
41 0: drive, 1: tristate.
47 most power. Controls the drive power or current. See "Low Power Mode"
49 - nvidia,pull-down-strength: Integer. Controls drive strength. 0 is weakest.
52 - nvidia,pull-up-strength: Integer. Controls drive strength. 0 is weakest.
92 drive groups:
Dpinctrl-mt65xx.txt44 configuration, pullups, drive strength, input enable/disable and input schmitt.
59 input-schmitt-enable, input-schmitt-disable and drive-strength are valid.
67 When config drive-strength, it can support some arguments, such as
144 drive-strength = <32>;
Dfsl,mxs-pinctrl.txt5 function is GPIO. The configuration on the pins includes drive strength,
19 In other words, a subnode that describes a drive strength parameter implies no
61 - fsl,drive-strength: Integer.
100 fsl,drive-strength = <MXS_DRIVE_4mA>;
112 fsl,drive-strength = <MXS_DRIVE_12mA>;
Datmel,at91-pinctrl.txt18 such as pull-up, multi drive, etc.
90 MULTIDRIVE (1 << 1): indicate this pin needs to be configured as multi-drive.
91 Multi-drive is equivalent to open-drain type output.
95 DRIVE_STRENGTH (3 << 5): indicate the drive strength of the pin using the
Dnvidia,tegra210-pinmux.txt17 parameters, such as pull-up, tristate, drive strength, etc.
45 0: drive, 1: tristate.
65 - nvidia,drive-type: Integer. Valid range 0...3.
66 - nvidia,pull-down-strength: Integer. Controls drive strength. 0 is weakest.
69 - nvidia,pull-up-strength: Integer. Controls drive strength. 0 is weakest.
/linux-4.4.14/Documentation/scsi/
Dst.txt11 to any specific tape drive. The tape parameters can be specified with
23 new tape is loaded into the drive or if writing begins at the
25 drive performs auto-detection of the tape format well (like some
29 for the first time). The first method is applicable if the drive
31 "sensible" mode for the device. An example is a DAT drive that is
69 of the physical block on tape. When reading, the drive reads the next
73 In fixed block mode, the data transfer between the drive and the
89 as a synchronization point, i.e., all remaining data form the drive buffers is
93 write the filemarks without flushing the drive buffer. Writing filemark at
94 close() is always flushing the drive buffers. However, if the previous
[all …]
/linux-4.4.14/Documentation/devicetree/bindings/clock/
Dsilabs,si5351.txt44 - silabs,drive-strength: output drive strength in mA, shall be one of {2,4,6,8}.
82 * - 8mA output drive strength
90 silabs,drive-strength = <8>;
99 * - 4mA output drive strength
106 silabs,drive-strength = <4>;
/linux-4.4.14/Documentation/blockdev/
DREADME.DAC96086 disks the device names will not change in the event of a disk drive failure.
238 there are only at most 6 usable partitions on each logical drive, systems
239 requiring more partitions should subdivide a drive group into multiple logical
243 will cause the logical drive geometry to have more than 65535 cylinders which
282 soon as a drive replacement is made available.
365 The "kill" command marks the physical drive <channel>:<target-id> as DEAD.
371 The "make-online" command changes the physical drive <channel>:<target-id>
374 one of them back online, after which a rebuild to the final drive is
377 Warning: make-online should only be used on a dead physical drive that is
378 an active part of a drive group, never on a standby drive. The command
[all …]
Dcciss.txt33 Detecting drive failures:
36 To get the status of logical volumes and to detect physical drive
91 SCSI tape drive and medium changer support
97 You must enable "SCSI tape drive support for Smart Array 5xxx" and
173 In the event the error handling code is triggered and a tape drive is
175 tape drive may still not allow i/o to continue until some command
178 before i/o can proceed again to a tape drive which was reset.
Dparide.txt27 were to open up a parallel port CD-ROM drive, for instance, one would
28 find a standard ATAPI CD-ROM drive, a power supply, and a single adapter
41 MicroSolutions backpack 8000t tape drive
96 what kind of parallel port adapter is used in your drive, you could
111 MicroSolutions PD drive pf bpck
112 MicroSolutions hard-drive pd bpck
142 protocol identification number and, for some devices, the drive's
156 also need to know the unit ID number for each drive. This is usually
157 the last two digits of the drive's serial number (but read MicroSolutions'
160 As an example, let's assume that you have a MicroSolutions PD/CD drive
[all …]
/linux-4.4.14/arch/sparc/include/asm/
Dfloppy_64.h78 #define fd_eject(drive) sun_fdops.fd_eject(drive) argument
274 static int sun_fd_eject(int drive) in sun_fd_eject() argument
427 static int sun_pci_fd_eject(int drive) in sun_pci_fd_eject() argument
498 static int sun_pci_fd_test_drive(unsigned long port, int drive) in sun_pci_fd_test_drive() argument
506 data = (0x10 << drive) | 0x0c | drive; in sun_pci_fd_test_drive()
510 sun_pci_fd_out_byte(port, drive & 0x03, FIFO); in sun_pci_fd_test_drive()
/linux-4.4.14/drivers/block/paride/
Dpf.c235 int drive; /* drive */ member
293 pf->drive = (*drives[unit])[D_SLV]; in pf_init_units()
431 write_reg(pf, 6, 0xa0+0x10*pf->drive); in pf_command()
542 write_reg(pf, 6, 0xa0+0x10*pf->drive); in pf_reset()
621 pf->name, pf->drive, pf->lun, bs); in pf_get_capacity()
642 pf->name, pf->drive, pf->lun, dt); in pf_identify()
658 pf->name, mf, id, ms[pf->drive], pf->lun, dt); in pf_identify()
677 if (pf->drive == -1) { in pf_probe()
678 for (pf->drive = 0; pf->drive <= 1; pf->drive++) in pf_probe()
Dpg.c216 int drive; /* drive */ member
256 dev->drive = parm[D_SLV]; in pg_init_units()
280 return 0xa0+0x10*dev->drive; in DRIVE()
455 printk("%s: %s %s, %s\n", dev->name, mf, id, ms[dev->drive]); in pg_identify()
467 if (dev->drive == -1) { in pg_probe()
468 for (dev->drive = 0; dev->drive <= 1; dev->drive++) in pg_probe()
Dpcd.c195 int drive; /* master/slave */ member
308 cd->drive = (*drives[unit])[D_SLV]; in pcd_init_units()
382 write_reg(cd, 6, 0xa0 + 0x10 * cd->drive); in pcd_command()
545 write_reg(cd, 6, 0xa0 + 0x10 * cd->drive); in pcd_reset()
622 cd->name, cd->drive ? "Slave" : "Master"); in pcd_identify()
633 printk("%s: %s: %s\n", cd->name, cd->drive ? "Slave" : "Master", id); in pcd_identify()
645 for (cd->drive = 0; cd->drive <= 1; cd->drive++) in pcd_probe()
649 cd->drive = ms; in pcd_probe()
Dpd.c232 int drive; /* master=0 slave=1 */ member
274 return 0xa0+0x10*disk->drive; in DRIVE()
663 if (disk->drive == 0) in pd_identify()
694 disk->drive ? "slave" : "master", in pd_identify()
847 if (disk->drive == -1) { in pd_probe_drive()
848 for (disk->drive = 0; disk->drive <= 1; disk->drive++) in pd_probe_drive()
869 disk->drive = parm[D_SLV]; in pd_detect()
Dpt.c221 int drive; /* drive */ member
269 return 0xa0+0x10*tape->drive; in DRIVE()
548 tape->name, tape->drive, dt); in pt_identify()
571 printk("%s: %s %s, %s", tape->name, mf, id, ms[tape->drive]); in pt_identify()
590 if (tape->drive == -1) { in pt_probe()
591 for (tape->drive = 0; tape->drive <= 1; tape->drive++) in pt_probe()
624 tape->drive = DU[D_SLV]; in pt_detect()
DKconfig37 you have such a CD-ROM drive, you should also say Y or M to "ISO
52 MicroSolutions backpack PD/CD drive and the Imation Superdisk
53 LS-120 drive.
66 parallel port version of the HP 5GB drive.
115 Series noted on the bottom of the drive. Series 6 drivers will.
117 In other words, if your BACKPACK drive doesn't say "Series 6" on the
133 on the bottom of the drive. Series 5 drivers don't always have it
136 In other words, if your BACKPACK drive says "Series 6" on the
213 (LS-120) drive.
233 drive. If you chose to build PARIDE support into your kernel, you
/linux-4.4.14/arch/arm64/boot/dts/mediatek/
Dmt8173-evb.dts129 drive-strength = <MTK_DRIVE_4mA>;
136 drive-strength = <MTK_DRIVE_4mA>;
157 drive-strength = <MTK_DRIVE_2mA>;
163 drive-strength = <MTK_DRIVE_2mA>;
181 drive-strength = <MTK_DRIVE_4mA>;
187 drive-strength = <MTK_DRIVE_4mA>;
/linux-4.4.14/drivers/input/keyboard/
Dqt2160.c92 u32 drive, pwmen; in qt2160_led_work() local
96 drive = qt2160_read(client, QT2160_CMD_DRIVE_X); in qt2160_led_work()
99 drive |= (1 << led->id); in qt2160_led_work()
103 drive &= ~(1 << led->id); in qt2160_led_work()
106 qt2160_write(client, QT2160_CMD_DRIVE_X, drive); in qt2160_led_work()
/linux-4.4.14/Documentation/devicetree/bindings/net/wireless/
Dbrcm,bcm43xx-fmac.txt12 - brcm,drive-strength : drive strength used for SDIO pins on device in mA
/linux-4.4.14/drivers/ata/
Dpata_acpi.c122 acpi->gtm.drive[unit].pio = t->cycle; in pacpi_set_piomode()
146 acpi->gtm.drive[unit].dma = t->udma; in pacpi_set_dmamode()
149 acpi->gtm.drive[unit].dma = t->cycle; in pacpi_set_dmamode()
/linux-4.4.14/drivers/scsi/
Dgdth_proc.c29 int orig_length, drive, wb_mode; in gdth_set_asc_info() local
41 drive = -1; in gdth_set_asc_info()
49 drive = (int)(*buffer-'0'); in gdth_set_asc_info()
52 drive = drive*10 + (int)(*buffer-'0'); in gdth_set_asc_info()
55 printk("GDT: Flushing host drive %d .. ",drive); in gdth_set_asc_info()
61 if (drive != -1 && i != drive) in gdth_set_asc_info()
/linux-4.4.14/Documentation/devicetree/bindings/input/touchscreen/
Dstmpe.txt24 - st,i-drive: current limit value of the touchscreen drivers (0 -> 20 mA typical 35
42 st,i-drive = <1>;
/linux-4.4.14/Documentation/
Ddevices.txt135 0 = /dev/fd0 Controller 0, drive 0, autodetect
136 1 = /dev/fd1 Controller 0, drive 1, autodetect
137 2 = /dev/fd2 Controller 0, drive 2, autodetect
138 3 = /dev/fd3 Controller 0, drive 3, autodetect
139 128 = /dev/fd4 Controller 1, drive 0, autodetect
140 129 = /dev/fd5 Controller 1, drive 1, autodetect
141 130 = /dev/fd6 Controller 1, drive 2, autodetect
142 131 = /dev/fd7 Controller 1, drive 3, autodetect
146 4 = /dev/fd?d360 5.25" 360K in a 360K drive(1)
147 20 = /dev/fd?h360 5.25" 360K in a 1200K drive(1)
[all …]
/linux-4.4.14/Documentation/devicetree/bindings/gpio/
Dgpio-stp-xway.txt4 peripheral controller used to drive external shift register cascades. At most
6 to drive the 2 LSBs of the cascade automatically.
/linux-4.4.14/drivers/platform/goldfish/
DKconfig4 This is a virtual device to drive the QEMU pipe interface used by
/linux-4.4.14/drivers/md/
DKconfig90 of a single drive, and the set protects against a failure of (N - 1)
132 A RAID-5 set of N drives with a capacity of C MB per drive provides
134 of a single drive. For a given sector (row) number, (N - 1) drives
135 contain data sectors, and one drive contains the parity protection.
136 For a RAID-4 set, the parity blocks are present on a single drive,
140 A RAID-6 set of N drives with a capacity of C MB per drive
367 A RAID-5 set of N drives with a capacity of C MB per drive provides
369 of a single drive. For a given sector (row) number, (N - 1) drives
370 contain data sectors, and one drive contains the parity protection.
371 For a RAID-4 set, the parity blocks are present on a single drive,
[all …]
/linux-4.4.14/Documentation/sound/alsa/soc/
Dclocking.txt24 as BCLK). This clock is used to drive the digital audio data across the link
47 It is also desirable to use the codec (if possible) to drive (or master) the

123