Home
last modified time | relevance | path

Searched refs:ops (Results 1 – 25 of 233) sorted by relevance

12345678910

/components/drivers/spi/
A Ddev_spi_bit_ops.c22 #define TOG_SCLK(ops) ops->tog_sclk(ops->data) argument
23 #define SET_SCLK(ops, val) ops->set_sclk(ops->data, val) argument
24 #define SET_MOSI(ops, val) ops->set_mosi(ops->data, val) argument
25 #define SET_MISO(ops, val) ops->set_miso(ops->data, val) argument
26 #define GET_SCLK(ops) ops->get_sclk(ops->data) argument
27 #define GET_MOSI(ops) ops->get_mosi(ops->data) argument
28 #define GET_MISO(ops) ops->get_miso(ops->data) argument
29 #define DIR_MOSI(ops, val) ops->dir_mosi(ops->data, val) argument
30 #define DIR_MISO(ops, val) ops->dir_miso(ops->data, val) argument
39 ops->udelay(ops->delay_us); in spi_delay2()
[all …]
/components/drivers/i2c/
A Ddev_i2c_bit_ops.c21 #define SET_SDA(ops, val) ops->set_sda(ops->data, val) argument
22 #define SET_SCL(ops, val) ops->set_scl(ops->data, val) argument
23 #define GET_SDA(ops) ops->get_sda(ops->data) argument
24 #define GET_SCL(ops) ops->get_scl(ops->data) argument
28 ops->udelay((ops->delay_us + 1) >> 1); in i2c_delay()
33 ops->udelay(ops->delay_us); in i2c_delay2()
36 #define SDA_L(ops) SET_SDA(ops, 0) argument
37 #define SDA_H(ops) SET_SDA(ops, 1) argument
38 #define SCL_L(ops) SET_SCL(ops, 0) argument
76 if (ops->get_scl && !GET_SCL(ops)) in i2c_start()
[all …]
/components/drivers/pci/endpoint/
A Dendpoint.c27 if (ep->ops->write_header) in rt_pci_ep_write_header()
107 if (ep->ops->clear_bar) in rt_pci_ep_clear_bar()
133 if (ep->ops->map_addr) in rt_pci_ep_map_addr()
185 if (ep->ops->set_msix) in rt_pci_ep_set_msi()
219 if (ep->ops->get_msi) in rt_pci_ep_get_msi()
246 if (ep->ops->set_msix) in rt_pci_ep_set_msix()
321 if (ep && ep->ops) in rt_pci_ep_start()
323 if (ep->ops->start) in rt_pci_ep_start()
346 if (ep && ep->ops) in rt_pci_ep_stop()
348 if (ep->ops->stop) in rt_pci_ep_stop()
[all …]
/components/drivers/pin/
A Ddev_pin.c95 _hw_pin.ops = ops; in rt_device_pin_register()
107 RT_ASSERT(_hw_pin.ops != RT_NULL); in rt_pin_attach_irq()
108 if (_hw_pin.ops->pin_attach_irq) in rt_pin_attach_irq()
117 RT_ASSERT(_hw_pin.ops != RT_NULL); in rt_pin_detach_irq()
118 if (_hw_pin.ops->pin_detach_irq) in rt_pin_detach_irq()
127 RT_ASSERT(_hw_pin.ops != RT_NULL); in rt_pin_irq_enable()
128 if (_hw_pin.ops->pin_irq_enable) in rt_pin_irq_enable()
137 RT_ASSERT(_hw_pin.ops != RT_NULL); in rt_pin_debounce()
138 if (_hw_pin.ops->pin_debounce) in rt_pin_debounce()
148 RT_ASSERT(_hw_pin.ops != RT_NULL); in rt_pin_mode()
[all …]
A Ddev_pin_dm.c42 if (gpio && gpio->ops->pin_mode) in pin_api_mode()
52 if (gpio && gpio->ops->pin_write) in pin_api_write()
62 if (gpio && gpio->ops->pin_read) in pin_api_read()
79 if (!gpio->ops->pin_attach_irq) in pin_api_attach_irq()
114 if (!gpio->ops->pin_detach_irq) in pin_api_detach_irq()
137 if (gpio && gpio->ops->pin_irq_enable) in pin_api_irq_enable()
154 if (gpio->ops->pin_get && !(res = gpio->ops->pin_get(name))) in pin_api_get()
170 if (gpio && gpio->ops->pin_debounce) in pin_api_debounce()
183 if (gpio && gpio->ops->pin_irq_mode) in pin_api_irq_mode()
208 if (!gpio || !gpio->ops) in pin_api_init()
[all …]
/components/drivers/misc/
A Dadc.c32 result = adc->ops->convert(adc, pos, value); in _adc_read()
48 if (cmd == RT_ADC_CMD_ENABLE && adc->ops->enabled) in _adc_control()
68 rt_int16_t value = adc->ops->get_vref(adc); in _adc_control()
93 RT_ASSERT(ops != RT_NULL && ops->convert != RT_NULL); in rt_hw_adc_register()
101 device->parent.ops = &adc_ops; in rt_hw_adc_register()
110 device->ops = ops; in rt_hw_adc_register()
124 result = dev->ops->convert(dev, channel, &value); in rt_adc_read()
136 if (dev->ops->enabled != RT_NULL) in rt_adc_enable()
153 if (dev->ops->enabled != RT_NULL) in rt_adc_disable()
175 resolution = dev->ops->get_resolution(dev); in rt_adc_voltage()
[all …]
A Ddac.c29 result = dac->ops->convert(dac, pos + i, value); in _dac_write()
45 if (cmd == RT_DAC_CMD_ENABLE && dac->ops->enabled) in _dac_control()
47 result = dac->ops->enabled(dac, (rt_uint32_t)args); in _dac_control()
82 RT_ASSERT(ops != RT_NULL && ops->convert != RT_NULL); in rt_hw_dac_register()
89 device->parent.ops = &dac_ops; in rt_hw_dac_register()
98 device->ops = ops; in rt_hw_dac_register()
110 return dev->ops->convert(dev, channel, &value); in rt_dac_write()
118 if (dev->ops->enabled != RT_NULL) in rt_dac_enable()
120 result = dev->ops->enabled(dev, channel); in rt_dac_enable()
135 if (dev->ops->disabled != RT_NULL) in rt_dac_disable()
[all …]
A Dpulse_encoder.c18 if (pulse_encoder->ops->init) in rt_pulse_encoder_init()
20 return pulse_encoder->ops->init(pulse_encoder); in rt_pulse_encoder_init()
33 if (pulse_encoder->ops->control) in rt_pulse_encoder_open()
35 return pulse_encoder->ops->control(pulse_encoder, PULSE_ENCODER_CMD_ENABLE, RT_NULL); in rt_pulse_encoder_open()
48 if (pulse_encoder->ops->control) in rt_pulse_encoder_close()
63 if (pulse_encoder->ops->get_count) in rt_pulse_encoder_read()
65 *(rt_int32_t *)buffer = pulse_encoder->ops->get_count(pulse_encoder); in rt_pulse_encoder_read()
80 result = pulse_encoder->ops->clear_count(pulse_encoder); in rt_pulse_encoder_control()
87 result = pulse_encoder->ops->control(pulse_encoder, cmd, args); in rt_pulse_encoder_control()
114 RT_ASSERT(pulse_encoder->ops != RT_NULL); in rt_device_pulse_encoder_register()
[all …]
A Drt_inputcapture.c27 if (inputcapture->ops->init) in rt_inputcapture_init()
29 ret = inputcapture->ops->init(inputcapture); in rt_inputcapture_init()
48 if (inputcapture->ops->open) in rt_inputcapture_open()
50 ret = inputcapture->ops->open(inputcapture); in rt_inputcapture_open()
66 if (inputcapture->ops->close) in rt_inputcapture_close()
68 ret = inputcapture->ops->close(inputcapture); in rt_inputcapture_close()
145 RT_ASSERT(inputcapture->ops != RT_NULL); in rt_device_inputcapture_register()
146 RT_ASSERT(inputcapture->ops->get_pulsewidth != RT_NULL); in rt_device_inputcapture_register()
156 device->ops = &inputcapture_ops; in rt_device_inputcapture_register()
178 if (inputcapture->ops->get_pulsewidth(inputcapture, &data.pulsewidth_us) != RT_EOK) in rt_hw_inputcapture_isr()
/components/drivers/wlan/
A Ddev_wlan.c728 if (wlan->ops->wlan_init) in _rt_wlan_dev_init()
759 if (wlan->ops->wlan_mode) in _rt_wlan_dev_control()
768 if (wlan->ops->wlan_scan) in _rt_wlan_dev_control()
777 if (wlan->ops->wlan_join) in _rt_wlan_dev_control()
786 if (wlan->ops->wlan_softap) in _rt_wlan_dev_control()
800 if (wlan->ops->wlan_ap_stop) in _rt_wlan_dev_control()
823 if (wlan->ops->wlan_get_rssi) in _rt_wlan_dev_control()
931 if (wlan->ops->wlan_set_mac) in _rt_wlan_dev_control()
940 if (wlan->ops->wlan_get_mac) in _rt_wlan_dev_control()
1009 wlan->device.ops = &wlan_ops; in rt_wlan_dev_register()
[all …]
/components/dfs/dfs_v1/src/
A Ddfs_fs.c63 *empty = ops; in dfs_register()
243 ops < &filesystem_operation_table[DFS_FILESYSTEM_TYPES_MAX]; ops++) in dfs_mount()
244 if ((*ops != NULL) && (strncmp((*ops)->name, filesystemtype, strlen((*ops)->name)) == 0)) in dfs_mount()
257 if ((*ops == NULL) || ((*ops)->mount == NULL)) in dfs_mount()
295 if (iter->ops == NULL) in dfs_mount()
314 fs->ops = *ops; in dfs_mount()
396 fs->ops->unmount == NULL || in dfs_unmount()
397 fs->ops->unmount(fs) < 0) in dfs_unmount()
464 if (ops->mkfs == NULL) in dfs_mkfs()
587 fs->ops->unmount == NULL || in dfs_unmount_device()
[all …]
/components/drivers/include/drivers/
A Dusb_device.h136 const struct udcd_ops* ops; member
177 ufunction_ops_t ops; member
323 RT_ASSERT(dcd->ops != RT_NULL); in dcd_set_address()
332 RT_ASSERT(dcd->ops != RT_NULL); in dcd_set_config()
341 RT_ASSERT(dcd->ops != RT_NULL); in dcd_ep_enable()
344 return dcd->ops->ep_enable(ep); in dcd_ep_enable()
350 RT_ASSERT(dcd->ops != RT_NULL); in dcd_ep_disable()
360 RT_ASSERT(dcd->ops != RT_NULL); in dcd_ep_read_prepare()
375 RT_ASSERT(dcd->ops != RT_NULL); in dcd_ep_read()
391 RT_ASSERT(dcd->ops != RT_NULL); in dcd_ep_write()
[all …]
/components/drivers/pic/
A Dpic.c131 if (pic && pic->ops && pic->ops->name) in rt_pic_linear_irq()
645 if (pic->ops->irq_init) in rt_pic_irq_init()
667 if (pic->ops->irq_finit) in rt_pic_irq_finit()
690 if (pirq->pic->ops->irq_enable) in rt_pic_irq_enable()
722 if (pirq->pic->ops->irq_ack) in rt_pic_irq_ack()
738 if (pirq->pic->ops->irq_mask) in rt_pic_irq_mask()
754 if (pirq->pic->ops->irq_unmask) in rt_pic_irq_unmask()
770 if (pirq->pic->ops->irq_eoi) in rt_pic_irq_eoi()
1040 if (pirq->pic->ops->irq_ack) in rt_pic_irq_parent_ack()
1051 if (pirq->pic->ops->irq_mask) in rt_pic_irq_parent_mask()
[all …]
/components/drivers/hwtimer/
A Dhwtimer.c113 if (timer->ops->init) in rt_hwtimer_init()
115 timer->ops->init(timer, 1); in rt_hwtimer_init()
131 if (timer->ops->control != RT_NULL) in rt_hwtimer_open()
149 if (timer->ops->init != RT_NULL) in rt_hwtimer_close()
151 timer->ops->init(timer, 0); in rt_hwtimer_close()
178 cnt = timer->ops->count_get(timer); in rt_hwtimer_read()
208 if ((timer->ops->start == RT_NULL) || (timer->ops->stop == RT_NULL)) in rt_hwtimer_write()
214 timer->ops->stop(timer); in rt_hwtimer_write()
246 timer->ops->stop(timer); in rt_hwtimer_control()
395 RT_ASSERT(timer->ops != RT_NULL); in rt_device_hwtimer_register()
[all …]
/components/drivers/phye/
A Dphye.c22 if (phye && phye->dev && phye->ops) in rt_phye_register()
78 if (phye->init_count == 0 && phye->ops->init) in rt_phye_init()
80 if ((err = phye->ops->init(phye))) in rt_phye_init()
106 if (phye->init_count == 1 && phye->ops->exit) in rt_phye_exit()
108 if ((err = phye->ops->exit(phye))) in rt_phye_exit()
137 if (phye->ops->reset) in rt_phye_reset()
139 err = phye->ops->reset(phye); in rt_phye_reset()
162 if ((err = phye->ops->power_on(phye))) in rt_phye_power_on()
190 if ((err = phye->ops->power_off(phye))) in rt_phye_power_off()
222 if (phye->ops->set_mode) in rt_phye_set_mode()
[all …]
/components/drivers/hwcrypto/
A Dhwcrypto.c55 if (ctx && ctx->device->ops->reset) in rt_hwcrypto_ctx_reset()
57 ctx->device->ops->reset(ctx); in rt_hwcrypto_ctx_reset()
79 err = ctx->device->ops->create(ctx); in rt_hwcrypto_ctx_init()
134 if (ctx->device->ops->destroy) in rt_hwcrypto_ctx_destroy()
136 ctx->device->ops->destroy(ctx); in rt_hwcrypto_ctx_destroy()
165 return src->device->ops->copy(des, src); in rt_hwcrypto_ctx_cpy()
230 RT_ASSERT(device->ops != RT_NULL); in rt_hwcrypto_register()
231 RT_ASSERT(device->ops->create != RT_NULL); in rt_hwcrypto_register()
233 RT_ASSERT(device->ops->copy != RT_NULL); in rt_hwcrypto_register()
234 RT_ASSERT(device->ops->reset != RT_NULL); in rt_hwcrypto_register()
[all …]
A Dhw_bignum.c203 if (bignum_ctx->ops->add) in rt_hwcrypto_bignum_add()
205 return bignum_ctx->ops->add(bignum_ctx, x, a, b); in rt_hwcrypto_bignum_add()
230 if (bignum_ctx->ops->sub) in rt_hwcrypto_bignum_sub()
232 return bignum_ctx->ops->sub(bignum_ctx, x, a, b); in rt_hwcrypto_bignum_sub()
257 if (bignum_ctx->ops->mul) in rt_hwcrypto_bignum_mul()
259 return bignum_ctx->ops->mul(bignum_ctx, x, a, b); in rt_hwcrypto_bignum_mul()
285 if (bignum_ctx->ops->mulmod) in rt_hwcrypto_bignum_mulmod()
287 return bignum_ctx->ops->mulmod(bignum_ctx, x, a, b, c); in rt_hwcrypto_bignum_mulmod()
313 if (bignum_ctx->ops->exptmod) in rt_hwcrypto_bignum_exptmod()
315 return bignum_ctx->ops->exptmod(bignum_ctx, x, a, b, c); in rt_hwcrypto_bignum_exptmod()
/components/drivers/pci/
A Decam.c21 const struct pci_ecam_ops *ops) in pci_ecam_create() argument
31 conf_win->bus_shift = ops->bus_shift; in pci_ecam_create()
32 conf_win->ops = ops; in pci_ecam_create()
34 host_bridge->ops = (const struct rt_pci_ops *)&ops->pci_ops; in pci_ecam_create()
42 const struct pci_ecam_ops *eops = conf_win->ops; in pci_ecam_map()
/components/legacy/fdt/inc/
A Ddtb_fwnode.h21 const struct fwnode_operations *ops; member
87 ((fwnode) && (fwnode)->ops && (fwnode)->ops->op)
89 …(fwnode ? (fwnode_has_op(fwnode, op) ? (fwnode)->ops->op(fwnode, ##__VA_ARGS__) : -ENXIO) : -EINVA…
92 (fwnode_has_op(fwnode, op) ? (fwnode)->ops->op(fwnode, ##__VA_ARGS__) : false)
95 (fwnode_has_op(fwnode, op) ? (fwnode)->ops->op(fwnode, ##__VA_ARGS__) : NULL)
100 (fwnode)->ops->op(fwnode, ##__VA_ARGS__); \
106 const struct fwnode_operations *ops) in fwnode_init() argument
108 fwnode->ops = ops; in fwnode_init()
/components/dfs/dfs_v2/src/
A Ddfs_seq_file.c59 if (!ops) in dfs_seq_open()
78 seq->ops = ops; in dfs_seq_open()
116 p = seq->ops->start(seq, &seq->index); in dfs_seq_traverse()
119 error = seq->ops->show(seq, p); in dfs_seq_traverse()
142 seq->ops->stop(seq, p); in dfs_seq_traverse()
146 seq->ops->stop(seq, p); in dfs_seq_traverse()
241 err = seq->ops->show(seq, p); in dfs_seq_read()
254 seq->ops->stop(seq, p); in dfs_seq_read()
263 seq->ops->stop(seq, p); in dfs_seq_read()
285 err = seq->ops->show(seq, p); in dfs_seq_read()
[all …]
/components/drivers/led/
A Dled.c112 led->ops->set_state(led, RT_LED_S_OFF); in _led_blink_timerout()
116 led->ops->set_state(led, RT_LED_S_ON); in _led_blink_timerout()
129 if (!led || !led->ops) in rt_led_register()
145 if (!led->ops->set_period && led->ops->set_state) in rt_led_register()
167 led->parent.ops = &_led_ops; in rt_led_register()
231 if (!led->ops->set_state) in rt_led_set_state()
245 err = led->ops->set_state(led, state); in rt_led_set_state()
281 if (!led->ops->get_state) in rt_led_get_state()
288 err = led->ops->get_state(led, out_state); in rt_led_get_state()
311 if (led->ops->set_period) in rt_led_set_period()
[all …]
/components/drivers/block/
A Dblk.c122 if (disk->ops->sync) in blk_control()
128 err = disk->ops->sync(disk); in blk_control()
141 if (disk->ops->erase) in blk_control()
155 err = disk->ops->erase(disk); in blk_control()
169 if (disk->ops->autorefresh) in blk_control()
194 if (disk->ops->control) in blk_control()
237 if (!disk || !disk->ops) in rt_hw_blk_disk_register()
292 disk->parent.ops = &blk_ops; in rt_hw_blk_disk_register()
311 if (!disk->ops->write) in rt_hw_blk_disk_register()
358 if (disk->ops->sync) in rt_hw_blk_disk_unregister()
[all …]
/components/drivers/dma/
A Ddma_pool.c230 ops = &ofw_dma_map_ops; in ofw_device_dma_ops()
233 return ops; in ofw_device_dma_ops()
241 if (ops) in device_dma_ops()
243 return ops; in device_dma_ops()
249 return ops; in device_dma_ops()
262 dev->dma_ops = ops; in device_dma_ops()
264 return ops; in device_dma_ops()
422 ops = device_dma_ops(dev); in rt_dma_alloc()
424 if (ops->alloc) in rt_dma_alloc()
456 ops = device_dma_ops(dev); in rt_dma_free()
[all …]
/components/drivers/cputime/
A Dcputime.c106 int clock_cpu_setops(const struct rt_clock_cputime_ops *ops) in clock_cpu_setops() argument
108 _cputime_ops = ops; in clock_cpu_setops()
109 if (ops) in clock_cpu_setops()
111 RT_ASSERT(ops->cputime_getres != RT_NULL); in clock_cpu_setops()
112 RT_ASSERT(ops->cputime_gettime != RT_NULL); in clock_cpu_setops()
/components/drivers/regulator/
A Dregulator.c179 if (reg_np->ops->enable_time) in regulator_get_enable_time()
232 if (reg_np->ops->enable) in regulator_enable()
234 err = reg_np->ops->enable(reg_np); in regulator_enable()
283 if (reg_np->ops->disable) in regulator_disable()
285 err = reg_np->ops->disable(reg_np); in regulator_disable()
343 if (reg->reg_np->ops->is_enabled) in rt_regulator_is_enabled()
355 if (reg_np->ops->set_voltage) in regulator_set_voltage()
435 if (reg_np->ops->get_voltage) in rt_regulator_get_voltage()
463 if (reg_np->ops->set_mode) in rt_regulator_set_mode()
491 if (reg_np->ops->get_mode) in rt_regulator_get_mode()
[all …]

Completed in 50 milliseconds

12345678910