From: Greg KH <gregkh@linuxfoundation.org>
To: Pengpeng Hou <hppiscas@163.com>
Cc: b-liu@ti.com, linux-usb@vger.kernel.org,
linux-omap@vger.kernel.org, linux-kernel@vger.kernel.org,
s.nawrocki@samsung.com, kishon@kernel.org, balbi@ti.com,
tony@atomide.com
Subject: Re: [PATCH v2 3/3] usb: musb: omap2430: report system-resume PHY setup failures
Date: Fri, 20 Nov 2026 15:08:21 +0100 [thread overview]
Message-ID: <2026112013-rubbing-busily-8bfc@gregkh> (raw)
In-Reply-To: <20260922004414.4192-4-hppiscas@163.com>
On Tue, Sep 22, 2026 at 08:44:14AM +0800, Pengpeng Hou wrote:
> omap2430_resume() ignores PHY setup failures and always reports success.
>
> Return the result of the ownership-aware PHY setup helper. End the
> system-sleep deferral even on failure: leaving phy_suspended set would
> make later runtime resumes skip the PHY permanently. The independent
> reference flags still record which resources need cleanup or retry.
>
> A later suspend or platform exit therefore releases only references
> actually held, while a runtime resume can retry setup without adding a
> second initialization reference left over from a failed cleanup.
>
> The issue was found by our static-analysis tool.
>
> Fixes: 68d9f95d6fd5 ("usb: musb: Fix suspend and resume issues for PHYs on I2C and SPI")
> Assisted-by: gpt 5
> Signed-off-by: Pengpeng Hou <hppiscas@163.com>
> ---
> drivers/usb/musb/omap2430.c | 6 ++++--
> 1 file changed, 4 insertions(+), 2 deletions(-)
>
> diff --git a/drivers/usb/musb/omap2430.c b/drivers/usb/musb/omap2430.c
> index 382d6cd4a9e6..951e60906f2c 100644
> --- a/drivers/usb/musb/omap2430.c
> +++ b/drivers/usb/musb/omap2430.c
> @@ -657,14 +657,16 @@ static int omap2430_resume(struct device *dev)
> {
> struct omap2430_glue *glue = dev_get_drvdata(dev);
> struct musb *musb = glue_to_musb(glue);
> + int ret;
>
> if (!musb)
> return 0;
>
> - omap2430_phy_power_on(glue);
> + ret = omap2430_phy_power_on(glue);
> + /* End system-sleep deferral so a later runtime resume can retry. */
Why is this comment needed?
prev parent reply other threads:[~2026-11-20 14:08 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-09-22 0:44 [PATCH v2 0/3] usb: musb: omap2430: handle PHY setup failures across PM Pengpeng Hou
2026-09-22 0:44 ` [PATCH v2 1/3] usb: musb: omap2430: track PHY references and check initial setup Pengpeng Hou
2026-09-22 0:44 ` [PATCH v2 2/3] usb: musb: omap2430: stop runtime resume after PHY setup failure Pengpeng Hou
2026-09-22 0:44 ` [PATCH v2 3/3] usb: musb: omap2430: report system-resume PHY setup failures Pengpeng Hou
2026-11-20 14:08 ` Greg KH [this message]
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=2026112013-rubbing-busily-8bfc@gregkh \
--to=gregkh@linuxfoundation.org \
--cc=b-liu@ti.com \
--cc=balbi@ti.com \
--cc=hppiscas@163.com \
--cc=kishon@kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-omap@vger.kernel.org \
--cc=linux-usb@vger.kernel.org \
--cc=s.nawrocki@samsung.com \
--cc=tony@atomide.com \
/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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.