* [PATCH] iio: adc: ti-ads131e08: return correct error code
@ 2025-10-11 8:11 Dixit Parmar
2025-10-12 16:44 ` Markus Elfring
2025-10-12 19:18 ` Jonathan Cameron
0 siblings, 2 replies; 3+ messages in thread
From: Dixit Parmar @ 2025-10-11 8:11 UTC (permalink / raw)
To: Jonathan Cameron, David Lechner, Nuno Sá, Andy Shevchenko
Cc: linux-iio, linux-kernel, Dixit Parmar
The error code returned from devm_iio_trigger_register() inturn
iio_trigger_register() can be other than -ENOMEM. Hence return the
same value as it was returned from the function call.
This change makes devm_iio_trigger_register() handling uniform with
other iio drivers.
Signed-off-by: Dixit Parmar <dixitparmar19@gmail.com>
---
The error code returned from devm_iio_trigger_register() inturn
iio_trigger_register() can be other than -ENOMEM. Hence return the
same value as it was returned from the function call.
This change makes devm_iio_trigger_register() handling uniform with
other iio drivers.
---
drivers/iio/adc/ti-ads131e08.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/iio/adc/ti-ads131e08.c b/drivers/iio/adc/ti-ads131e08.c
index b18f30d3fdbe..10330d6913df 100644
--- a/drivers/iio/adc/ti-ads131e08.c
+++ b/drivers/iio/adc/ti-ads131e08.c
@@ -852,7 +852,7 @@ static int ads131e08_probe(struct spi_device *spi)
ret = devm_iio_trigger_register(&spi->dev, st->trig);
if (ret) {
dev_err(&spi->dev, "failed to register IIO trigger\n");
- return -ENOMEM;
+ return ret;
}
indio_dev->trig = iio_trigger_get(st->trig);
---
base-commit: 07e27ad16399afcd693be20211b0dfae63e0615f
change-id: 20251011-ret_val-3186236b240f
Best regards,
--
Dixit Parmar <dixitparmar19@gmail.com>
^ permalink raw reply related [flat|nested] 3+ messages in thread
* Re: [PATCH] iio: adc: ti-ads131e08: return correct error code
2025-10-11 8:11 [PATCH] iio: adc: ti-ads131e08: return correct error code Dixit Parmar
@ 2025-10-12 16:44 ` Markus Elfring
2025-10-12 19:18 ` Jonathan Cameron
1 sibling, 0 replies; 3+ messages in thread
From: Markus Elfring @ 2025-10-12 16:44 UTC (permalink / raw)
To: Dixit Parmar, linux-iio, Andy Shevchenko, David Lechner,
Jonathan Cameron, Nuno Sá
Cc: LKML
…
> This change makes …
Will another imperative wording approach become more helpful for an improved
change description?
https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/tree/Documentation/process/submitting-patches.rst?h=v6.17#n94
How do you think about to add any tags (like “Fixes” and “Cc”) accordingly?
https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/tree/Documentation/process/submitting-patches.rst?h=v6.17#n145
Regards,
Markus
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: [PATCH] iio: adc: ti-ads131e08: return correct error code
2025-10-11 8:11 [PATCH] iio: adc: ti-ads131e08: return correct error code Dixit Parmar
2025-10-12 16:44 ` Markus Elfring
@ 2025-10-12 19:18 ` Jonathan Cameron
1 sibling, 0 replies; 3+ messages in thread
From: Jonathan Cameron @ 2025-10-12 19:18 UTC (permalink / raw)
To: Dixit Parmar
Cc: David Lechner, Nuno Sá, Andy Shevchenko, linux-iio,
linux-kernel
On Sat, 11 Oct 2025 13:41:49 +0530
Dixit Parmar <dixitparmar19@gmail.com> wrote:
> The error code returned from devm_iio_trigger_register() inturn
> iio_trigger_register() can be other than -ENOMEM. Hence return the
> same value as it was returned from the function call.
> This change makes devm_iio_trigger_register() handling uniform with
> other iio drivers.
>
> Signed-off-by: Dixit Parmar <dixitparmar19@gmail.com>
Applied
Thanks,
J
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2025-10-12 19:18 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2025-10-11 8:11 [PATCH] iio: adc: ti-ads131e08: return correct error code Dixit Parmar
2025-10-12 16:44 ` Markus Elfring
2025-10-12 19:18 ` Jonathan Cameron
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).