mirror of
https://github.com/zephyrproject-rtos/zephyr
synced 2025-09-07 20:13:03 +00:00
This patch restructures stm32_i2c_v2 drivers Interrupts: - NACK failures trigger an I2C event interrupt, so move handling of NACK failure from error isr to event isr. - Extract logic of interrupt handling to static functions. Use isr functions (event & error OR combined) to call these. This reduces duplication between error isr and combined isr. - Restructure the error interrupt handling, so that it has no effect when no errors occured and thus can be called by combined isr. - Change interrupt logic from if/else to pure ifs for each flag. This reduces code paths and leads to one call of the isr handling multiple interrupt conditions, if there's more than one I2C interrupt flags set. This is the way it's done e.g. in linux kernels (since 4.14) drivers/i2c/busses/i2c-stm32f7.c Signed-off-by: Daniel Wagenknecht <wagenknecht@clage.de> |
||
---|---|---|
.. | ||
CMakeLists.txt | ||
i2c_atmel_sam3.c | ||
i2c_bitbang.c | ||
i2c_bitbang.h | ||
i2c_cc32xx.c | ||
i2c_dw_registers.h | ||
i2c_dw.c | ||
i2c_dw.h | ||
i2c_esp32.c | ||
i2c_gpio.c | ||
i2c_handlers.c | ||
i2c_ll_stm32_v1.c | ||
i2c_ll_stm32_v2.c | ||
i2c_ll_stm32.c | ||
i2c_ll_stm32.h | ||
i2c_mcux.c | ||
i2c_nios2.c | ||
i2c_nrfx_twi.c | ||
i2c_nrfx_twim.c | ||
i2c_qmsi_ss.c | ||
i2c_qmsi.c | ||
i2c_sam_twi.c | ||
i2c_sam_twihs.c | ||
i2c_sbcon.c | ||
i2c-priv.h | ||
Kconfig | ||
Kconfig.dw | ||
Kconfig.esp32 | ||
Kconfig.gpio | ||
Kconfig.nrfx | ||
Kconfig.qmsi | ||
Kconfig.sbcon | ||
Kconfig.stm32 |