remoteproc: pru: Use rproc_of_parse_firmware() to get firmware name

There is a helper function to get the firmware name, make use of that.

Signed-off-by: Andrew Davis <afd@ti.com>
Link: https://lore.kernel.org/r/20260302202728.322073-1-afd@ti.com
Signed-off-by: Mathieu Poirier <mathieu.poirier@linaro.org>
This commit is contained in:
Andrew Davis
2026-03-02 14:27:27 -06:00
committed by Mathieu Poirier
parent 41c3f9fa52
commit 8f5dea46d0

View File

@@ -1003,11 +1003,9 @@ static int pru_rproc_probe(struct platform_device *pdev)
if (!data)
return -ENODEV;
ret = of_property_read_string(np, "firmware-name", &fw_name);
if (ret) {
dev_err(dev, "unable to retrieve firmware-name %d\n", ret);
return ret;
}
ret = rproc_of_parse_firmware(dev, 0, &fw_name);
if (ret)
return dev_err_probe(dev, ret, "unable to retrieve firmware-name\n");
rproc = devm_rproc_alloc(dev, pdev->name, &pru_rproc_ops, fw_name,
sizeof(*pru));