diff --git a/drivers/i2c/i2c_mcux_flexcomm.c b/drivers/i2c/i2c_mcux_flexcomm.c index f0dc4fe6cf2..4527f2764da 100644 --- a/drivers/i2c/i2c_mcux_flexcomm.c +++ b/drivers/i2c/i2c_mcux_flexcomm.c @@ -157,9 +157,7 @@ static int mcux_flexcomm_transfer(const struct device *dev, k_sem_take(&data->lock, K_FOREVER); -#ifdef CONFIG_PM_POLICY_DEVICE_CONSTRAINTS pm_policy_device_power_lock_get(dev); -#endif /* Iterate over all the messages */ for (int i = 0; i < num_msgs; i++) { @@ -215,9 +213,7 @@ static int mcux_flexcomm_transfer(const struct device *dev, msgs++; } -#ifdef CONFIG_PM_POLICY_DEVICE_CONSTRAINTS pm_policy_device_power_lock_put(dev); -#endif k_sem_give(&data->lock); diff --git a/drivers/mipi_dbi/mipi_dbi_nxp_lcdic.c b/drivers/mipi_dbi/mipi_dbi_nxp_lcdic.c index e9db3d71d23..1cca0f37f5f 100644 --- a/drivers/mipi_dbi/mipi_dbi_nxp_lcdic.c +++ b/drivers/mipi_dbi/mipi_dbi_nxp_lcdic.c @@ -430,9 +430,7 @@ static int mipi_dbi_lcdic_write_display(const struct device *dev, goto release_sem; } -#ifdef CONFIG_PM_POLICY_DEVICE_CONSTRAINTS pm_policy_device_power_lock_get(dev); -#endif ret = mipi_dbi_lcdic_configure(dev, dbi_config); if (ret) { @@ -527,9 +525,7 @@ static int mipi_dbi_lcdic_write_display(const struct device *dev, } release_power_lock: -#ifdef CONFIG_PM_POLICY_DEVICE_CONSTRAINTS pm_policy_device_power_lock_put(dev); -#endif release_sem: k_sem_give(&dev_data->lock); @@ -554,9 +550,7 @@ static int mipi_dbi_lcdic_write_cmd(const struct device *dev, goto release_sem; } -#ifdef CONFIG_PM_POLICY_DEVICE_CONSTRAINTS pm_policy_device_power_lock_get(dev); -#endif ret = mipi_dbi_lcdic_configure(dev, dbi_config); if (ret) { @@ -632,9 +626,7 @@ static int mipi_dbi_lcdic_write_cmd(const struct device *dev, } release_power_lock: -#ifdef CONFIG_PM_POLICY_DEVICE_CONSTRAINTS pm_policy_device_power_lock_put(dev); -#endif release_sem: k_sem_give(&dev_data->lock); @@ -821,9 +813,7 @@ static void mipi_dbi_lcdic_isr(const struct device *dev) base->IMR |= LCDIC_ALL_INTERRUPTS; /* All data has been sent. */ k_sem_give(&data->xfer_sem); -#ifdef CONFIG_PM_POLICY_DEVICE_CONSTRAINTS pm_policy_device_power_lock_put(dev); -#endif } else { /* Command done. Queue next command */ data->cmd_bytes = MIN(data->xfer_bytes, LCDIC_MAX_XFER);