Re: [PATCH 22/23] reset: rzg2l: use platform_device_set_of_node_from_dev()
From: Philipp Zabel
Date: Tue Jun 02 2026 - 04:27:48 EST
On Do, 2026-05-21 at 10:36 +0200, Bartosz Golaszewski wrote:
> Ahead of reworking the reference counting logic for platform devices,
> encapsulate the assignment of the OF node from another device for
> dynamically allocated platform devices with the provided helper.
>
> Signed-off-by: Bartosz Golaszewski <bartosz.golaszewski@xxxxxxxxxxxxxxxx>
> ---
> drivers/reset/reset-rzg2l-usbphy-ctrl.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/drivers/reset/reset-rzg2l-usbphy-ctrl.c b/drivers/reset/reset-rzg2l-usbphy-ctrl.c
> index fd75d9601a3bfde7b7e3f6db287ec8c5c45a20ab..f003b360629c90bb37ed0ade7a675b5b0f28fa7e 100644
> --- a/drivers/reset/reset-rzg2l-usbphy-ctrl.c
> +++ b/drivers/reset/reset-rzg2l-usbphy-ctrl.c
> @@ -249,7 +249,7 @@ static int rzg2l_usbphy_ctrl_probe(struct platform_device *pdev)
> vdev->dev.parent = dev;
> priv->vdev = vdev;
>
> - device_set_of_node_from_dev(&vdev->dev, dev);
> + platform_device_set_of_node_from_dev(vdev, dev);
> error = platform_device_add(vdev);
> if (error)
> goto err_device_put;
Acked-by: Philipp Zabel <p.zabel@xxxxxxxxxxxxxx>
regards
Philipp