Thread (27 messages) flat view 27 messages, 5 authors, 2025-09-18

Re: [PATCH v14 02/10] power: reset: reboot-mode: Add device tree node-based registration

From: Shivendra Pratap <hidden>
Date: 2025-09-17 16:29:56
Also in: linux-arm-msm, linux-devicetree, linux-pm, lkml


On 9/17/2025 12:18 AM, Sebastian Reichel wrote:
Hi,

On Fri, Aug 15, 2025 at 08:05:07PM +0530, Shivendra Pratap wrote:
quoted
The reboot-mode driver does not have a strict requirement for
device-based registration. It primarily uses the device's of_node
to read mode-<cmd> properties and the device pointer for logging.

Remove the dependency on struct device and introduce support for
Device Tree (DT) node-based registration. This enables drivers
that are not associated with a struct device to leverage the
reboot-mode framework.

Signed-off-by: Shivendra Pratap <redacted>
---
Please use fwnode instead of device_node, so that the same thing
can be used with non DT setups, if that becomes necessary. Otherwise
LGTM.
To be more clear on this, have one question: the current unmodified
design of reboot-mode is dt based:

struct device_node *np = reboot->dev->of_node;
and then parses the node using for_each_property_of_node(np, prop).

We want to refactor reboot-mode to support non-DT setups by adding
support for fwnode-based approach (struct fwnode_handle *fwnode)?

Can you please explain a bit? Some more details would be helpful to
make the change.

thanks,
Shivendra
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help