From: sashiko-bot@kernel.org
To: "Shivendra Pratap" <shivendra.pratap@oss.qualcomm.com>
Cc: devicetree@vger.kernel.org, robh@kernel.org, conor+dt@kernel.org
Subject: Re: [PATCH v28 04/10] firmware: arm: psci: Add support for PSCI auxiliary devices
Date: Fri, 27 Nov 2026 15:30:48 +0000 [thread overview]
Message-ID: <sashiko-outbox-237739@kernel.org> (raw)
In-Reply-To: <20261127-arm-psci-system_reset2-vendor-reboots-v28-4-da05a33b08d8@oss.qualcomm.com>
Thank you for your contribution! Sashiko AI review found 1 potential
issue to consider:
- [Medium] firmware: arm: psci: premature fw_devlink pickup in
arm_psci_probe()
--
commit aa59945bb4d8456dbf61f8f8873df33afdc23249
Author: Shivendra Pratap <shivendra.pratap@oss.qualcomm.com>
firmware: arm: psci: Add support for PSCI auxiliary devices
This commit introduces a PSCI platform driver that binds to
"arm,psci-1.0" and registers child devices on the auxiliary bus,
converting cpuidle-psci-domain from a platform driver into an auxiliary
driver.
> diff --git a/drivers/firmware/arm/psci/psci-devices.c b/drivers/firmware/arm/psci/psci-devices.c
> new file mode 100644
> index 0000000000000..d23befc490ed5
> --- /dev/null
> +++ b/drivers/firmware/arm/psci/psci-devices.c
> @@ -0,0 +1,116 @@
[ ... ]
> +static int arm_psci_probe(struct platform_device *pdev)
> +{
> + const struct arm_psci_device_info *info;
> + int auxdev_count = 0;
> + int i, ret;
> +
> + for (i = 0; i < ARRAY_SIZE(arm_psci_devices); i++) {
> + info = &arm_psci_devices[i];
> + ret = arm_psci_auxiliary_device_create(&pdev->dev, info);
> + if (ret)
> + dev_warn(&pdev->dev, "failed to create %s aux device: %d\n",
> + info->name, ret);
> + else
> + auxdev_count++;
> + }
> +
> + return auxdev_count ? 0 : -ENODEV;
> +}
[Severity: Medium]
Can returning 0 here when psci_cpuidle_domain_probe() defers cause
fw_devlink to permanently mark the child power-domain DT nodes as
FWNODE_FLAG_NOT_DEVICE?
When a PSCI child power domain references an external parent power domain
that has not probed yet (such as cluster_pd referencing &mpm on
qcom/sm6375), dt_idle_pd_init_topology() returns -EPROBE_DEFER and
psci_pd_remove() deletes the child genpd devices, leaving their
fwnode->dev pointers NULL while auxdev is placed on the deferred probe
list.
Because device_add(&auxdev->dev) still returns 0, arm_psci_probe()
succeeds on the parent arm,psci-1.0 platform device. driver_bound() then
runs device_links_driver_bound(&pdev->dev) ->
fw_devlink_pickup_dangling_consumers(&pdev->dev):
drivers/base/core.c:__fw_devlink_pickup_dangling_consumers() {
...
if (fwnode->dev && fwnode->dev->bus)
return;
fwnode_set_flag(fwnode, FWNODE_FLAG_NOT_DEVICE);
__fwnode_links_move_consumers(fwnode, new_sup);
...
}
Previously, psci_cpuidle_domain_driver bound directly to the platform
device, so -EPROBE_DEFER prevented driver_bound(&pdev->dev) from running
until the topology was initialized. With this regression, the child
power-domain fwnodes are permanently flagged FWNODE_FLAG_NOT_DEVICE and
their consumer fwnode_links are moved to the already-bound parent pdev,
unblocking consumers before the PM domains exist and leaving the child
genpd devices without consumer device links to hold off sync_state once
psci_cpuidle_domain_probe() later retries.
--
Sashiko AI review · https://sashiko.dev/#/patchset/20261127-arm-psci-system_reset2-vendor-reboots-v28-0-da05a33b08d8@oss.qualcomm.com?part=4
next prev parent reply other threads:[~2026-11-27 15:30 UTC|newest]
Thread overview: 13+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-11-27 14:26 [PATCH v28 00/10] Implement PSCI reboot mode driver for PSCI resets Shivendra Pratap
2026-11-27 14:26 ` [PATCH v28 01/10] power: reset: reboot-mode: Support up to 3 magic values per mode Shivendra Pratap
2026-11-27 14:26 ` [PATCH v28 02/10] power: reset: reboot-mode: Add support for predefined reboot modes Shivendra Pratap
2026-11-27 14:50 ` sashiko-bot
2026-11-27 14:26 ` [PATCH v28 03/10] firmware: psci: Introduce command-based resets Shivendra Pratap
2026-11-27 14:26 ` [PATCH v28 04/10] firmware: arm: psci: Add support for PSCI auxiliary devices Shivendra Pratap
2026-11-27 15:30 ` sashiko-bot [this message]
2026-11-27 14:26 ` [PATCH v28 05/10] dt-bindings: arm: Document reboot mode magic Shivendra Pratap
2026-11-27 14:26 ` [PATCH v28 06/10] power: reset: Add psci-reboot-mode driver Shivendra Pratap
2026-11-27 14:27 ` [PATCH v28 07/10] arm64: dts: qcom: Add psci reboot-modes for kodiak boards Shivendra Pratap
2026-11-27 14:27 ` [PATCH v28 08/10] arm64: dts: qcom: Add psci reboot-modes for lemans boards Shivendra Pratap
2026-11-27 14:27 ` [PATCH v28 09/10] arm64: dts: qcom: Add psci reboot-modes for monaco boards Shivendra Pratap
2026-11-27 14:27 ` [PATCH v28 10/10] arm64: dts: qcom: Add psci reboot-modes for talos boards Shivendra Pratap
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=sashiko-outbox-237739@kernel.org \
--to=sashiko-bot@kernel.org \
--cc=conor+dt@kernel.org \
--cc=devicetree@vger.kernel.org \
--cc=robh@kernel.org \
--cc=sashiko-reviews@lists.linux.dev \
--cc=shivendra.pratap@oss.qualcomm.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