* [PATCH] iio: backend: fix wrong pointer passed to IS_ERR()
@ 2024-10-28 13:52 Yang Yingliang
2024-10-28 20:36 ` Jonathan Cameron
0 siblings, 1 reply; 2+ messages in thread
From: Yang Yingliang @ 2024-10-28 13:52 UTC (permalink / raw)
To: nuno.sa, olivier.moysan, jic23, lars
Cc: linux-iio, yangyingliang, bobo.shaobowang, Jonathan.Cameron
From: Yang Yingliang <yangyingliang@huawei.com>
It should be fwnode_back passed to IS_ERR().
Fixes: c464cc610f51 ("iio: add child nodes support in iio backend framework")
Signed-off-by: Yang Yingliang <yangyingliang@huawei.com>
---
drivers/iio/industrialio-backend.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/drivers/iio/industrialio-backend.c b/drivers/iio/industrialio-backend.c
index 20b3b5212da7..fb34a8e4d04e 100644
--- a/drivers/iio/industrialio-backend.c
+++ b/drivers/iio/industrialio-backend.c
@@ -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);
--
2.33.0
^ permalink raw reply related [flat|nested] 2+ messages in thread
* Re: [PATCH] iio: backend: fix wrong pointer passed to IS_ERR()
2024-10-28 13:52 [PATCH] iio: backend: fix wrong pointer passed to IS_ERR() Yang Yingliang
@ 2024-10-28 20:36 ` Jonathan Cameron
0 siblings, 0 replies; 2+ messages in thread
From: Jonathan Cameron @ 2024-10-28 20:36 UTC (permalink / raw)
To: Yang Yingliang
Cc: nuno.sa, olivier.moysan, lars, linux-iio, yangyingliang,
bobo.shaobowang, Jonathan.Cameron
On Mon, 28 Oct 2024 21:52:15 +0800
Yang Yingliang <yangyingliang@huaweicloud.com> wrote:
> From: Yang Yingliang <yangyingliang@huawei.com>
>
> It should be fwnode_back passed to IS_ERR().
>
> Fixes: c464cc610f51 ("iio: add child nodes support in iio backend framework")
> Signed-off-by: Yang Yingliang <yangyingliang@huawei.com>
Thanks.
Applied to the fixes-togreg branch of iio.git.
I'm not sure if I'll get another fixes pull out due to some upcoming travel,
but if not I'll queue this up for the merge window instead.
Jonathan
> ---
> drivers/iio/industrialio-backend.c | 4 ++--
> 1 file changed, 2 insertions(+), 2 deletions(-)
>
> diff --git a/drivers/iio/industrialio-backend.c b/drivers/iio/industrialio-backend.c
> index 20b3b5212da7..fb34a8e4d04e 100644
> --- a/drivers/iio/industrialio-backend.c
> +++ b/drivers/iio/industrialio-backend.c
> @@ -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);
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2024-10-28 20:36 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2024-10-28 13:52 [PATCH] iio: backend: fix wrong pointer passed to IS_ERR() Yang Yingliang
2024-10-28 20:36 ` Jonathan Cameron
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox