Home
last modified time | relevance | path

Searched refs:ch (Results 1 – 25 of 134) sorted by relevance

123456

/Zephyr-Core-3.7.0/drivers/dma/
Ddma_gd32.c46 #define DMA_CHCTL(dma, ch) REG32((dma + 0x08UL) + 0x14UL * (uint32_t)(ch)) argument
47 #define DMA_CHCNT(dma, ch) REG32((dma + 0x0CUL) + 0x14UL * (uint32_t)(ch)) argument
48 #define DMA_CHPADDR(dma, ch) REG32((dma + 0x10UL) + 0x14UL * (uint32_t)(ch)) argument
49 #define DMA_CHMADDR(dma, ch) REG32((dma + 0x14UL) + 0x14UL * (uint32_t)(ch)) argument
54 #define GD32_DMA_CHCTL(dma, ch) DMA_CHCTL((dma), (ch)) argument
55 #define GD32_DMA_CHCNT(dma, ch) DMA_CHCNT((dma), (ch)) argument
56 #define GD32_DMA_CHPADDR(dma, ch) DMA_CHPADDR((dma), (ch)) argument
57 #define GD32_DMA_CHMADDR(dma, ch) DMA_CHMADDR((dma), (ch)) argument
95 gd32_dma_periph_increase_enable(uint32_t reg, dma_channel_enum ch) in gd32_dma_periph_increase_enable() argument
97 GD32_DMA_CHCTL(reg, ch) |= DMA_CHXCTL_PNAGA; in gd32_dma_periph_increase_enable()
[all …]
Ddma_rpi_pico.c58 ((dma_hw_t *)cfg->reg)->ch[channel].al1_ctrl &= ~DMA_INT_ERROR_FLAGS; in rpi_pico_dma_channel_clear_error_flags()
66 return ((dma_hw_t *)cfg->reg)->ch[channel].al1_ctrl & DMA_INT_ERROR_FLAGS; in rpi_pico_dma_channel_get_error_flags()
201 static int dma_rpi_pico_reload(const struct device *dev, uint32_t ch, uint32_t src, uint32_t dst, in dma_rpi_pico_reload() argument
207 if (ch >= cfg->channels) { in dma_rpi_pico_reload()
208 LOG_ERR("reload channel must be < %" PRIu32 " (%" PRIu32 ")", cfg->channels, ch); in dma_rpi_pico_reload()
212 if (dma_channel_is_busy(ch)) { in dma_rpi_pico_reload()
216 data->channels[ch].source_address = (void *)src; in dma_rpi_pico_reload()
217 data->channels[ch].dest_address = (void *)dst; in dma_rpi_pico_reload()
218 data->channels[ch].block_size = size; in dma_rpi_pico_reload()
219 dma_channel_configure(ch, &data->channels[ch].config, data->channels[ch].dest_address, in dma_rpi_pico_reload()
[all …]
Ddma_andes_atcdmac300.c27 #define DMA_CH_OFFSET(ch) (ch * 0x20) argument
28 #define DMA_CH_CTRL(dev, ch) \ argument
29 (((struct dma_atcdmac300_cfg *)dev->config)->base + 0x40 + DMA_CH_OFFSET(ch))
30 #define DMA_CH_TRANSIZE(dev, ch) \ argument
31 (((struct dma_atcdmac300_cfg *)dev->config)->base + 0x44 + DMA_CH_OFFSET(ch))
32 #define DMA_CH_SRC_ADDR_L(dev, ch) \ argument
33 (((struct dma_atcdmac300_cfg *)dev->config)->base + 0x48 + DMA_CH_OFFSET(ch))
34 #define DMA_CH_SRC_ADDR_H(dev, ch) \ argument
35 (((struct dma_atcdmac300_cfg *)dev->config)->base + 0x4C + DMA_CH_OFFSET(ch))
36 #define DMA_CH_DST_ADDR_L(dev, ch) \ argument
[all …]
/Zephyr-Core-3.7.0/subsys/settings/src/
Dsettings.c43 STRUCT_SECTION_FOREACH(settings_handler_static, ch) { in settings_register()
44 if (strcmp(handler->name, ch->name) == 0) { in settings_register()
51 struct settings_handler *ch; in settings_register() local
52 SYS_SLIST_FOR_EACH_CONTAINER(&settings_handlers, ch, node) { in settings_register()
53 if (strcmp(handler->name, ch->name) == 0) { in settings_register()
148 STRUCT_SECTION_FOREACH(settings_handler_static, ch) { in settings_parse_and_lookup()
149 if (!settings_name_steq(name, ch->name, &tmpnext)) { in settings_parse_and_lookup()
153 bestmatch = ch; in settings_parse_and_lookup()
159 if (settings_name_steq(ch->name, bestmatch->name, NULL)) { in settings_parse_and_lookup()
160 bestmatch = ch; in settings_parse_and_lookup()
[all …]
Dsettings_runtime.c28 struct settings_handler_static *ch; in settings_runtime_set() local
32 ch = settings_parse_and_lookup(name, &name_key); in settings_runtime_set()
33 if (!ch) { in settings_runtime_set()
39 return ch->h_set(name_key, len, settings_runtime_read_cb, (void *)&arg); in settings_runtime_set()
44 struct settings_handler_static *ch; in settings_runtime_get() local
47 ch = settings_parse_and_lookup(name, &name_key); in settings_runtime_get()
48 if (!ch) { in settings_runtime_get()
52 if (!ch->h_get) { in settings_runtime_get()
56 return ch->h_get(name_key, data, len); in settings_runtime_get()
61 struct settings_handler_static *ch; in settings_runtime_commit() local
[all …]
Dsettings_store.c139 STRUCT_SECTION_FOREACH(settings_handler_static, ch) { in settings_save_subtree()
140 if (subtree && !settings_name_steq(ch->name, subtree, NULL)) { in settings_save_subtree()
143 if (ch->h_export) { in settings_save_subtree()
144 rc2 = ch->h_export(settings_save_one); in settings_save_subtree()
152 struct settings_handler *ch; in settings_save_subtree() local
153 SYS_SLIST_FOR_EACH_CONTAINER(&settings_handlers, ch, node) { in settings_save_subtree()
154 if (subtree && !settings_name_steq(ch->name, subtree, NULL)) { in settings_save_subtree()
157 if (ch->h_export) { in settings_save_subtree()
158 rc2 = ch->h_export(settings_save_one); in settings_save_subtree()
/Zephyr-Core-3.7.0/subsys/net/lib/http/
Dhttp_parser_url.c147 enum state parse_url_char(enum state s, const char ch) in parse_url_char() argument
149 if (ch == ' ' || ch == '\r' || ch == '\n') { in parse_url_char()
154 if (ch == '\t' || ch == '\f') { in parse_url_char()
166 if (ch == '/' || ch == '*') { in parse_url_char()
170 if (IS_ALPHA(ch)) { in parse_url_char()
177 if (IS_ALPHA(ch)) { in parse_url_char()
181 if (ch == ':') { in parse_url_char()
188 if (ch == '/') { in parse_url_char()
195 if (ch == '/') { in parse_url_char()
202 if (ch == '@') { in parse_url_char()
[all …]
Dhttp_parser.c295 #define IS_HEADER_CHAR(ch) \ argument
296 (ch == CR || ch == LF || ch == 9 || \
297 ((unsigned char)ch > 31 && ch != 127))
370 int parser_header_state(struct http_parser *parser, char ch, char c) in parser_header_state() argument
467 if (ch != ' ') { in parser_header_state()
482 enum header_states *header_state, char ch, char c) in header_states() argument
522 if (ch == ' ') { in header_states()
526 if (UNLIKELY(!IS_NUM(ch))) { in header_states()
534 t += ch - '0'; in header_states()
612 if (ch == ',') { in header_states()
[all …]
/Zephyr-Core-3.7.0/soc/nordic/nrf53/
Dsync_rtc.c34 } ch; member
76 nrf_ipc_event_t ipc_evt = nrf_ipc_receive_event_get(channels.ch.ipc_in); in ppi_ipc_to_rtc()
77 uint32_t task_addr = z_nrf_rtc_timer_capture_task_address_get(channels.ch.rtc); in ppi_ipc_to_rtc()
80 nrfx_gppi_task_endpoint_setup(channels.ch.ppi, task_addr); in ppi_ipc_to_rtc()
81 nrf_ipc_publish_set(NRF_IPC, ipc_evt, channels.ch.ppi); in ppi_ipc_to_rtc()
83 nrfx_gppi_task_endpoint_clear(channels.ch.ppi, task_addr); in ppi_ipc_to_rtc()
95 uint32_t evt_addr = z_nrf_rtc_timer_compare_evt_address_get(channels.ch.rtc); in ppi_rtc_to_ipc()
96 nrf_ipc_task_t ipc_task = nrf_ipc_send_task_get(channels.ch.ipc_out); in ppi_rtc_to_ipc()
99 nrf_ipc_subscribe_set(NRF_IPC, ipc_task, channels.ch.ppi); in ppi_rtc_to_ipc()
100 nrfx_gppi_event_endpoint_setup(channels.ch.ppi, evt_addr); in ppi_rtc_to_ipc()
[all …]
/Zephyr-Core-3.7.0/drivers/mbox/
Dmbox_andes_plic_sw.c64 static inline bool is_channel_valid(const struct device *dev, uint32_t ch) in is_channel_valid() argument
68 return (ch <= conf->channel_max); in is_channel_valid()
71 static int mbox_andes_send(const struct device *dev, uint32_t ch, in mbox_andes_send() argument
78 if (!is_channel_valid(dev, ch)) { in mbox_andes_send()
83 plic_sw_irq_set_pending(dev, ch + 1); in mbox_andes_send()
88 static int mbox_andes_register_callback(const struct device *dev, uint32_t ch, in mbox_andes_register_callback() argument
97 if (ch > conf->channel_max) { in mbox_andes_register_callback()
103 if (ch & data->ipi_channel & data->reg_cb_channel) { in mbox_andes_register_callback()
108 data->reg_cb_channel |= BIT(ch); in mbox_andes_register_callback()
110 data->cb[ch] = cb; in mbox_andes_register_callback()
[all …]
Dmbox_nrfx_ipc.c34 static inline bool is_rx_channel_valid(const struct device *dev, uint32_t ch) in is_rx_channel_valid() argument
38 return ((ch < IPC_CONF_NUM) && (conf->rx_mask & BIT(ch))); in is_rx_channel_valid()
41 static inline bool is_tx_channel_valid(const struct device *dev, uint32_t ch) in is_tx_channel_valid() argument
45 return ((ch < IPC_CONF_NUM) && (conf->tx_mask & BIT(ch))); in is_tx_channel_valid()
164 for (size_t ch = 0; ch < IPC_CONF_NUM; ch++) { in enable_dt_channels() local
165 if (conf->tx_mask & BIT(ch)) { in enable_dt_channels()
166 ch_config.send_task_config[ch] = BIT(ch); in enable_dt_channels()
169 if (conf->rx_mask & BIT(ch)) { in enable_dt_channels()
170 ch_config.receive_event_config[ch] = BIT(ch); in enable_dt_channels()
/Zephyr-Core-3.7.0/tests/drivers/build_all/sensor/src/
Dgeneric_test.c106 for (enum sensor_channel ch = 0; ch < ARRAY_SIZE(channel_table); ch++) { in run_generic_test() local
107 if (SENSOR_CHANNEL_3_AXIS(ch)) { in run_generic_test()
113 struct sensor_chan_spec ch_spec = {.chan_type = ch, .chan_idx = 0}; in run_generic_test()
116 &channel_table[ch].epsilon, &shift) == 0) { in run_generic_test()
118 channel_table[ch].supported = true; in run_generic_test()
120 LOG_INF("CH %d: lower=%d, upper=%d, eps=%d, shift=%d", ch, lower, upper, in run_generic_test()
121 channel_table[ch].epsilon, shift); in run_generic_test()
124 iodev_all_channels[iodev_read_config.count++].chan_type = ch; in run_generic_test()
130 channel_table[ch].expected_value_shift = shift; in run_generic_test()
132 channel_table[ch].expected_values[i] = in run_generic_test()
[all …]
/Zephyr-Core-3.7.0/drivers/ipm/
Dipm_stm32_ipcc.c38 #define IPCC_EnableReceiveChannel(hipcc, ch) \ argument
39 LL_C1_IPCC_EnableReceiveChannel(hipcc, 1 << ch)
40 #define IPCC_EnableTransmitChannel(hipcc, ch) \ argument
41 LL_C1_IPCC_EnableTransmitChannel(hipcc, 1 << ch)
42 #define IPCC_DisableReceiveChannel(hipcc, ch) \ argument
43 LL_C2_IPCC_DisableReceiveChannel(hipcc, 1 << ch)
44 #define IPCC_DisableTransmitChannel(hipcc, ch) \ argument
45 LL_C1_IPCC_DisableTransmitChannel(hipcc, 1 << ch)
47 #define IPCC_ClearFlag_CHx(hipcc, ch) LL_C1_IPCC_ClearFlag_CHx(hipcc, 1 << ch) argument
48 #define IPCC_SetFlag_CHx(hipcc, ch) LL_C1_IPCC_SetFlag_CHx(hipcc, 1 << ch) argument
[all …]
/Zephyr-Core-3.7.0/include/zephyr/drivers/
Demul_sensor.h30 int (*set_channel)(const struct emul *target, struct sensor_chan_spec ch,
33 int (*get_sample_range)(const struct emul *target, struct sensor_chan_spec ch, q31_t *lower,
36 int (*set_attribute)(const struct emul *target, struct sensor_chan_spec ch,
39 int (*get_attribute_metadata)(const struct emul *target, struct sensor_chan_spec ch,
72 struct sensor_chan_spec ch, const q31_t *value, in emul_sensor_backend_set_channel() argument
82 return api->set_channel(target, ch, value, shift); in emul_sensor_backend_set_channel()
105 struct sensor_chan_spec ch, q31_t *lower, in emul_sensor_backend_get_sample_range() argument
115 return api->get_sample_range(target, ch, lower, upper, epsilon, shift); in emul_sensor_backend_get_sample_range()
131 struct sensor_chan_spec ch, in emul_sensor_backend_set_attribute() argument
144 return api->set_attribute(target, ch, attribute, value); in emul_sensor_backend_set_attribute()
[all …]
/Zephyr-Core-3.7.0/dts/arm/infineon/cat1a/legacy/
Dpsoc6_cm0.dtsi30 compatible = "cypress,psoc6-intmux-ch";
38 compatible = "cypress,psoc6-intmux-ch";
46 compatible = "cypress,psoc6-intmux-ch";
54 compatible = "cypress,psoc6-intmux-ch";
62 compatible = "cypress,psoc6-intmux-ch";
70 compatible = "cypress,psoc6-intmux-ch";
78 compatible = "cypress,psoc6-intmux-ch";
86 compatible = "cypress,psoc6-intmux-ch";
94 compatible = "cypress,psoc6-intmux-ch";
102 compatible = "cypress,psoc6-intmux-ch";
[all …]
/Zephyr-Core-3.7.0/subsys/debug/gdbstub/
Dgdbstub_backend_serial.c43 void z_gdb_putchar(unsigned char ch) in z_gdb_putchar() argument
45 uart_poll_out(uart_dev, ch); in z_gdb_putchar()
50 unsigned char ch; in z_gdb_getchar() local
52 while (uart_poll_in(uart_dev, &ch) < 0) { in z_gdb_getchar()
55 return ch; in z_gdb_getchar()
/Zephyr-Core-3.7.0/drivers/adc/
Dadc_cc32xx.c67 static inline void start_sampling(unsigned long base, int ch) in start_sampling() argument
69 MAP_ADCChannelEnable(base, ch); in start_sampling()
71 while (!MAP_ADCFIFOLvlGet(base, ch)) { in start_sampling()
73 MAP_ADCFIFORead(base, ch); in start_sampling()
75 MAP_ADCIntClear(base, ch, ISR_MASK); in start_sampling()
76 MAP_ADCIntEnable(base, ch, ISR_MASK); in start_sampling()
118 const int ch = s_channel[i]; in adc_cc32xx_init() local
120 MAP_ADCIntDisable(config->base, ch, ISR_MASK); in adc_cc32xx_init()
121 MAP_ADCChannelDisable(config->base, ch); in adc_cc32xx_init()
122 MAP_ADCDMADisable(config->base, ch); in adc_cc32xx_init()
[all …]
Dadc_ite_it8xxx2.c38 #define ADC_CHANNEL_OFFSET(ch) ((ch)-CHIP_ADC_CH13-ADC_CHANNEL_SHIFT) argument
73 uint32_t ch; member
131 static void adc_disable_measurement(uint32_t ch) in adc_disable_measurement() argument
135 if (ch <= CHIP_ADC_CH7) { in adc_disable_measurement()
148 adc_regs->adc_vchs_ctrl[ADC_CHANNEL_OFFSET(ch)].VCHCTL = in adc_disable_measurement()
164 return (data->ch <= CHIP_ADC_CH7) ? in adc_data_valid()
166 (adc_regs->ADCDVSTS2 & BIT(ADC_CHANNEL_OFFSET(data->ch))); in adc_data_valid()
176 if (data->ch <= CHIP_ADC_CH7) { in adc_it8xxx2_get_sample()
183 adc_regs->adc_vchs_ctrl[ADC_CHANNEL_OFFSET(data->ch)].VCHDATM << 8 | in adc_it8xxx2_get_sample()
184 adc_regs->adc_vchs_ctrl[ADC_CHANNEL_OFFSET(data->ch)].VCHDATL; in adc_it8xxx2_get_sample()
[all …]
/Zephyr-Core-3.7.0/tests/bsim/bluetooth/host/att/long_read/
Dbs_sync.c55 void bs_bc_receive_msg_sync(uint ch, size_t size, uint8_t *data) in bs_bc_receive_msg_sync() argument
57 while (bs_bc_is_msg_received(ch) < size) { in bs_bc_receive_msg_sync()
60 bs_bc_receive_msg(ch, data, size); in bs_bc_receive_msg_sync()
63 void bs_bc_send_uint(uint ch, uint64_t data) in bs_bc_send_uint() argument
68 bs_bc_send_msg(ch, data_bytes, sizeof(data_bytes)); in bs_bc_send_uint()
71 uint64_t bs_bc_recv_uint(uint ch) in bs_bc_recv_uint() argument
75 bs_bc_receive_msg_sync(ch, sizeof(data), data); in bs_bc_recv_uint()
/Zephyr-Core-3.7.0/tests/bsim/bluetooth/host/att/open_close/src/
Dbs_sync.c55 void bs_bc_receive_msg_sync(uint ch, size_t size, uint8_t *data) in bs_bc_receive_msg_sync() argument
57 while (bs_bc_is_msg_received(ch) < size) { in bs_bc_receive_msg_sync()
60 bs_bc_receive_msg(ch, data, size); in bs_bc_receive_msg_sync()
63 void bs_bc_send_uint(uint ch, uint64_t data) in bs_bc_send_uint() argument
68 bs_bc_send_msg(ch, data_bytes, sizeof(data_bytes)); in bs_bc_send_uint()
71 uint64_t bs_bc_recv_uint(uint ch) in bs_bc_recv_uint() argument
75 bs_bc_receive_msg_sync(ch, sizeof(data), data); in bs_bc_recv_uint()
/Zephyr-Core-3.7.0/modules/lvgl/
Dlvgl_display_24bit.c39 mix_color.ch.red = *buf_xy; in lvgl_set_px_cb_24bit()
40 mix_color.ch.green = *(buf_xy + 1); in lvgl_set_px_cb_24bit()
41 mix_color.ch.blue = *(buf_xy + 2); in lvgl_set_px_cb_24bit()
47 *buf_xy = converted_color.ch.red; in lvgl_set_px_cb_24bit()
48 *(buf_xy + 1) = converted_color.ch.green; in lvgl_set_px_cb_24bit()
49 *(buf_xy + 2) = converted_color.ch.blue; in lvgl_set_px_cb_24bit()
/Zephyr-Core-3.7.0/drivers/sensor/ti/fdc2x1x/
Dfdc2x1x.c31 uint8_t ch, double *freq) in fdc2x1x_raw_to_freq() argument
38 data->channel_buf[ch]) / pow(2, 28); in fdc2x1x_raw_to_freq()
41 ((data->channel_buf[ch] / pow(2, 12 + cfg->output_gain)) + in fdc2x1x_raw_to_freq()
42 (cfg->ch_cfg[ch].offset / pow(2, 16))); in fdc2x1x_raw_to_freq()
55 uint8_t ch, double freq, double *capacitance) in fdc2x1x_raw_to_capacitance() argument
315 static int fdc2x1x_set_active_channel(const struct device *dev, uint8_t ch) in fdc2x1x_set_active_channel() argument
320 FDC2X1X_CFG_ACTIVE_CHAN_SET(ch)); in fdc2x1x_set_active_channel()
733 int ch; in fdc2x1x_init_config() local
738 for (ch = 0; ch < cfg->num_channels; ch++) { in fdc2x1x_init_config()
739 ret = fdc2x1x_set_fin_sel(dev, ch, cfg->ch_cfg[ch].fin_sel); in fdc2x1x_init_config()
[all …]
/Zephyr-Core-3.7.0/drivers/sensor/bosch/bmi160/
Demul_bmi160.c282 static int bmi160_emul_backend_set_channel(const struct emul *target, struct sensor_chan_spec ch, in bmi160_emul_backend_set_channel() argument
291 switch (ch.chan_type) { in bmi160_emul_backend_set_channel()
295 reg_lsb = BMI160_REG_DATA_ACC_X + (ch.chan_type - SENSOR_CHAN_ACCEL_X) * 2; in bmi160_emul_backend_set_channel()
316 reg_lsb = BMI160_REG_DATA_GYR_X + (ch.chan_type - SENSOR_CHAN_GYRO_X) * 2; in bmi160_emul_backend_set_channel()
356 if (ch.chan_type == SENSOR_CHAN_DIE_TEMP) { in bmi160_emul_backend_set_channel()
370 struct sensor_chan_spec ch, q31_t *lower, in bmi160_emul_backend_get_sample_range() argument
375 switch (ch.chan_type) { in bmi160_emul_backend_get_sample_range()
443 static int bmi160_emul_backend_set_offset(const struct emul *target, struct sensor_chan_spec ch, in bmi160_emul_backend_set_offset() argument
446 if (ch.chan_type != SENSOR_CHAN_ACCEL_XYZ && ch.chan_type != SENSOR_CHAN_GYRO_XYZ) { in bmi160_emul_backend_set_offset()
455 if (ch.chan_type == SENSOR_CHAN_ACCEL_XYZ) { in bmi160_emul_backend_set_offset()
[all …]
/Zephyr-Core-3.7.0/subsys/bluetooth/shell/
Dl2cap.c53 struct bt_l2cap_le_chan ch; member
55 #define L2CH_CHAN(_chan) CONTAINER_OF(_chan, struct l2ch, ch.chan)
58 #define L2CAP_CHAN(_chan) _chan->ch.chan
93 bt_l2cap_chan_recv_complete(&c->ch.chan, buf); in l2cap_recv_cb()
172 .ch.chan.ops = &l2cap_ops,
173 .ch.rx.mtu = DATA_MTU,
227 if (l2ch_chan.ch.chan.conn) { in l2cap_accept()
232 *chan = &l2ch_chan.ch.chan; in l2cap_accept()
283 struct bt_l2cap_chan *l2cap_ecred_chans[] = { &l2ch_chan.ch.chan, NULL }; in cmd_ecred_reconfigure()
292 if (!l2ch_chan.ch.chan.conn) { in cmd_ecred_reconfigure()
[all …]
/Zephyr-Core-3.7.0/drivers/spi/
Dspi_nrfx_common.c13 uint8_t ch; in spi_nrfx_wake_init() local
16 .p_in_channel = &ch, in spi_nrfx_wake_init()
25 res = nrfx_gpiote_channel_alloc(gpiote, &ch); in spi_nrfx_wake_init()
32 nrfx_gpiote_channel_free(gpiote, ch); in spi_nrfx_wake_init()

123456