Re: [PATCH v2] interconnect: qcom: bcm-voter: Clear the ALC vote left by the bootloader

From: Konrad Dybcio

Date: Mon Nov 23 2026 - 13:43:45 EST


On 11/20/26 10:41 PM, Michael Auer wrote:
> Hi,
>
> A sashiko review of this patch found that the wake and sleep writes
> never reach the hardware. rpmh only caches them, the (0, 0) wake write
> replaces the (12, 0) wake value from the active-only write, and
> rpmh_flush() skips entries with equal sleep and wake values.
>
> That matches the OnePlus 6: the rpmh cache has ALC at sleep 0 and
> wake 0, and the APPS DRV vote read back after a night with 139
> suspends is still 0x20030000, so (12, 0). What I tested is the
> active-only (12, 0) vote alone, held through suspend, and with it the
> SoC reaches CX collapse.

I was hoping you would test my suggestion before sending it out..

> Konrad, did you mean ALC to drop to (0, 0) in sleep? Then the wake
> write has to go, so that rpmh_flush() programs both sets. I can test
> that. If the active vote is enough, I would drop the wake and sleep
> writes in v3, so the code does what was tested.

My agent suggests that changing this to use rpmh_write_batch() as
these aren't cached and should achieve the desired outcome, please
explore that

Konrad