Re: [PATCH] irqchip/qcom-pdc: Restore the configuration when resuming
From: Konrad Dybcio
Date: Tue Oct 27 2026 - 07:59:15 EST
On 10/26/26 5:37 PM, Abel Vesa wrote:
> A hibernation image is restored after a power cycle, and after the
> kernel that loaded the image has set the PDC up for its own
> interrupts. The restored kernel then runs with the PDC configured for
> another set of interrupts: a GPIO interrupt it uses may be disabled or
> have another type. On a Qualcomm Glymur CRD the EC interrupt, which the
> PDC detects for the TLMM, then fires forever:
>
> qcom-hamoa-ec 3-0076: Unknown EC event: 0
> qcom_ec_irq: 20501 callbacks suppressed
>
> Restoring the TLMM configuration does not help, as the trigger type
> and the enable for such a pin live in the PDC.
[...]
> +static u32 pdc_last_bank(void)
> +{
> + u32 last = 0;
> + int n;
You can declare the iterator as part of the loop, since you don't
you use it outside the scope anyway (also in other funcs)
Otherwise I think this looks ok
Konrad