Lines Matching full:channels
31 uint32_t channels; member
50 struct dma_rpi_pico_channel *channels; member
119 if (channel >= cfg->channels) { in dma_rpi_pico_config()
120 LOG_ERR("channel must be < %" PRIu32 " (%" PRIu32 ")", cfg->channels, channel); in dma_rpi_pico_config()
179 data->channels[channel].config = dma_channel_get_default_config(channel); in dma_rpi_pico_config()
181 data->channels[channel].source_address = (void *)dma_cfg->head_block->source_address; in dma_rpi_pico_config()
182 data->channels[channel].dest_address = (void *)dma_cfg->head_block->dest_address; in dma_rpi_pico_config()
183 data->channels[channel].block_size = dma_cfg->head_block->block_size; in dma_rpi_pico_config()
184 channel_config_set_read_increment(&data->channels[channel].config, in dma_rpi_pico_config()
187 channel_config_set_write_increment(&data->channels[channel].config, in dma_rpi_pico_config()
191 &data->channels[channel].config, in dma_rpi_pico_config()
193 channel_config_set_dreq(&data->channels[channel].config, in dma_rpi_pico_config()
195 channel_config_set_high_priority(&data->channels[channel].config, in dma_rpi_pico_config()
198 data->channels[channel].callback = dma_cfg->dma_callback; in dma_rpi_pico_config()
199 data->channels[channel].user_data = dma_cfg->user_data; in dma_rpi_pico_config()
200 data->channels[channel].direction = dma_cfg->channel_direction; in dma_rpi_pico_config()
211 if (ch >= cfg->channels) { in dma_rpi_pico_reload()
212 LOG_ERR("reload channel must be < %" PRIu32 " (%" PRIu32 ")", cfg->channels, ch); in dma_rpi_pico_reload()
220 data->channels[ch].source_address = (void *)src; in dma_rpi_pico_reload()
221 data->channels[ch].dest_address = (void *)dst; in dma_rpi_pico_reload()
222 data->channels[ch].block_size = size; in dma_rpi_pico_reload()
223 dma_channel_configure(ch, &data->channels[ch].config, data->channels[ch].dest_address, in dma_rpi_pico_reload()
224 data->channels[ch].source_address, data->channels[ch].block_size, in dma_rpi_pico_reload()
235 if (ch >= cfg->channels) { in dma_rpi_pico_start()
236 LOG_ERR("start channel must be < %" PRIu32 " (%" PRIu32 ")", cfg->channels, ch); in dma_rpi_pico_start()
243 dma_channel_configure(ch, &data->channels[ch].config, data->channels[ch].dest_address, in dma_rpi_pico_start()
244 data->channels[ch].source_address, data->channels[ch].block_size, in dma_rpi_pico_start()
254 if (ch >= cfg->channels) { in dma_rpi_pico_stop()
255 LOG_ERR("stop channel must be < %" PRIu32 " (%" PRIu32 ")", cfg->channels, ch); in dma_rpi_pico_stop()
278 if (ch >= cfg->channels) { in dma_rpi_pico_get_status()
279 LOG_ERR("channel must be < %" PRIu32 " (%" PRIu32 ")", cfg->channels, ch); in dma_rpi_pico_get_status()
284 stat->dir = data->channels[ch].direction; in dma_rpi_pico_get_status()
320 for (uint32_t i = 0; i < cfg->channels; i++) { in dma_rpi_pico_isr()
333 if (data->channels[i].callback) { in dma_rpi_pico_isr()
334 data->channels[i].callback(dev, data->channels[i].user_data, i, err); in dma_rpi_pico_isr()
364 .channels = DT_INST_PROP(inst, dma_channels), \
380 .channels = dma_rpi_pico##inst##_channels, \