/Zephyr-latest/drivers/gnss/ |
D | gnss_emul.c | 41 struct gnss_data data; member 51 struct gnss_emul_data *data = dev->data; in gnss_emul_lock_sem() local 53 (void)k_sem_take(&data->lock, K_FOREVER); in gnss_emul_lock_sem() 58 struct gnss_emul_data *data = dev->data; in gnss_emul_unlock_sem() local 60 k_sem_give(&data->lock); in gnss_emul_unlock_sem() 65 struct gnss_emul_data *data = dev->data; in gnss_emul_update_fix_timestamp() local 69 data->fix_timestamp_ms = ((uptime_ms / data->fix_interval_ms) + 1) * data->fix_interval_ms; in gnss_emul_update_fix_timestamp() 72 data->resume_timestamp_ms = data->fix_timestamp_ms; in gnss_emul_update_fix_timestamp() 78 struct gnss_emul_data *data = dev->data; in gnss_emul_fix_is_acquired() local 81 time_since_resume = data->fix_timestamp_ms - data->resume_timestamp_ms; in gnss_emul_fix_is_acquired() [all …]
|
D | gnss_nmea0183_match.c | 32 static void gnss_nmea0183_match_reset_gsv(struct gnss_nmea0183_match_data *data) in gnss_nmea0183_match_reset_gsv() argument 34 data->satellites_length = 0; in gnss_nmea0183_match_reset_gsv() 35 data->gsv_message_number = 1; in gnss_nmea0183_match_reset_gsv() 39 static void gnss_nmea0183_match_publish(struct gnss_nmea0183_match_data *data) in gnss_nmea0183_match_publish() argument 41 if ((data->gga_utc == 0) || (data->rmc_utc == 0)) { in gnss_nmea0183_match_publish() 45 if (data->gga_utc == data->rmc_utc) { in gnss_nmea0183_match_publish() 46 gnss_publish_data(data->gnss, &data->data); in gnss_nmea0183_match_publish() 53 struct gnss_nmea0183_match_data *data = user_data; in gnss_nmea0183_match_gga_callback() local 55 if (gnss_nmea0183_parse_gga((const char **)argv, argc, &data->data) < 0) { in gnss_nmea0183_match_gga_callback() 59 if (gnss_nmea0183_match_parse_utc(argv, argc, &data->gga_utc) < 0) { in gnss_nmea0183_match_gga_callback() [all …]
|
D | gnss_quectel_lcx6g.c | 121 struct quectel_lcx6g_data *data = dev->data; in quectel_lcx6g_configure_pps() local 143 ret = gnss_nmea0183_snprintk(data->pair_request_buf, sizeof(data->pair_request_buf), in quectel_lcx6g_configure_pps() 149 ret = modem_chat_script_chat_set_request(&data->pair_script_chat, data->pair_request_buf); in quectel_lcx6g_configure_pps() 154 ret = gnss_nmea0183_snprintk(data->pair_match_buf, sizeof(data->pair_match_buf), in quectel_lcx6g_configure_pps() 160 ret = modem_chat_match_set_match(&data->pair_match, data->pair_match_buf); in quectel_lcx6g_configure_pps() 165 return modem_chat_run_script(&data->chat, &data->pair_script); in quectel_lcx6g_configure_pps() 170 struct quectel_lcx6g_data *data = dev->data; in quectel_lcx6g_lock() local 172 (void)k_sem_take(&data->lock, K_FOREVER); in quectel_lcx6g_lock() 177 struct quectel_lcx6g_data *data = dev->data; in quectel_lcx6g_unlock() local 179 k_sem_give(&data->lock); in quectel_lcx6g_unlock() [all …]
|
/Zephyr-latest/drivers/serial/ |
D | serial_test.c | 49 struct serial_vnd_data *data = dev->data; in is_irq_rx_pending() local 51 return !ring_buf_is_empty(data->read_queue); in is_irq_rx_pending() 56 struct serial_vnd_data *data = dev->data; in is_irq_tx_pending() local 58 return ring_buf_space_get(data->written) != 0; in is_irq_tx_pending() 63 struct serial_vnd_data *data = dev->data; in irq_process() local 68 bool rx_int = rx_rdy && data->irq_rx_enabled; in irq_process() 69 bool tx_int = tx_rdy && data->irq_tx_enabled; in irq_process() 79 if (!data->irq_isr) { in irq_process() 83 data->irq_isr(dev, NULL); in irq_process() 89 struct serial_vnd_data *data = dev->data; in irq_rx_enable() local [all …]
|
D | uart_xmc4xxx.c | 151 struct uart_xmc4xxx_data *data = dev->data; in uart_xmc4xxx_isr() local 154 if (data->user_cb) { in uart_xmc4xxx_isr() 155 data->user_cb(dev, data->user_data); in uart_xmc4xxx_isr() 163 if (data->dma_rx.buffer_len) { in uart_xmc4xxx_isr() 171 async_timer_start(&data->dma_rx.timeout_work, data->dma_rx.timeout); in uart_xmc4xxx_isr() 179 struct uart_xmc4xxx_data *data = dev->data; in uart_xmc4xxx_configure_service_requests() local 184 data->service_request_tx = (config->irq_num_tx - USIC_IRQ_MIN) % IRQS_PER_USIC; in uart_xmc4xxx_configure_service_requests() 189 data->service_request_tx); in uart_xmc4xxx_configure_service_requests() 193 data->service_request_tx); in uart_xmc4xxx_configure_service_requests() 198 data->service_request_rx = (config->irq_num_rx - USIC_IRQ_MIN) % IRQS_PER_USIC; in uart_xmc4xxx_configure_service_requests() [all …]
|
D | uart_emul.c | 32 /* Device run time data */ 112 struct uart_emul_data *data = dev->data; in uart_emul_tx_data_ready() local 115 if (data->tx_data_ready_cb) { in uart_emul_tx_data_ready() 116 (data->tx_data_ready_cb)(dev, ring_buf_size_get(data->tx_rb), data->user_data); in uart_emul_tx_data_ready() 118 SYS_SLIST_FOR_EACH_NODE(&data->emuls, node) { in uart_emul_tx_data_ready() 124 emul->api->tx_data_ready(dev, ring_buf_size_get(data->tx_rb), emul->target); in uart_emul_tx_data_ready() 130 struct uart_emul_data *drv_data = dev->data; in uart_emul_poll_in() 148 struct uart_emul_data *drv_data = dev->data; in uart_emul_poll_out() 171 struct uart_emul_data *drv_data = dev->data; in uart_emul_err_check() 181 struct uart_emul_data *drv_data = dev->data; in uart_emul_configure() [all …]
|
D | uart_esp32.c | 112 /* driver data */ 137 struct uart_esp32_data *data = dev->data; in uart_esp32_poll_in() local 140 if (uart_hal_get_rxfifo_len(&data->hal) == 0) { in uart_esp32_poll_in() 144 uart_hal_read_rxfifo(&data->hal, p_char, &inout_rd_len); in uart_esp32_poll_in() 151 struct uart_esp32_data *data = dev->data; in uart_esp32_poll_out() local 155 while (uart_hal_get_txfifo_len(&data->hal) == 0) { in uart_esp32_poll_out() 160 uart_hal_write_txfifo(&data->hal, &c, 1, &written); in uart_esp32_poll_out() 165 struct uart_esp32_data *data = dev->data; in uart_esp32_err_check() local 166 uint32_t mask = uart_hal_get_intsts_mask(&data->hal); in uart_esp32_err_check() 198 struct uart_esp32_data *data = dev->data; in uart_esp32_config_get() local [all …]
|
/Zephyr-latest/drivers/stepper/ |
D | gpio_stepper_controller.c | 49 struct gpio_stepper_data *data = dev->data; in stepper_motor_set_coil_charge() local 54 half_step_lookup_table[data->coil_charge][i]); in stepper_motor_set_coil_charge() 61 struct gpio_stepper_data *data = dev->data; in increment_coil_charge() local 63 if (data->coil_charge == NUM_CONTROL_PINS * MAX_MICRO_STEP_RES - data->step_gap) { in increment_coil_charge() 64 data->coil_charge = 0; in increment_coil_charge() 66 data->coil_charge = data->coil_charge + data->step_gap; in increment_coil_charge() 72 struct gpio_stepper_data *data = dev->data; in decrement_coil_charge() local 74 if (data->coil_charge == 0) { in decrement_coil_charge() 75 data->coil_charge = NUM_CONTROL_PINS * MAX_MICRO_STEP_RES - data->step_gap; in decrement_coil_charge() 77 data->coil_charge = data->coil_charge - data->step_gap; in decrement_coil_charge() [all …]
|
/Zephyr-latest/samples/drivers/soc_flash_nrf/ |
D | README.rst | 49 Data read: 1122 50 Data read matches data written. Good! 53 Data read: aabb 54 Data read matches data written. Good! 57 Data read: abcd 58 Data read matches data written. Good! 61 Data read: 1234 62 Data read matches data written. Good! 70 Data read: 1234 71 Data read matches data written. Good! [all …]
|
/Zephyr-latest/drivers/spi/ |
D | spi_b_renesas_ra8.c | 64 struct ra_spi_data *data = dev->data; in spi_cb() local 68 spi_context_cs_control(&data->ctx, false); in spi_cb() 69 spi_context_complete(&data->ctx, dev, 0); in spi_cb() 77 spi_context_cs_control(&data->ctx, false); in spi_cb() 78 spi_context_complete(&data->ctx, dev, -EIO); in spi_cb() 87 struct ra_spi_data *data = dev->data; in ra_spi_b_configure() local 90 if (spi_context_configured(&data->ctx, config)) { in ra_spi_b_configure() 95 if (data->spi.open != 0) { in ra_spi_b_configure() 96 R_SPI_B_Close(&data->spi); in ra_spi_b_configure() 104 data->fsp_config.operating_mode = SPI_MODE_SLAVE; in ra_spi_b_configure() [all …]
|
D | spi_renesas_ra.c | 60 struct ra_spi_data *data = dev->data; in spi_cb() local 64 spi_context_cs_control(&data->ctx, false); in spi_cb() 65 spi_context_complete(&data->ctx, dev, 0); in spi_cb() 73 spi_context_cs_control(&data->ctx, false); in spi_cb() 74 spi_context_complete(&data->ctx, dev, -EIO); in spi_cb() 83 struct ra_spi_data *data = dev->data; in ra_spi_configure() local 86 if (spi_context_configured(&data->ctx, config)) { in ra_spi_configure() 91 if (data->spi.open != 0) { in ra_spi_configure() 92 R_SPI_Close(&data->spi); in ra_spi_configure() 100 data->fsp_config.operating_mode = SPI_MODE_SLAVE; in ra_spi_configure() [all …]
|
D | spi_rpi_pico_pio.c | 140 static inline bool spi_pico_pio_transfer_ongoing(struct spi_pico_pio_data *data) in spi_pico_pio_transfer_ongoing() argument 142 return spi_context_tx_on(&data->spi_ctx) || spi_context_rx_on(&data->spi_ctx); in spi_pico_pio_transfer_ongoing() 145 static inline void spi_pico_pio_sm_put8(PIO pio, uint sm, uint8_t data) in spi_pico_pio_sm_put8() argument 147 /* Do 8 bit accesses on FIFO, so that write data is byte-replicated. This */ in spi_pico_pio_sm_put8() 151 *txfifo = data; in spi_pico_pio_sm_put8() 156 /* Do 8 bit accesses on FIFO, so that write data is byte-replicated. This */ in spi_pico_pio_sm_get8() 163 static inline void spi_pico_pio_sm_put16(PIO pio, uint sm, uint16_t data) in spi_pico_pio_sm_put16() argument 165 /* Do 16 bit accesses on FIFO, so that write data is halfword-replicated. This */ in spi_pico_pio_sm_put16() 169 *txfifo = data; in spi_pico_pio_sm_put16() 179 static inline void spi_pico_pio_sm_put32(PIO pio, uint sm, uint32_t data) in spi_pico_pio_sm_put32() argument [all …]
|
/Zephyr-latest/drivers/stepper/step_dir/ |
D | step_dir_stepper_common.c | 14 struct step_dir_stepper_common_data *data = dev->data; in step_dir_stepper_perform_step() local 17 switch (data->direction) { in step_dir_stepper_perform_step() 25 LOG_ERR("Unsupported direction: %d", data->direction); in step_dir_stepper_perform_step() 47 if (data->direction == STEPPER_DIRECTION_POSITIVE) { in step_dir_stepper_perform_step() 48 data->actual_position++; in step_dir_stepper_perform_step() 50 data->actual_position--; in step_dir_stepper_perform_step() 58 struct step_dir_stepper_common_data *data = dev->data; in stepper_trigger_callback() local 60 if (!data->callback) { in stepper_trigger_callback() 66 data->callback(dev, event, data->event_cb_user_data); in stepper_trigger_callback() 72 int ret = k_msgq_put(&data->event_msgq, &event, K_NO_WAIT); in stepper_trigger_callback() [all …]
|
/Zephyr-latest/tests/subsys/pm/device_runtime_api/src/ |
D | test_driver.c | 22 struct test_driver_data *data = dev->data; in test_driver_action() local 25 data->ongoing = true; in test_driver_action() 27 if (data->async) { in test_driver_action() 28 k_sem_take(&data->sync, K_FOREVER); in test_driver_action() 29 data->async = false; in test_driver_action() 32 data->ongoing = false; in test_driver_action() 35 data->count++; in test_driver_action() 42 struct test_driver_data *data = dev->data; in test_driver_pm_async() local 44 data->async = true; in test_driver_pm_async() 49 struct test_driver_data *data = dev->data; in test_driver_pm_done() local [all …]
|
/Zephyr-latest/tests/drivers/sensor/generic/src/ |
D | main.c | 22 struct sensor_value data; member 27 struct sensor_value data; member 109 struct sensor_value data; in ZTEST() local 119 &data), RETURN_SUCCESS, "fail to get channel"); in ZTEST() 120 zassert_equal(data.val1, chan_elements[0].data.val1, in ZTEST() 121 "the data does not match"); in ZTEST() 122 zassert_equal(data.val2, chan_elements[0].data.val2, in ZTEST() 123 "the data does not match"); in ZTEST() 131 &data), RETURN_SUCCESS, "fail to get channel"); in ZTEST() 132 zassert_equal(data.val1, chan_elements[i].data.val1, in ZTEST() [all …]
|
/Zephyr-latest/tests/bsim/bluetooth/host/adv/encrypted/css_sample_data/src/ |
D | central.c | 11 static bool data_parse_cb(struct bt_data *data, void *user_data) in data_parse_cb() argument 13 if (data->type == BT_DATA_ENCRYPTED_AD_DATA) { in data_parse_cb() 17 size_t decrypted_data_size = BT_EAD_DECRYPTED_PAYLOAD_SIZE(data->data_len); in data_parse_cb() 20 LOG_ERR("Size of decrypted data: %d", decrypted_data_size); in data_parse_cb() 21 LOG_ERR("Size of sample data: %d", sample_data->size_ad_data); in data_parse_cb() 22 FAIL("Computed size of data does not match the size of the data from the " in data_parse_cb() 23 "sample. (data set %d)\n", in data_parse_cb() 27 if (memcmp(sample_data->randomizer_little_endian, data->data, in data_parse_cb() 30 bt_hex(data->data, BT_EAD_RANDOMIZER_SIZE)); in data_parse_cb() 40 err = bt_ead_decrypt(sample_data->session_key, sample_data->iv, data->data, in data_parse_cb() [all …]
|
/Zephyr-latest/drivers/counter/ |
D | counter_esp32_tmr.c | 67 struct counter_esp32_data *data = dev->data; in counter_esp32_init() local 78 timer_hal_init(&data->hal_ctx, cfg->group, cfg->index); in counter_esp32_init() 79 data->alarm_cfg.callback = NULL; in counter_esp32_init() 80 timer_ll_enable_intr(data->hal_ctx.dev, TIMER_LL_EVENT_ALARM(data->hal_ctx.timer_id), in counter_esp32_init() 82 timer_ll_clear_intr_status(data->hal_ctx.dev, TIMER_LL_EVENT_ALARM(data->hal_ctx.timer_id)); in counter_esp32_init() 83 timer_ll_enable_auto_reload(data->hal_ctx.dev, data->hal_ctx.timer_id, in counter_esp32_init() 85 timer_ll_set_clock_source(data->hal_ctx.dev, data->hal_ctx.timer_id, in counter_esp32_init() 87 timer_ll_set_clock_prescale(data->hal_ctx.dev, data->hal_ctx.timer_id, cfg->config.divider); in counter_esp32_init() 88 timer_ll_set_count_direction(data->hal_ctx.dev, data->hal_ctx.timer_id, in counter_esp32_init() 90 timer_ll_enable_alarm(data->hal_ctx.dev, data->hal_ctx.timer_id, cfg->config.alarm_en); in counter_esp32_init() [all …]
|
/Zephyr-latest/drivers/i2c/target/ |
D | eeprom_target.c | 38 struct i2c_eeprom_target_data *data = dev->data; in eeprom_target_program() local 40 if (length > data->buffer_size) { in eeprom_target_program() 44 memcpy(data->buffer, eeprom_data, length); in eeprom_target_program() 52 struct i2c_eeprom_target_data *data = dev->data; in eeprom_target_read() local 54 if (!data || offset >= data->buffer_size) { in eeprom_target_read() 58 *eeprom_data = data->buffer[offset]; in eeprom_target_read() 67 struct i2c_eeprom_target_data *data = dev->data; in eeprom_target_set_addr() local 70 ret = i2c_target_unregister(cfg->bus.bus, &data->config); in eeprom_target_set_addr() 76 data->config.address = addr; in eeprom_target_set_addr() 78 return i2c_target_register(cfg->bus.bus, &data->config); in eeprom_target_set_addr() [all …]
|
/Zephyr-latest/tests/subsys/mgmt/ec_host_cmd/uart/src/ |
D | main.c | 37 struct uart_mock_data *data = uart_mock.data; in tx_done() local 41 evt.data.tx.buf = data->tx_buf; in tx_done() 42 evt.data.tx.len = data->tx_len; in tx_done() 44 data->cb(&uart_mock, &evt, data->user_data); in tx_done() 98 struct uart_mock_data *data = uart_mock.data; in test_hello() local 99 struct ec_host_cmd_request_header *cmd = (struct ec_host_cmd_request_header *)data->rx_buf; in test_hello() 109 evt.data.rx.len = CMD_HEADER_SIZE + sizeof(struct hello_cmd_data); in test_hello() 110 evt.data.rx.offset = 0; in test_hello() 111 evt.data.rx.buf = data->rx_buf; in test_hello() 121 /* Set expected data set from the EC */ in test_hello() [all …]
|
/Zephyr-latest/samples/subsys/zbus/runtime_obs_registration/ |
D | README.rst | 5 Use zbus' runtime observer registration to filter data generated by a producer. 11 …le of the communication, we have the filter responsible for filtering the data generated by the pr… 32 I: >-- Raw data fetched 33 I: -|- Filtering data 34 I: --> Consuming data: Acc x=0, y=0, z=0 35 I: >-- Raw data fetched 36 I: -|- Filtering data 37 I: --> Consuming data: Acc x=2, y=2, z=2 38 I: >-- Raw data fetched 39 I: -|- Filtering data [all …]
|
/Zephyr-latest/subsys/usb/usb_c/ |
D | usbc_stack.c | 26 struct usbc_port_data *port = dev->data; in usbc_handler() 66 struct usbc_port_data *port = dev->data; \ 102 struct usbc_port_data *data = dev->data; in DT_INST_FOREACH_STATUS_OKAY() local 105 data->request.val = PRIV_PORT_REQUEST_START; in DT_INST_FOREACH_STATUS_OKAY() 106 k_fifo_put(&data->request_fifo, &data->request); in DT_INST_FOREACH_STATUS_OKAY() 109 k_thread_resume(data->port_thread); in DT_INST_FOREACH_STATUS_OKAY() 119 struct usbc_port_data *data = dev->data; in usbc_suspend() local 122 data->request.val = PRIV_PORT_REQUEST_SUSPEND; in usbc_suspend() 123 k_fifo_put(&data->request_fifo, &data->request); in usbc_suspend() 134 struct usbc_port_data *data = dev->data; in usbc_request() local [all …]
|
/Zephyr-latest/drivers/virtualization/ |
D | virt_ivshmem.c | 40 struct ivshmem *data = dev->data; in ivshmem_configure_msi_x_interrupts() local 48 n_vectors = pcie_msi_vectors_allocate(data->pcie->bdf, in ivshmem_configure_msi_x_interrupts() 50 data->vectors, in ivshmem_configure_msi_x_interrupts() 61 data->params[i].dev = dev; in ivshmem_configure_msi_x_interrupts() 62 data->params[i].vector = i; in ivshmem_configure_msi_x_interrupts() 64 if (!pcie_msi_vector_connect(data->pcie->bdf, in ivshmem_configure_msi_x_interrupts() 65 &data->vectors[i], in ivshmem_configure_msi_x_interrupts() 67 &data->params[i], 0)) { in ivshmem_configure_msi_x_interrupts() 75 if (!pcie_msi_enable(data->pcie->bdf, data->vectors, n_vectors, 0)) { in ivshmem_configure_msi_x_interrupts() 80 data->n_vectors = n_vectors; in ivshmem_configure_msi_x_interrupts() [all …]
|
/Zephyr-latest/tests/subsys/rtio/rtio_api/src/ |
D | rtio_iodev_test.h | 33 static void rtio_iodev_test_next(struct rtio_iodev_test_data *data, bool completion) in rtio_iodev_test_next() argument 36 k_spinlock_key_t key = k_spin_lock(&data->lock); in rtio_iodev_test_next() 39 if (!completion && data->txn_head != NULL) { in rtio_iodev_test_next() 43 struct mpsc_node *next = mpsc_pop(&data->io_q); in rtio_iodev_test_next() 47 data->txn_head = NULL; in rtio_iodev_test_next() 48 data->txn_curr = NULL; in rtio_iodev_test_next() 54 data->txn_head = next_sqe; in rtio_iodev_test_next() 55 data->txn_curr = next_sqe; in rtio_iodev_test_next() 56 k_timer_start(&data->timer, K_MSEC(10), K_NO_WAIT); in rtio_iodev_test_next() 59 k_spin_unlock(&data->lock, key); in rtio_iodev_test_next() [all …]
|
/Zephyr-latest/boards/nxp/s32z2xxdc2/support/ |
D | startup.cmm | 105 Data.Set EAXI:0x41850014 %LE %Long 0x0 106 Data.Set EAXI:0x41850018 %LE %Long 0x0 107 Data.Set EAXI:0x4185001C %LE %Long 0x0 110 Data.Set DP:0x1C100c0 %LE %Long 0x3cf3cf00 111 Data.Set DP:0x1C100c8 %LE %Long 0x3cf3cf00 121 Data.Set EZAXI:&cfgCoreAddr %Long 0yXXXXxxxxXXXXxxxxXXXXxxxxXXXXxxx&(spltLckBit) ; CFG_CORE 124 Data.Set EAXI:&rtuStartAddr %Long 0xFFFEF7FF 147 Data.LOAD.Elf &elfFile EAXI: 181 Data.Set EAXI:0x41900300 %LE %Long 0x5 182 Data.Set EAXI:0x41900304 %LE %Long 0x1 [all …]
|
/Zephyr-latest/drivers/modem/ |
D | modem_cmd_handler.c | 37 static void skipcrlf(struct modem_cmd_handler_data *data) in skipcrlf() argument 39 while (data->rx_buf && data->rx_buf->len && in skipcrlf() 40 is_crlf(*data->rx_buf->data)) { in skipcrlf() 41 net_buf_pull_u8(data->rx_buf); in skipcrlf() 42 if (!data->rx_buf->len) { in skipcrlf() 43 data->rx_buf = net_buf_frag_del(NULL, data->rx_buf); in skipcrlf() 48 static uint16_t findcrlf(struct modem_cmd_handler_data *data, in findcrlf() argument 51 struct net_buf *buf = data->rx_buf; in findcrlf() 54 while (buf && buf->len && !is_crlf(*(buf->data + pos))) { in findcrlf() 64 if (buf && buf->len && is_crlf(*(buf->data + pos))) { in findcrlf() [all …]
|