Lines Matching refs:index
969 #define UART_DMA_CHANNEL_INIT(index, dir, ch_dir, src_burst, dst_burst) \ argument
970 .dma_dev = DEVICE_DT_GET(DT_INST_DMAS_CTLR_BY_NAME(index, dir)), \
971 .dma_channel = DT_INST_DMAS_CELL_BY_NAME(index, dir, channel), \
973 .dma_slot = DT_INST_DMAS_CELL_BY_NAME(index, dir, config), \
975 .channel_priority = DT_INST_DMAS_CELL_BY_NAME(index, dir, priority), \
984 #define UART_DMA_CHANNEL(index, dir, ch_dir, src_burst, dst_burst) \ argument
986 DT_INST_DMAS_HAS_NAME(index, dir), \
987 (UART_DMA_CHANNEL_INIT(index, dir, ch_dir, src_burst, dst_burst)), (NULL))},
989 #define UART_DMA_CHANNEL(index, dir, ch_dir, src_burst, dst_burst) argument
993 #define XMC4XXX_IRQ_HANDLER(index) \ argument
994 static void uart_xmc4xxx_irq_setup_##index(const struct device *dev) \
996 IRQ_CONNECT(DT_INST_IRQ_BY_NAME(index, tx, irq), \
997 DT_INST_IRQ_BY_NAME(index, tx, priority), uart_xmc4xxx_isr, \
998 DEVICE_DT_INST_GET(index), 0); \
999 IRQ_CONNECT(DT_INST_IRQ_BY_NAME(index, rx, irq), \
1000 DT_INST_IRQ_BY_NAME(index, rx, priority), uart_xmc4xxx_isr, \
1001 DEVICE_DT_INST_GET(index), 0); \
1002 irq_enable(DT_INST_IRQ_BY_NAME(index, tx, irq)); \
1003 irq_enable(DT_INST_IRQ_BY_NAME(index, rx, irq)); \
1006 #define XMC4XXX_IRQ_STRUCT_INIT(index) \ argument
1007 .irq_config_func = uart_xmc4xxx_irq_setup_##index, \
1008 .irq_num_tx = DT_INST_IRQ_BY_NAME(index, tx, irq), \
1009 .irq_num_rx = DT_INST_IRQ_BY_NAME(index, rx, irq),
1012 #define XMC4XXX_IRQ_HANDLER(index) argument
1013 #define XMC4XXX_IRQ_STRUCT_INIT(index) argument
1016 #define XMC4XXX_INIT(index) \ argument
1017 PINCTRL_DT_INST_DEFINE(index); \
1018 XMC4XXX_IRQ_HANDLER(index) \
1019 static struct uart_xmc4xxx_data xmc4xxx_data_##index = { \
1020 .config.baudrate = DT_INST_PROP(index, current_speed), \
1021 UART_DMA_CHANNEL(index, tx, MEMORY_TO_PERIPHERAL, 8, 1) \
1022 UART_DMA_CHANNEL(index, rx, PERIPHERAL_TO_MEMORY, 1, 8) \
1025 static const struct uart_xmc4xxx_config xmc4xxx_config_##index = { \
1026 .uart = (XMC_USIC_CH_t *)DT_INST_REG_ADDR(index), \
1027 .pcfg = PINCTRL_DT_INST_DEV_CONFIG_GET(index), \
1028 .input_src = DT_INST_ENUM_IDX(index, input_src), \
1029 XMC4XXX_IRQ_STRUCT_INIT(index) \
1030 .fifo_start_offset = DT_INST_PROP(index, fifo_start_offset), \
1031 .fifo_tx_size = DT_INST_ENUM_IDX(index, fifo_tx_size), \
1032 .fifo_rx_size = DT_INST_ENUM_IDX(index, fifo_rx_size), \
1035 DEVICE_DT_INST_DEFINE(index, uart_xmc4xxx_init, \
1037 &xmc4xxx_data_##index, \
1038 &xmc4xxx_config_##index, PRE_KERNEL_1, \