From: sashiko-bot@kernel.org
To: "Xu Yang" <xu.yang_2@oss.nxp.com>
Cc: olteanv@gmail.com, vkoul@kernel.org, Frank.Li@kernel.org,
linux-phy@lists.infradead.org, imx@lists.linux.dev,
neil.armstrong@linaro.org
Subject: Re: [PATCH v6 6/6] phy: fsl-imx8mq-usb: keep PHY power domain runtime always-on for i.MX8MP
Date: Wed, 15 Jul 2026 11:44:05 +0000 [thread overview]
Message-ID: <20260715114405.CEA621F000E9@smtp.kernel.org> (raw)
In-Reply-To: <20260715-imx8mp-usb-phy-improvement-v6-6-00d95e270e4c@nxp.com>
Thank you for your contribution! Sashiko AI review found 1 potential issue(s) to consider:
- [High] The driver unconditionally fails probe if dev_pm_genpd_rpm_always_on() returns an error. This breaks backward compatibility on configurations without generic power domains or when the device tree lacks a power-domains property.
--
--- Patch [6]: [PATCH v6 6/6] phy: fsl-imx8mq-usb: keep PHY power domain runtime always-on for i.MX8MP ---
commit 14514f8e33060037a734acad2199e7febc56def8
Author: Xu Yang <xu.yang_2@nxp.com>
Subject: phy: fsl-imx8mq-usb: keep PHY power domain runtime always-on for i.MX8MP
This commit marks the PHY power domain as runtime always-on for the i.MX8MP
platform to prevent it from being powered off during runtime suspend. This is
intended to preserve USB wakeup functionality on i.MX8MP.
> diff --git a/drivers/phy/freescale/phy-fsl-imx8mq-usb.c b/drivers/phy/freescale/phy-fsl-imx8mq-usb.c
> --- a/drivers/phy/freescale/phy-fsl-imx8mq-usb.c
> +++ b/drivers/phy/freescale/phy-fsl-imx8mq-usb.c
[ ... ]
> @@ -739,6 +742,12 @@ static int imx8mq_usb_phy_probe(struct platform_device *pdev)
> if (!phy_data)
> return -EINVAL;
>
> + if (phy_data->need_genpd_rpm_on) {
> + ret = dev_pm_genpd_rpm_always_on(dev, true);
> + if (ret)
> + return dev_err_probe(dev, ret, "failed to set genpd rpm always on\n");
[Severity: High]
Does this code cause probe to fail unnecessarily when generic power domains
are disabled or not configured in the device tree?
If the kernel is compiled without CONFIG_PM_GENERIC_DOMAINS,
dev_pm_genpd_rpm_always_on() will return -EOPNOTSUPP. Similarly, if the
device tree lacks a 'power-domains' property for the PHY node, it may return
-ENODEV.
Since the power domain won't be runtime-suspended by the generic power domain
framework in these cases, the wakeup issue this patch intends to fix doesn't
exist.
Should this check ignore non-fatal errors like -EOPNOTSUPP and -ENODEV to
preserve backward compatibility with older device trees and minimal kernel
configurations?
> + }
> +
> imx_phy->phy = devm_phy_create(dev, NULL, phy_data->ops);
> if (IS_ERR(imx_phy->phy))
> return PTR_ERR(imx_phy->phy);
--
Sashiko AI review · https://sashiko.dev/#/patchset/20260715-imx8mp-usb-phy-improvement-v6-0-00d95e270e4c@nxp.com?part=6
next prev parent reply other threads:[~2026-07-15 11:44 UTC|newest]
Thread overview: 13+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-07-15 11:33 [PATCH v6 0/6] phy: fsl-imx8mq-usb: few improvements Xu Yang
2026-07-15 11:33 ` [PATCH v6 1/6] phy: fsl-imx8mq-usb: fix typec switch leak on probe error path Xu Yang
2026-07-15 11:46 ` sashiko-bot
2026-07-15 11:33 ` [PATCH v6 2/6] phy: fsl-imx8mq-usb: set usb phy to be wakeup capable Xu Yang
2026-07-15 11:33 ` [PATCH v6 3/6] phy: fsl-imx8mq-usb: add runtime PM support Xu Yang
2026-07-15 11:52 ` sashiko-bot
2026-07-15 15:28 ` Frank Li
2026-07-15 11:33 ` [PATCH v6 4/6] phy: fsl-imx8mq-usb: add control register regmap Xu Yang
2026-07-15 11:34 ` [PATCH v6 5/6] phy: fsl-imx8mq-usb: introduce per-variant driver data structure Xu Yang
2026-07-15 15:29 ` Frank Li
2026-07-15 11:34 ` [PATCH v6 6/6] phy: fsl-imx8mq-usb: keep PHY power domain runtime always-on for i.MX8MP Xu Yang
2026-07-15 11:44 ` sashiko-bot [this message]
2026-07-15 15:32 ` Frank Li
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=20260715114405.CEA621F000E9@smtp.kernel.org \
--to=sashiko-bot@kernel.org \
--cc=Frank.Li@kernel.org \
--cc=imx@lists.linux.dev \
--cc=linux-phy@lists.infradead.org \
--cc=neil.armstrong@linaro.org \
--cc=olteanv@gmail.com \
--cc=sashiko-reviews@lists.linux.dev \
--cc=vkoul@kernel.org \
--cc=xu.yang_2@oss.nxp.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox