* Re: [PATCH] i2c: qcom-cci: drop custom suspend/resume and rely on runtime PM helpers
2026-06-25 9:42 [PATCH] i2c: qcom-cci: drop custom suspend/resume and rely on runtime PM helpers Wenmeng Liu
@ 2026-06-25 9:51 ` Loic Poulain
2026-06-25 10:22 ` Konrad Dybcio
` (2 subsequent siblings)
3 siblings, 0 replies; 5+ messages in thread
From: Loic Poulain @ 2026-06-25 9:51 UTC (permalink / raw)
To: Wenmeng Liu
Cc: Robert Foss, Andi Shyti, Bjorn Andersson, Wolfram Sang,
Todor Tomov, Vinod Koul, linux-i2c, linux-arm-msm, linux-kernel,
stable
On Thu, Jun 25, 2026 at 11:42 AM Wenmeng Liu
<wenmeng.liu@oss.qualcomm.com> wrote:
>
> cci_resume() unconditionally calls cci_resume_runtime() regardless of
> the runtime PM state.
>
> If the device is already runtime-suspended before system suspend,
> the clock is re-enabled while runtime_status remains RPM_SUSPENDED.
> As a result, pm_request_autosuspend() does not arm the timer,
> leaving the clock permanently enabled.
>
> Fixes: e517526195de ("i2c: Add Qualcomm CCI I2C driver")
> Cc: stable@vger.kernel.org
> Signed-off-by: Wenmeng Liu <wenmeng.liu@oss.qualcomm.com>
Reviewed-by: Loic Poulain <loic.poulain@oss.qualcomm.com>
> ---
> drivers/i2c/busses/i2c-qcom-cci.c | 18 +-----------------
> 1 file changed, 1 insertion(+), 17 deletions(-)
>
> diff --git a/drivers/i2c/busses/i2c-qcom-cci.c b/drivers/i2c/busses/i2c-qcom-cci.c
> index 4d64895a9e9e4e0bd5e0ccb5c3cc04b282b1e4d5..bdeda3979c4814b5cdb463734b8361da7fffa879 100644
> --- a/drivers/i2c/busses/i2c-qcom-cci.c
> +++ b/drivers/i2c/busses/i2c-qcom-cci.c
> @@ -492,24 +492,8 @@ static int __maybe_unused cci_resume_runtime(struct device *dev)
> return 0;
> }
>
> -static int __maybe_unused cci_suspend(struct device *dev)
> -{
> - if (!pm_runtime_suspended(dev))
> - return cci_suspend_runtime(dev);
> -
> - return 0;
> -}
> -
> -static int __maybe_unused cci_resume(struct device *dev)
> -{
> - cci_resume_runtime(dev);
> - pm_request_autosuspend(dev);
> -
> - return 0;
> -}
> -
> static const struct dev_pm_ops qcom_cci_pm = {
> - SET_SYSTEM_SLEEP_PM_OPS(cci_suspend, cci_resume)
> + SET_SYSTEM_SLEEP_PM_OPS(pm_runtime_force_suspend, pm_runtime_force_resume)
> SET_RUNTIME_PM_OPS(cci_suspend_runtime, cci_resume_runtime, NULL)
> };
>
>
> ---
> base-commit: 4e5dfb7c84012007c3c7061126491bbc92d71bf1
> change-id: 20260625-cci-3eedf766d43b
>
> Best regards,
> --
> Wenmeng Liu <wenmeng.liu@oss.qualcomm.com>
>
^ permalink raw reply [flat|nested] 5+ messages in thread* Re: [PATCH] i2c: qcom-cci: drop custom suspend/resume and rely on runtime PM helpers
2026-06-25 9:42 [PATCH] i2c: qcom-cci: drop custom suspend/resume and rely on runtime PM helpers Wenmeng Liu
2026-06-25 9:51 ` Loic Poulain
@ 2026-06-25 10:22 ` Konrad Dybcio
2026-06-25 11:07 ` Vladimir Zapolskiy
2026-07-28 21:37 ` Andi Shyti
3 siblings, 0 replies; 5+ messages in thread
From: Konrad Dybcio @ 2026-06-25 10:22 UTC (permalink / raw)
To: Wenmeng Liu, Loic Poulain, Robert Foss, Andi Shyti,
Bjorn Andersson, Wolfram Sang, Todor Tomov, Vinod Koul
Cc: linux-i2c, linux-arm-msm, linux-kernel, stable
On 6/25/26 11:42 AM, Wenmeng Liu wrote:
> cci_resume() unconditionally calls cci_resume_runtime() regardless of
> the runtime PM state.
>
> If the device is already runtime-suspended before system suspend,
> the clock is re-enabled while runtime_status remains RPM_SUSPENDED.
> As a result, pm_request_autosuspend() does not arm the timer,
> leaving the clock permanently enabled.
>
> Fixes: e517526195de ("i2c: Add Qualcomm CCI I2C driver")
> Cc: stable@vger.kernel.org
> Signed-off-by: Wenmeng Liu <wenmeng.liu@oss.qualcomm.com>
> ---
Reviewed-by: Konrad Dybcio <konrad.dybcio@oss.qualcomm.com>
Konrad
^ permalink raw reply [flat|nested] 5+ messages in thread* Re: [PATCH] i2c: qcom-cci: drop custom suspend/resume and rely on runtime PM helpers
2026-06-25 9:42 [PATCH] i2c: qcom-cci: drop custom suspend/resume and rely on runtime PM helpers Wenmeng Liu
2026-06-25 9:51 ` Loic Poulain
2026-06-25 10:22 ` Konrad Dybcio
@ 2026-06-25 11:07 ` Vladimir Zapolskiy
2026-07-28 21:37 ` Andi Shyti
3 siblings, 0 replies; 5+ messages in thread
From: Vladimir Zapolskiy @ 2026-06-25 11:07 UTC (permalink / raw)
To: Wenmeng Liu, Loic Poulain, Robert Foss, Andi Shyti,
Bjorn Andersson, Wolfram Sang, Todor Tomov, Vinod Koul
Cc: linux-i2c, linux-arm-msm, linux-kernel, stable
On 6/25/26 12:42, Wenmeng Liu wrote:
> cci_resume() unconditionally calls cci_resume_runtime() regardless of
> the runtime PM state.
>
> If the device is already runtime-suspended before system suspend,
> the clock is re-enabled while runtime_status remains RPM_SUSPENDED.
> As a result, pm_request_autosuspend() does not arm the timer,
> leaving the clock permanently enabled.
>
> Fixes: e517526195de ("i2c: Add Qualcomm CCI I2C driver")
> Cc: stable@vger.kernel.org
> Signed-off-by: Wenmeng Liu <wenmeng.liu@oss.qualcomm.com>
> ---
> drivers/i2c/busses/i2c-qcom-cci.c | 18 +-----------------
> 1 file changed, 1 insertion(+), 17 deletions(-)
>
> diff --git a/drivers/i2c/busses/i2c-qcom-cci.c b/drivers/i2c/busses/i2c-qcom-cci.c
> index 4d64895a9e9e4e0bd5e0ccb5c3cc04b282b1e4d5..bdeda3979c4814b5cdb463734b8361da7fffa879 100644
> --- a/drivers/i2c/busses/i2c-qcom-cci.c
> +++ b/drivers/i2c/busses/i2c-qcom-cci.c
> @@ -492,24 +492,8 @@ static int __maybe_unused cci_resume_runtime(struct device *dev)
> return 0;
> }
>
> -static int __maybe_unused cci_suspend(struct device *dev)
> -{
> - if (!pm_runtime_suspended(dev))
> - return cci_suspend_runtime(dev);
> -
> - return 0;
> -}
> -
> -static int __maybe_unused cci_resume(struct device *dev)
> -{
> - cci_resume_runtime(dev);
> - pm_request_autosuspend(dev);
> -
> - return 0;
> -}
> -
> static const struct dev_pm_ops qcom_cci_pm = {
> - SET_SYSTEM_SLEEP_PM_OPS(cci_suspend, cci_resume)
> + SET_SYSTEM_SLEEP_PM_OPS(pm_runtime_force_suspend, pm_runtime_force_resume)
> SET_RUNTIME_PM_OPS(cci_suspend_runtime, cci_resume_runtime, NULL)
> };
>
Reviewed-by: Vladimir Zapolskiy <vladimir.zapolskiy@linaro.org>
--
Best wishes,
Vladimir
^ permalink raw reply [flat|nested] 5+ messages in thread* Re: [PATCH] i2c: qcom-cci: drop custom suspend/resume and rely on runtime PM helpers
2026-06-25 9:42 [PATCH] i2c: qcom-cci: drop custom suspend/resume and rely on runtime PM helpers Wenmeng Liu
` (2 preceding siblings ...)
2026-06-25 11:07 ` Vladimir Zapolskiy
@ 2026-07-28 21:37 ` Andi Shyti
3 siblings, 0 replies; 5+ messages in thread
From: Andi Shyti @ 2026-07-28 21:37 UTC (permalink / raw)
To: Wenmeng Liu
Cc: Loic Poulain, Robert Foss, Bjorn Andersson, Wolfram Sang,
Todor Tomov, Vinod Koul, linux-i2c, linux-arm-msm, linux-kernel,
stable
Hi Wenmeng,
On Thu, Jun 25, 2026 at 05:42:45PM +0800, Wenmeng Liu wrote:
> cci_resume() unconditionally calls cci_resume_runtime() regardless of
> the runtime PM state.
>
> If the device is already runtime-suspended before system suspend,
> the clock is re-enabled while runtime_status remains RPM_SUSPENDED.
> As a result, pm_request_autosuspend() does not arm the timer,
> leaving the clock permanently enabled.
>
> Fixes: e517526195de ("i2c: Add Qualcomm CCI I2C driver")
> Cc: stable@vger.kernel.org
> Signed-off-by: Wenmeng Liu <wenmeng.liu@oss.qualcomm.com>
merged to i2c/i2c-fixes.
Thanks,
Andi
^ permalink raw reply [flat|nested] 5+ messages in thread