Re: [PATCH v2] PM: sleep: Add DPM watchdog to prepare/late/early/noirq/complete phases

From: Rafael J. Wysocki (Intel)

Date: Fri Sep 25 2026 - 13:02:27 EST


On Fri, Sep 11, 2026 at 3:24 PM Tzung-Bi Shih <tzungbi@xxxxxxxxxx> wrote:
>
> On Thu, Sep 10, 2026 at 10:01:40AM -0700, Doug Anderson wrote:
> > On Wed, Sep 9, 2026 at 3:48 PM Mayank Rungta <mrungta@xxxxxxxxxx> wrote:
> > >
> > > Extend the DPM watchdog to wrap device_prepare, device_suspend_late,
> > > device_suspend_noirq, device_resume_noirq, device_resume_early, and
> > > device_complete callbacks. If a driver hangs during these transitions,
> > > the watchdog will fire and dump a stack trace to help identify the
> > > offending driver.
> > >
> > > To prevent false-positive timeouts, the watchdog is set only after
> > > waiting for subordinate (during suspend) and superior (during resume)
> > > devices. With this change, DPM watchdog coverage is extended across all
> > > phases of system sleep transitions.
> > >
> > > Signed-off-by: Mayank Rungta <mrungta@xxxxxxxxxx>
> > > ---
> > > v2:
> > > - Extend DPM watchdog to device_prepare and device_complete callbacks.
> > > - Update commit subject and description to reflect coverage across all
> > > system sleep phases.
> > > v1:
> > > - Initial version adding DPM watchdog to late/early/noirq phases.
> > >
> > > Testing:
> > > - Tested on an ARM64 SoC (Pixel platform running a 6.18-based kernel with
> > > DPM watchdog enabled; Android 6.18 kernel has latest DPM changes
> > > backported).
> > > - Verified hang simulation in device_prepare and device_complete
> > > triggers DPM watchdog panic and stack trace as expected.
> > >
> > > drivers/base/power/main.c | 31 ++++++++++++++++++++++++++++---
> > > 1 file changed, 28 insertions(+), 3 deletions(-)
> >
> > Thanks! I guess you dropped my (and Tzung-Bi's) Reviewed-by tags
> > because of the minor changes between v1 and v2? They look right to me,
> > so:
> >
> > Reviewed-by: Douglas Anderson <dianders@xxxxxxxxxxxx>
>
> They look right to me too:
> Reviewed-by: Tzung-Bi Shih <tzungbi@xxxxxxxxxx>

Applied as 7.4 material, thanks!