iio: backend: fix wrong pointer passed to IS_ERR()

It should be fwnode_back passed to IS_ERR().

Fixes: c464cc610f ("iio: add child nodes support in iio backend framework")
Signed-off-by: Yang Yingliang <yangyingliang@huawei.com>
Link: https://patch.msgid.link/20241028135215.1549-1-yangyingliang@huaweicloud.com
Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
This commit is contained in:
Yang Yingliang 2024-10-28 21:52:15 +08:00 committed by Jonathan Cameron
parent ef5f5e7b6f
commit fa40763144

View File

@ -737,8 +737,8 @@ static struct iio_backend *__devm_iio_backend_fwnode_get(struct device *dev, con
}
fwnode_back = fwnode_find_reference(fwnode, "io-backends", index);
if (IS_ERR(fwnode))
return dev_err_cast_probe(dev, fwnode,
if (IS_ERR(fwnode_back))
return dev_err_cast_probe(dev, fwnode_back,
"Cannot get Firmware reference\n");
guard(mutex)(&iio_back_lock);