Re: [PATCH v2 5/9] irqchip/irq-qcom-mpm: Program wakeup timer when CPU cluster goes to LPM

From: Konrad Dybcio

Date: Mon Oct 19 2026 - 07:57:31 EST


On 10/15/26 11:55 AM, Sneh Mankad wrote:
> The next wakeup timer value needs to be set in MPM timer as the arch timer
> interrupt can not wakeup the SoC if after the deepest CPUidle states the
> SoC also enters deepest low power state.
>
> To wakeup the SoC in such scenarios the earliest wakeup time is set in MPM
> timer and the Resource Power Manager (RPM processor) takes care of setting
> the timer in HW.
>
> Add MPM timer programming when CPU cluster enters power collapse.
>
> Signed-off-by: Sneh Mankad <sneh.mankad@xxxxxxxxxxxxxxxx>
> ---

[...]

> +static void mpm_write_next_wakeup(struct qcom_mpm_priv *priv)
> +{
> + ktime_t now, wakeup = KTIME_MAX;
> + u64 wakeup_us, wakeup_cycles = ~0;
> + u32 lo, hi;
> +
> + /* Set highest time when system (timekeeping) is suspended */
> + if (system_state == SYSTEM_SUSPEND)
> + goto exit;
> +
> + /* Find the relative wakeup in kernel time scale */
> + wakeup = dev_pm_genpd_get_next_hrtimer(priv->dev);

This returns KTIME_MAX after the DT patches in this series are merged
(because there's no power_domain that the MPM hangs off of anymore)

Konrad