Re: [PATCH 1/9] coresight: cpu-debug: Fix PM usage counter leak in debug_enable_func()

From: Leo Yan

Date: Tue Oct 27 2026 - 14:10:19 EST


On Tue, Oct 27, 2026 at 02:55:47PM +0000, James Clark wrote:
> pm_runtime_get_sync() increments the usage counter even when it fails,
> but the failing CPU isn't added to the rollback mask, so its reference
> is never dropped. Use pm_runtime_resume_and_get() which drops the
> reference itself on failure.
>
> Fixes: 2227b7c74634 ("coresight: add support for CPU debug module")
> Reported-by: Sashiko <sashiko-bot@xxxxxxxxxx>
> Closes: https://sashiko.dev/#/bug/linux-2ff60e6d-33ac-4a69-9c62-63eb482f1913
> Signed-off-by: James Clark <james.clark@xxxxxxxxxx>

This duplicates with:
https://lore.kernel.org/linux-arm-kernel/20260911-b4-coresight-runtime-pm-failures-v1-1-acdf49756e11@xxxxxxxxxxxxxxxx/#r

I'd prefer to pick up that patch, as it has fixed all drivers in the
CoreSight directory.

Thanks,
Leo