1# Copyright (c) 2018 Intel Corporation 2# SPDX-License-Identifier: Apache-2.0 3 4menuconfig I2C_STM32 5 bool "STM32 I2C driver" 6 default y 7 depends on DT_HAS_ST_STM32_I2C_V1_ENABLED || DT_HAS_ST_STM32_I2C_V2_ENABLED 8 help 9 Enable I2C support on the STM32 SoCs 10 11if I2C_STM32 12 13config I2C_STM32_V1 14 bool 15 default y 16 depends on DT_HAS_ST_STM32_I2C_V1_ENABLED 17 select USE_STM32_LL_I2C 18 select I2C_STM32_INTERRUPT if I2C_TARGET 19 help 20 Driver variant matching `st,stm32-i2c-v1` compatible. 21 22config I2C_STM32_V2 23 bool 24 default y 25 depends on DT_HAS_ST_STM32_I2C_V2_ENABLED 26 select USE_STM32_LL_I2C 27 select USE_STM32_LL_RCC if SOC_SERIES_STM32F0X || SOC_SERIES_STM32F3X 28 select I2C_STM32_INTERRUPT if I2C_TARGET 29 help 30 Driver variant matching `st,stm32-i2c-v2` compatible. 31 If I2C_TARGET is enabled it selects I2C_STM32_INTERRUPT, since target mode 32 is only supported by this driver with interrupts enabled. 33 34config I2C_STM32_INTERRUPT 35 bool "STM32 MCU I2C Interrupt Support" 36 depends on I2C_STM32_V1 || I2C_STM32_V2 37 default y 38 help 39 Enable Interrupt support for the I2C Driver 40 41config I2C_STM32_COMBINED_INTERRUPT 42 bool 43 depends on I2C_STM32_INTERRUPT 44 default y if SOC_SERIES_STM32C0X || SOC_SERIES_STM32F0X || \ 45 SOC_SERIES_STM32G0X || SOC_SERIES_STM32L0X 46 47config I2C_STM32_BUS_RECOVERY 48 bool "Bus recovery support" 49 select I2C_BITBANG 50 help 51 Enable STM32 driver bus recovery support via GPIO bitbanging. 52 53endif # I2C_STM32 54