# Re: \[PATCH 19/23\] platform/surface: gpe: use platform\_device\_set\_fwnode()

- From: Ilpo Järvinen \<ilpo.jarvinen@linux.intel.com\>
- Date: 2026-05-28 11:21:36 
- List: linuxppc-dev
- Page: https://ratatoskr.run/linuxppc-dev/2026/05/17041350
- Thread: https://ratatoskr.run/netdev/2026/05/17013086/t.md

```text
On Thu, 21 May 2026, Bartosz Golaszewski wrote:

> Ahead of reworking the reference counting logic for platform devices,
> encapsulate the assignment of the firmware node for dynamically allocated
> platform devices with the provided helper.
> 
> Signed-off-by: Bartosz Golaszewski <redacted>
> ---
>  drivers/platform/surface/surface_gpe.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/drivers/platform/surface/surface_gpe.c b/drivers/platform/surface/surface_gpe.c
> index b359413903b13c4f8e8b284ef7ae6f6db3f47d72..40896a8544b0a4da4261ea881b1eaed62d93b32b 100644
> --- a/drivers/platform/surface/surface_gpe.c
> +++ b/drivers/platform/surface/surface_gpe.c
> @@ -317,7 +317,7 @@ static int __init surface_gpe_init(void)
>  		goto err_alloc;
>  	}
>  
> -	pdev->dev.fwnode = fwnode;
> +	platform_device_set_fwnode(pdev, fwnode);
>  
>  	status = platform_device_add(pdev);
>  	if (status)
> 
> 

Acked-by: Ilpo Järvinen <ilpo.jarvinen@linux.intel.com>

-- 
 i.
```
