Re: [PATCH] pmdomain: renesas: r8a78000: Fix lockdep false positive

From: Abel Vesa

Date: Tue Sep 08 2026 - 03:33:17 EST


On 26-09-07 16:32:01, Geert Uytterhoeven wrote:
> Lockdep reports a possible circular locking dependency when attaching
> devices to an MDLC PM domain:
>
> - During creation of the singleton PM domain:
> A. r8a78000_genpd_always_on_singleton() takes r8a78000_mdlc_lock,
> B. pm_genpd_init() takes gpd_list_lock.
>
> - During attachment of devices to PM domains:
> A. pm_genpd_add_device() takes gpd_list_lock,
> B. r8a78000_mdlc_attach_dev() takes r8a78000_mdlc_lock.
>
> As the former is done only once, before any devices are attached, such a
> AB-BA deadlock cannot really happen. Fix this false positive by
> introducing a separate lock to protect the creation of the singleton
> domain.
>
> Fixes: 89e6a71b35703f10 ("pmdomain: renesas: Add R-Car X5H MDLC driver")
> Signed-off-by: Geert Uytterhoeven <geert+renesas@xxxxxxxxx>

Looks OK to me, so:

Reviewed-by: Abel Vesa <abel.vesa@xxxxxxxxxxxxxxxx>