From: Johan Hovold <johan@kernel.org>
To: "Rafael J. Wysocki" <rjw@rjwysocki.net>
Cc: Linux PM <linux-pm@vger.kernel.org>,
LKML <linux-kernel@vger.kernel.org>,
Alan Stern <stern@rowland.harvard.edu>,
Bjorn Helgaas <helgaas@kernel.org>,
Linux PCI <linux-pci@vger.kernel.org>,
Ulf Hansson <ulf.hansson@linaro.org>,
Manivannan Sadhasivam <manivannan.sadhasivam@linaro.org>,
Kevin Xie <kevin.xie@starfivetech.com>
Subject: Re: [PATCH v1] PM: sleep: core: Synchronize runtime PM status of parents and children
Date: Wed, 29 Jan 2025 09:31:37 +0100 [thread overview]
Message-ID: <Z5nnaU5VnDK9yNTW@hovoldconsulting.com> (raw)
In-Reply-To: <12619233.O9o76ZdvQC@rjwysocki.net>
On Tue, Jan 28, 2025 at 08:24:41PM +0100, Rafael J. Wysocki wrote:
> From: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
>
> Commit 6e176bf8d461 ("PM: sleep: core: Do not skip callbacks in the
> resume phase") overlooked the case in which the parent of a device with
> DPM_FLAG_SMART_SUSPEND set did not use that flag and could be runtime-
> suspended before a transition into a system-wide sleep state. In that
> case, if the child is resumed during the subsequent transition from
> that state into the working state, its runtime PM status will be set to
> RPM_ACTIVE, but the runtime PM status of the parent will not be updated
> accordingly, even though the parent will be resumed too, because of the
> dev_pm_skip_suspend() check in device_resume_noirq().
>
> Address this problem by tracking the need to set the runtime PM status
> to RPM_ACTIVE during system-wide resume transitions for devices with
> DPM_FLAG_SMART_SUSPEND set and all of the devices depended on by them.
>
> Fixes: 6e176bf8d461 ("PM: sleep: core: Do not skip callbacks in the resume phase")
> Closes: https://lore.kernel.org/linux-pm/Z30p2Etwf3F2AUvD@hovoldconsulting.com/
> Reported-by: Johan Hovold <johan@kernel.org>
> Tested-by: Manivannan Sadhasivam <manivannan.sadhasivam@linaro.org>
> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
Thanks for tracking this down Mani, and thanks Rafael for the quick fix.
As expected this makes the warning go away also in my setup, and the
patch itself looks correct to me:
Reviewed-by: Johan Hovold <johan+linaro@kernel.org>
Tested-by: Johan Hovold <johan+linaro@kernel.org>
Johan
next prev parent reply other threads:[~2025-01-29 8:31 UTC|newest]
Thread overview: 21+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-01-28 19:24 [PATCH v1] PM: sleep: core: Synchronize runtime PM status of parents and children Rafael J. Wysocki
2025-01-29 8:31 ` Johan Hovold [this message]
2025-01-29 11:52 ` Ulf Hansson
2025-01-29 15:55 ` Rafael J. Wysocki
2025-01-29 16:42 ` Ulf Hansson
2025-01-29 16:58 ` Rafael J. Wysocki
2025-01-30 11:11 ` Ulf Hansson
2025-01-30 13:19 ` Rafael J. Wysocki
2025-01-31 10:01 ` Ulf Hansson
2025-02-01 12:35 ` Rafael J. Wysocki
2025-02-03 12:12 ` Ulf Hansson
2025-02-07 13:38 ` Jon Hunter
2025-02-07 13:50 ` Johan Hovold
2025-02-07 14:45 ` Johan Hovold
2025-02-07 15:41 ` Rafael J. Wysocki
2025-02-07 16:06 ` Johan Hovold
2025-02-07 16:26 ` Johan Hovold
2025-02-07 18:14 ` Rafael J. Wysocki
2025-02-08 12:10 ` Rafael J. Wysocki
2025-02-08 16:42 ` Johan Hovold
2025-02-08 17:43 ` Rafael J. Wysocki
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=Z5nnaU5VnDK9yNTW@hovoldconsulting.com \
--to=johan@kernel.org \
--cc=helgaas@kernel.org \
--cc=kevin.xie@starfivetech.com \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-pci@vger.kernel.org \
--cc=linux-pm@vger.kernel.org \
--cc=manivannan.sadhasivam@linaro.org \
--cc=rjw@rjwysocki.net \
--cc=stern@rowland.harvard.edu \
--cc=ulf.hansson@linaro.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox