Re: [PATCH v2] regulator: as3722: use the platform OF node setter

From: Mark Brown

Date: Sat Nov 07 2026 - 11:25:08 EST


> Use platform_device_set_of_node() to synchronize both fields and
> give the device its own reference. Use __free(device_node) to release

> static int as3722_get_regulator_dt_data(struct platform_device *pdev,
> struct as3722_regulators *as3722_regs)
> {

> - pdev->dev.of_node = np;
> + platform_device_set_of_node(pdev, np);

Are you sure this is safe to use during probe(), which must of necessity
happen after platform_device_add()? In particular with the interactions
with fw_devlink.

--
Mark Brown <broonie@xxxxxxxxxx>