Skip to content

Commit 5ff3dbe

Browse files
etienne-lmsjhedberg
authored andcommitted
drivers: i2c: stm32: exclude stm32f7 family for PM in RTIO driver
Exclude STM32F7 SoC series from PM support since that SoC doees not yet manage power management in Zephyr and HAL API functions LL_I2C_EnableWakeUpFromStop() and LL_I2C_DisableWakeUpFromStop() are not implemented in the H7 HAL/LL drivers. This change ports into the STM32 RTIO driver the change made in the non-RTIO driver through commit 1804eb7 ("drivers: i2c: stm32: exclude stm32f7 family for PM"). Signed-off-by: Etienne Carriere <[email protected]>
1 parent e29ebbe commit 5ff3dbe

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

drivers/i2c/i2c_ll_stm32_v2_rtio.c

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -212,11 +212,13 @@ int i2c_stm32_target_register(const struct device *dev,
212212
/* Mark device as active */
213213
(void)pm_device_runtime_get(dev);
214214

215+
#if !defined(CONFIG_SOC_SERIES_STM32F7X)
215216
if (pm_device_wakeup_is_capable(dev)) {
216217
/* Enable wake-up from stop */
217218
LOG_DBG("i2c: enabling wakeup from stop");
218219
LL_I2C_EnableWakeUpFromStop(cfg->i2c);
219220
}
221+
#endif /* !CONFIG_SOC_SERIES_STM32F7X */
220222

221223
LL_I2C_Enable(i2c);
222224

@@ -297,11 +299,13 @@ int i2c_stm32_target_unregister(const struct device *dev,
297299

298300
LL_I2C_Disable(i2c);
299301

302+
#if !defined(CONFIG_SOC_SERIES_STM32F7X)
300303
if (pm_device_wakeup_is_capable(dev)) {
301304
/* Disable wake-up from STOP */
302305
LOG_DBG("i2c: disabling wakeup from stop");
303306
LL_I2C_DisableWakeUpFromStop(i2c);
304307
}
308+
#endif /* !CONFIG_SOC_SERIES_STM32F7X */
305309

306310
/* Release the device */
307311
(void)pm_device_runtime_put(dev);

0 commit comments

Comments
 (0)