/Linux-v5.4/drivers/staging/comedi/drivers/ |
D | ni_labpc_common.c | 337 struct comedi_8254 *pacer = dev->pacer; in labpc_adc_timing() local 352 pacer->next_div1 = (scan_period - 1) / in labpc_adc_timing() 353 (pacer->osc_base * I8254_MAX_COUNT) + 1; in labpc_adc_timing() 355 comedi_check_trigger_arg_min(&pacer->next_div1, 2); in labpc_adc_timing() 356 comedi_check_trigger_arg_max(&pacer->next_div1, in labpc_adc_timing() 359 base_period = pacer->osc_base * pacer->next_div1; in labpc_adc_timing() 365 pacer->next_div = DIV_ROUND_CLOSEST(convert_period, in labpc_adc_timing() 367 pacer->next_div2 = DIV_ROUND_CLOSEST(scan_period, in labpc_adc_timing() 371 pacer->next_div = DIV_ROUND_UP(convert_period, in labpc_adc_timing() 373 pacer->next_div2 = DIV_ROUND_UP(scan_period, in labpc_adc_timing() [all …]
|
D | cb_pcimdas.c | 368 dev->pacer = comedi_8254_init(devpriv->BADR3 + PCIMDAS_8254_BASE, in cb_pcimdas_auto_attach() 371 if (!dev->pacer) in cb_pcimdas_auto_attach() 433 comedi_8254_subdevice_init(s, dev->pacer); in cb_pcimdas_auto_attach() 435 dev->pacer->insn_config = cb_pcimdas_counter_insn_config; in cb_pcimdas_auto_attach() 438 comedi_8254_set_busy(dev->pacer, 1, true); in cb_pcimdas_auto_attach() 439 comedi_8254_set_busy(dev->pacer, 2, true); in cb_pcimdas_auto_attach()
|
D | aio_aio12_8.c | 210 dev->pacer = comedi_8254_init(dev->iobase + AIO12_8_8254_BASE_REG, in aio_aio12_8_attach() 212 if (!dev->pacer) in aio_aio12_8_attach() 257 comedi_8254_subdevice_init(s, dev->pacer); in aio_aio12_8_attach() 259 dev->pacer->insn_config = aio_aio12_8_counter_insn_config; in aio_aio12_8_attach()
|
D | adl_pci9118.c | 399 comedi_8254_load(dev->pacer, 0, dmabuf->hw >> 1, in pci9118_ai_mode4_switch() 536 struct comedi_8254 *pacer = dev->pacer; in pci9118_calc_divisors() local 539 *div1 = *tim2 / pacer->osc_base; /* convert timer (burst) */ in pci9118_calc_divisors() 540 *div2 = *tim1 / pacer->osc_base; /* scan timer */ in pci9118_calc_divisors() 545 *tim2 = *div1 * pacer->osc_base; /* real convert timer */ in pci9118_calc_divisors() 553 *tim1 = *div1 * *div2 * pacer->osc_base; in pci9118_calc_divisors() 559 comedi_8254_pacer_enable(dev->pacer, 1, 2, true); in pci9118_start_pacer() 570 comedi_8254_pacer_enable(dev->pacer, 1, 2, false); in pci9118_ai_cancel() 920 struct comedi_8254 *pacer = dev->pacer; in pci9118_ai_cmd() local 1041 comedi_8254_cascade_ns_to_timer(pacer, &cmd->convert_arg, in pci9118_ai_cmd() [all …]
|
D | ni_at_ao.c | 275 comedi_8254_set_mode(dev->pacer, 0, I8254_MODE4 | I8254_BINARY); in atao_reset() 276 comedi_8254_set_mode(dev->pacer, 1, I8254_MODE4 | I8254_BINARY); in atao_reset() 277 comedi_8254_write(dev->pacer, 0, 0x0003); in atao_reset() 308 dev->pacer = comedi_8254_init(dev->iobase + ATAO_82C53_BASE, in atao_attach() 310 if (!dev->pacer) in atao_attach()
|
D | cb_das16_cs.c | 368 dev->pacer = comedi_8254_init(dev->iobase + DAS16CS_TIMER_BASE, in das16cs_auto_attach() 370 if (!dev->pacer) in das16cs_auto_attach() 415 comedi_8254_subdevice_init(s, dev->pacer); in das16cs_auto_attach() 417 dev->pacer->insn_config = das16cs_counter_insn_config; in das16cs_auto_attach() 420 comedi_8254_set_busy(dev->pacer, 1, true); in das16cs_auto_attach() 421 comedi_8254_set_busy(dev->pacer, 2, true); in das16cs_auto_attach()
|
D | adv_pci1710.c | 384 comedi_8254_pacer_enable(dev->pacer, 1, 2, false); in pci1710_ai_cancel() 508 comedi_8254_pacer_enable(dev->pacer, 1, 2, true); in pci1710_irq_handler() 538 comedi_8254_update_divisors(dev->pacer); in pci1710_ai_cmd() 554 comedi_8254_pacer_enable(dev->pacer, 1, 2, true); in pci1710_ai_cmd() 618 comedi_8254_cascade_ns_to_timer(dev->pacer, &arg, cmd->flags); in pci1710_ai_cmdtest() 771 dev->pacer = comedi_8254_init(dev->iobase + PCI171X_TIMER_BASE, in pci1710_auto_attach() 773 if (!dev->pacer) in pci1710_auto_attach() 865 comedi_8254_subdevice_init(s, dev->pacer); in pci1710_auto_attach() 867 dev->pacer->insn_config = pci1710_counter_insn_config; in pci1710_auto_attach() 870 comedi_8254_set_busy(dev->pacer, 1, true); in pci1710_auto_attach() [all …]
|
D | pcl816.c | 387 comedi_8254_cascade_ns_to_timer(dev->pacer, &arg, cmd->flags); in pcl816_ai_cmdtest() 430 comedi_8254_set_mode(dev->pacer, 0, I8254_MODE1 | I8254_BINARY); in pcl816_ai_cmd() 431 comedi_8254_write(dev->pacer, 0, 0x0ff); in pcl816_ai_cmd() 433 comedi_8254_update_divisors(dev->pacer); in pcl816_ai_cmd() 434 comedi_8254_pacer_enable(dev->pacer, 1, 2, true); in pcl816_ai_cmd() 494 comedi_8254_pacer_enable(dev->pacer, 1, 2, false); in pcl816_ai_cancel() 620 dev->pacer = comedi_8254_init(dev->iobase + PCL816_TIMER_BASE, in pcl816_attach() 622 if (!dev->pacer) in pcl816_attach()
|
D | pcl711.c | 329 comedi_8254_cascade_ns_to_timer(dev->pacer, &arg, cmd->flags); in pcl711_ai_cmdtest() 346 comedi_8254_update_divisors(dev->pacer); in pcl711_ai_cmd() 347 comedi_8254_pacer_enable(dev->pacer, 1, 2, true); in pcl711_ai_cmd() 434 dev->pacer = comedi_8254_init(dev->iobase + PCL711_TIMER_BASE, in pcl711_attach() 436 if (!dev->pacer) in pcl711_attach()
|
D | das16m1.c | 222 comedi_8254_cascade_ns_to_timer(dev->pacer, &arg, cmd->flags); in das16m1_ai_cmdtest() 269 comedi_8254_update_divisors(dev->pacer); in das16m1_ai_cmd() 270 comedi_8254_pacer_enable(dev->pacer, 1, 2, true); in das16m1_ai_cmd() 533 dev->pacer = comedi_8254_init(dev->iobase + DAS16M1_8254_IOBASE2, in das16m1_attach() 535 if (!dev->pacer) in das16m1_attach()
|
D | das6402.c | 237 comedi_8254_update_divisors(dev->pacer); in das6402_ai_cmd() 238 comedi_8254_pacer_enable(dev->pacer, 1, 2, true); in das6402_ai_cmd() 336 comedi_8254_cascade_ns_to_timer(dev->pacer, &arg, cmd->flags); in das6402_ai_cmdtest() 595 dev->pacer = comedi_8254_init(dev->iobase + DAS6402_TIMER_BASE, in das6402_attach() 597 if (!dev->pacer) in das6402_attach()
|
D | das800.c | 349 comedi_8254_cascade_ns_to_timer(dev->pacer, &arg, cmd->flags); in das800_ai_do_cmdtest() 401 comedi_8254_update_divisors(dev->pacer); in das800_ai_do_cmd() 402 comedi_8254_pacer_enable(dev->pacer, 1, 2, true); in das800_ai_do_cmd() 677 dev->pacer = comedi_8254_init(dev->iobase + DAS800_8254, in das800_attach() 679 if (!dev->pacer) in das800_attach()
|
D | adl_pci9111.c | 306 comedi_8254_cascade_ns_to_timer(dev->pacer, &arg, cmd->flags); in pci9111_ai_do_cmd_test() 361 comedi_8254_update_divisors(dev->pacer); in pci9111_ai_do_cmd() 362 comedi_8254_pacer_enable(dev->pacer, 1, 2, true); in pci9111_ai_do_cmd() 651 dev->pacer = comedi_8254_init(dev->iobase + PCI9111_8254_BASE_REG, in pci9111_auto_attach() 653 if (!dev->pacer) in pci9111_auto_attach()
|
D | das08.c | 443 dev->pacer = comedi_8254_init(dev->iobase + board->i8254_offset, in das08_common_attach() 445 if (!dev->pacer) in das08_common_attach() 448 comedi_8254_subdevice_init(s, dev->pacer); in das08_common_attach()
|
D | das16.c | 664 comedi_8254_cascade_ns_to_timer(dev->pacer, &arg, cmd->flags); in das16_cmd_test() 669 comedi_8254_cascade_ns_to_timer(dev->pacer, &arg, cmd->flags); in das16_cmd_test() 688 comedi_8254_cascade_ns_to_timer(dev->pacer, &ns, flags); in das16_set_pacer() 689 comedi_8254_update_divisors(dev->pacer); in das16_set_pacer() 690 comedi_8254_pacer_enable(dev->pacer, 1, 2, true); in das16_set_pacer() 1072 dev->pacer = comedi_8254_init(dev->iobase + DAS16_TIMER_BASE_REG, in das16_attach() 1074 if (!dev->pacer) in das16_attach()
|
D | das1800.c | 559 comedi_8254_cascade_ns_to_timer(dev->pacer, &arg, cmd->flags); in das1800_ai_fixup_paced_timing() 606 comedi_8254_cascade_ns_to_timer(dev->pacer, &arg, cmd->flags); in das1800_ai_fixup_burst_timing() 902 comedi_8254_update_divisors(dev->pacer); in das1800_ai_cmd() 903 comedi_8254_pacer_enable(dev->pacer, 1, 2, true); in das1800_ai_cmd() 908 comedi_8254_load(dev->pacer, 0, 1, I8254_MODE0 | I8254_BINARY); in das1800_ai_cmd() 1238 dev->pacer = comedi_8254_init(dev->iobase + DAS1800_COUNTER, in das1800_attach() 1240 if (!dev->pacer) in das1800_attach()
|
D | pcl812.c | 694 comedi_8254_cascade_ns_to_timer(dev->pacer, &arg, cmd->flags); in pcl812_ai_cmdtest() 745 comedi_8254_update_divisors(dev->pacer); in pcl812_ai_cmd() 746 comedi_8254_pacer_enable(dev->pacer, 1, 2, true); in pcl812_ai_cmd() 904 comedi_8254_pacer_enable(dev->pacer, 1, 2, false); in pcl812_ai_cancel() 1148 dev->pacer = comedi_8254_init(dev->iobase + PCL812_TIMER_BASE, in pcl812_attach() 1151 if (!dev->pacer) in pcl812_attach()
|
D | pcl818.c | 690 comedi_8254_cascade_ns_to_timer(dev->pacer, &arg, cmd->flags); in ai_cmdtest() 752 comedi_8254_update_divisors(dev->pacer); in pcl818_ai_cmd() 753 comedi_8254_pacer_enable(dev->pacer, 1, 2, true); in pcl818_ai_cmd() 786 comedi_8254_pacer_enable(dev->pacer, 1, 2, false); in pcl818_ai_cancel() 1020 dev->pacer = comedi_8254_init(dev->iobase + PCL818_TIMER_BASE, in pcl818_attach() 1022 if (!dev->pacer) in pcl818_attach()
|
D | amplc_pci230.c | 690 comedi_8254_set_mode(dev->pacer, ct, mode); in pci230_ct_setup_ns_mode() 699 comedi_8254_write(dev->pacer, ct, count); in pci230_ct_setup_ns_mode() 705 comedi_8254_set_mode(dev->pacer, ct, I8254_MODE1); in pci230_cancel_ct() 755 comedi_8254_set_mode(dev->pacer, 2, I8254_MODE0); in pci230_ai_insn_read() 806 comedi_8254_set_mode(dev->pacer, 2, I8254_MODE0); in pci230_ai_insn_read() 807 comedi_8254_set_mode(dev->pacer, 2, I8254_MODE1); in pci230_ai_insn_read() 1765 comedi_8254_set_mode(dev->pacer, 2, I8254_MODE0); in pci230_ai_inttrig_convert() 1766 comedi_8254_set_mode(dev->pacer, 2, I8254_MODE1); in pci230_ai_inttrig_convert() 2187 comedi_8254_set_mode(dev->pacer, 2, I8254_MODE1); in pci230_ai_cmd() 2480 dev->pacer = comedi_8254_init(dev->iobase + PCI230_Z2_CT_BASE, in pci230_auto_attach() [all …]
|
D | adv_pci_dio.c | 448 dev->pacer = comedi_8254_init(dev->iobase + in pci_dio_auto_attach() 451 if (!dev->pacer) in pci_dio_auto_attach() 454 comedi_8254_subdevice_init(s, dev->pacer); in pci_dio_auto_attach()
|
D | amplc_pci224.c | 790 comedi_8254_cascade_ns_to_timer(dev->pacer, &arg, cmd->flags); in pci224_ao_cmdtest() 828 comedi_8254_pacer_enable(dev->pacer, 2, 0, false); in pci224_ao_start_pacer() 884 comedi_8254_update_divisors(dev->pacer); in pci224_ao_cmd() 1056 dev->pacer = comedi_8254_init(devpriv->iobase1 + PCI224_Z2_BASE, in pci224_auto_attach() 1058 if (!dev->pacer) in pci224_auto_attach()
|
D | ni_at_a2150.c | 531 comedi_8254_load(dev->pacer, 2, 72, I8254_MODE0 | I8254_BINARY); in a2150_ai_cmd() 712 dev->pacer = comedi_8254_init(dev->iobase + I8253_BASE_REG, in a2150_attach() 714 if (!dev->pacer) in a2150_attach()
|
D | cb_pcidas.c | 763 comedi_8254_cascade_ns_to_timer(dev->pacer, &arg, cmd->flags); in cb_pcidas_ai_cmdtest() 768 comedi_8254_cascade_ns_to_timer(dev->pacer, &arg, cmd->flags); in cb_pcidas_ai_cmdtest() 823 comedi_8254_update_divisors(dev->pacer); in cb_pcidas_ai_cmd() 824 comedi_8254_pacer_enable(dev->pacer, 1, 2, true); in cb_pcidas_ai_cmd() 1292 dev->pacer = comedi_8254_init(dev->iobase + PCIDAS_AI_8254_BASE, in cb_pcidas_auto_attach() 1294 if (!dev->pacer) in cb_pcidas_auto_attach()
|
D | rtd520.c | 1294 dev->pacer = comedi_8254_mm_init(dev->mmio + LAS0_8254_TIMER_BASE, in rtd_auto_attach() 1296 if (!dev->pacer) in rtd_auto_attach() 1299 comedi_8254_subdevice_init(s, dev->pacer); in rtd_auto_attach() 1300 dev->pacer->insn_config = rtd_counter_insn_config; in rtd_auto_attach()
|
/Linux-v5.4/drivers/staging/comedi/ |
D | drivers.c | 181 kfree(dev->pacer); in comedi_device_detach_cleanup() 183 dev->pacer = NULL; in comedi_device_detach_cleanup()
|