Home
last modified time | relevance | path

Searched refs:target_cfg (Results 1 – 14 of 14) sorted by relevance

/Zephyr-latest/drivers/i2c/
Di2c_emul.c33 struct i2c_target_config *target_cfg; member
91 const struct i2c_target_callbacks *callbacks = data->target_cfg->callbacks; in i2c_emul_send_to_target()
102 callbacks->buf_read_requested(data->target_cfg, &ptr, &len); in i2c_emul_send_to_target()
113 callbacks->buf_write_received(data->target_cfg, msgs[i].buf, in i2c_emul_send_to_target()
117 int rc = callbacks->stop(data->target_cfg); in i2c_emul_send_to_target()
137 rc = callbacks->read_requested(data->target_cfg, in i2c_emul_send_to_target()
142 rc = callbacks->read_processed(data->target_cfg, in i2c_emul_send_to_target()
155 rc = callbacks->write_requested(data->target_cfg); in i2c_emul_send_to_target()
162 rc = callbacks->write_received(data->target_cfg, msgs[i].buf[j]); in i2c_emul_send_to_target()
169 int rc = callbacks->stop(data->target_cfg); in i2c_emul_send_to_target()
[all …]
Di2c_gecko.c43 struct i2c_target_config *target_cfg; member
191 data->target_cfg = cfg; in i2c_gecko_target_register()
211 data->target_cfg = NULL; in i2c_gecko_target_unregister()
256 data->target_cfg->callbacks->read_requested(data->target_cfg, in i2c_gecko_isr()
260 data->target_cfg->callbacks->write_requested(data->target_cfg); in i2c_gecko_isr()
267 data->target_cfg->callbacks->write_received(data->target_cfg, rx_byte); in i2c_gecko_isr()
275 data->target_cfg->callbacks->read_processed(data->target_cfg, &tx_byte); in i2c_gecko_isr()
283 data->target_cfg->callbacks->stop(data->target_cfg); in i2c_gecko_isr()
Di2c_bcm_iproc.c162 struct i2c_target_config *target_cfg; member
231 struct i2c_target_config *target_config = dd->target_cfg; in iproc_i2c_target_init()
305 struct i2c_target_config *target_cfg = dd->target_cfg; in iproc_i2c_target_read() local
318 target_cfg->callbacks->write_requested(target_cfg); in iproc_i2c_target_read()
323 target_cfg->callbacks->write_received(target_cfg, rx_data); in iproc_i2c_target_read()
327 target_cfg->callbacks->write_received(target_cfg, rx_data); in iproc_i2c_target_read()
329 target_cfg->callbacks->stop(target_cfg); in iproc_i2c_target_read()
372 struct i2c_target_config *target_cfg = dd->target_cfg; in iproc_i2c_target_isr() local
411 target_cfg->callbacks->read_requested(target_cfg, &data); in iproc_i2c_target_isr()
414 target_cfg->callbacks->read_processed(target_cfg, &data); in iproc_i2c_target_isr()
[all …]
Di2c_xilinx_axi.c35 struct i2c_target_config *target_cfg; member
82 if (data->target_cfg) { in i2c_xilinx_axi_target_register()
87 data->target_cfg = cfg; in i2c_xilinx_axi_target_register()
109 if (!data->target_cfg) { in i2c_xilinx_axi_target_unregister()
119 data->target_cfg = NULL; in i2c_xilinx_axi_target_unregister()
152 if ((*data->target_cfg->callbacks->read_requested)(data->target_cfg, in i2c_xilinx_axi_target_isr()
162 if ((*data->target_cfg->callbacks->write_requested)(data->target_cfg)) { in i2c_xilinx_axi_target_isr()
172 (*data->target_cfg->callbacks->stop)(data->target_cfg); in i2c_xilinx_axi_target_isr()
187 if ((*data->target_cfg->callbacks->write_received)(data->target_cfg, in i2c_xilinx_axi_target_isr()
208 (*data->target_cfg->callbacks->read_processed)(data->target_cfg, in i2c_xilinx_axi_target_isr()
[all …]
Di2c_npcx_controller.h94 struct i2c_target_config *target_cfg, uint8_t port);
107 struct i2c_target_config *target_cfg);
Di2c_npcx_port.c148 struct i2c_target_config *target_cfg) in i2c_npcx_target_register() argument
152 if (!target_cfg) { in i2c_npcx_target_register()
161 return npcx_i2c_ctrl_target_register(config->i2c_ctrl, target_cfg, config->port); in i2c_npcx_target_register()
165 struct i2c_target_config *target_cfg) in i2c_npcx_target_unregister() argument
174 return npcx_i2c_ctrl_target_unregister(config->i2c_ctrl, target_cfg); in i2c_npcx_target_unregister()
Di2c_mcux_flexcomm.c41 struct i2c_target_config *target_cfg; member
232 if (target->target_attached && target->target_cfg->address == address) { in mcux_flexcomm_find_target_by_address()
276 addr->address = target->target_cfg->address; in mcux_flexcomm_setup_i2c_config_address()
300 target_cb = target->target_cfg->callbacks; in i2c_target_transfer_callback()
307 target_cb->read_requested(target->target_cfg, &txVal); in i2c_target_transfer_callback()
309 target_cb->read_processed(target->target_cfg, &txVal); in i2c_target_transfer_callback()
319 target_cb->write_requested(target->target_cfg); in i2c_target_transfer_callback()
331 target_cb->write_received(target->target_cfg, rxVal); in i2c_target_transfer_callback()
338 target_cb->stop(target->target_cfg); in i2c_target_transfer_callback()
393 target->target_cfg = target_config; in mcux_flexcomm_target_register()
[all …]
Di2c_mcux_lpi2c.c68 struct i2c_target_config *target_cfg; member
321 const struct i2c_target_callbacks *target_cb = data->target_cfg->callbacks; in mcux_lpi2c_slave_irq_handler()
350 ret = target_cb->write_requested(data->target_cfg); in mcux_lpi2c_slave_irq_handler()
358 ret = target_cb->write_received(data->target_cfg, in mcux_lpi2c_slave_irq_handler()
373 ret = target_cb->read_requested(data->target_cfg, in mcux_lpi2c_slave_irq_handler()
385 ret = target_cb->read_processed(data->target_cfg, in mcux_lpi2c_slave_irq_handler()
401 target_cb->stop(data->target_cfg); in mcux_lpi2c_slave_irq_handler()
436 data->target_cfg = target_config; in mcux_lpi2c_target_register()
469 data->target_cfg = NULL; in mcux_lpi2c_target_unregister()
Di2c_ite_enhance.c143 struct i2c_target_config *target_cfg; member
992 const struct i2c_target_callbacks *target_cb = data->target_cfg->callbacks; in target_i2c_isr_dma()
1017 target_cb->buf_write_received(data->target_cfg, in target_i2c_isr_dma()
1023 target_cb->stop(data->target_cfg); in target_i2c_isr_dma()
1035 target_cb->buf_read_requested(data->target_cfg, in target_i2c_isr_dma()
1057 const struct i2c_target_callbacks *target_cb = data->target_cfg->callbacks; in target_i2c_isr_pio()
1064 ret = target_cb->write_requested(data->target_cfg); in target_i2c_isr_pio()
1068 if (!target_cb->read_requested(data->target_cfg, &val)) { in target_i2c_isr_pio()
1077 if (!target_cb->read_processed(data->target_cfg, &val)) { in target_i2c_isr_pio()
1083 ret = target_cb->write_received(data->target_cfg, val); in target_i2c_isr_pio()
[all …]
Di2c_mchp_xec_v2.c102 struct i2c_target_config *target_cfg; member
251 if (data->target_cfg) { in i2c_xec_reset_config()
252 regs->OWN_ADDR = data->target_cfg->address; in i2c_xec_reset_config()
812 data->target_cfg->callbacks; in i2c_xec_bus_isr()
841 target_cb->stop(data->target_cfg); in i2c_xec_bus_isr()
850 target_cb->stop(data->target_cfg); in i2c_xec_bus_isr()
870 data->target_cfg, &val); in i2c_xec_bus_isr()
897 data->target_cfg); in i2c_xec_bus_isr()
941 data->target_cfg, &val); in i2c_xec_bus_isr()
958 ret = target_cb->write_received(data->target_cfg, val); in i2c_xec_bus_isr()
[all …]
Di2c_npcx_controller.c165 struct i2c_target_config *target_cfg; member
757 const struct i2c_target_callbacks *target_cb = data->target_cfg->callbacks; in i2c_ctrl_target_isr()
767 target_cb->stop(data->target_cfg); in i2c_ctrl_target_isr()
794 target_cb->stop(data->target_cfg); in i2c_ctrl_target_isr()
818 target_cb->read_requested(data->target_cfg, &val); in i2c_ctrl_target_isr()
826 target_cb->write_requested(data->target_cfg); in i2c_ctrl_target_isr()
837 target_cb->read_processed(data->target_cfg, &val); in i2c_ctrl_target_isr()
844 target_cb->write_received(data->target_cfg, val); in i2c_ctrl_target_isr()
1073 struct i2c_target_config *target_cfg, uint8_t port) in npcx_i2c_ctrl_target_register() argument
1079 uint8_t addr = BIT(NPCX_SMBADDR1_SAEN) | target_cfg->address; in npcx_i2c_ctrl_target_register()
[all …]
Di2c_max32.c60 struct i2c_target_config *target_cfg; member
114 data->target_cfg = cfg; in api_target_register()
132 data->target_cfg = NULL; in api_target_unregister()
146 const struct i2c_target_callbacks *target_cb = data->target_cfg->callbacks; in i2c_max32_target_callback()
152 target_cb->write_requested(data->target_cfg); in i2c_max32_target_callback()
164 target_cb->write_received(data->target_cfg, rxval); in i2c_max32_target_callback()
173 target_cb->read_requested(data->target_cfg, &txval); in i2c_max32_target_callback()
177 target_cb->read_processed(data->target_cfg, &txval); in i2c_max32_target_callback()
182 target_cb->stop(data->target_cfg); in i2c_max32_target_callback()
Di2c_mcux_lpi2c_rtio.c62 struct i2c_target_config *target_cfg; member
/Zephyr-latest/samples/drivers/i2c/custom_target/src/
Dmain.c80 struct i2c_target_config target_cfg = { in main() local
87 if (i2c_target_register(bus, &target_cfg) < 0) { in main()
94 if (i2c_target_unregister(bus, &target_cfg) < 0) { in main()