All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH 1/1] leds: as3645a: Fix error return code in as3645a_parse_node()
@ 2021-05-15  3:06 Zhen Lei
  2021-05-25 16:42 ` Sakari Ailus
  2021-06-23 20:15 ` Pavel Machek
  0 siblings, 2 replies; 3+ messages in thread
From: Zhen Lei @ 2021-05-15  3:06 UTC (permalink / raw)
  To: Sakari Ailus, Pavel Machek, Mauro Carvalho Chehab,
	Jacek Anaszewski, linux-leds
  Cc: Zhen Lei

Return error code -ENODEV rather than '0' when the indicator node can not
be found.

Fixes: a56ba8fbcb55 ("media: leds: as3645a: Add LED flash class driver")
Reported-by: Hulk Robot <hulkci@huawei.com>
Signed-off-by: Zhen Lei <thunder.leizhen@huawei.com>
---
 drivers/leds/leds-as3645a.c | 1 +
 1 file changed, 1 insertion(+)

diff --git a/drivers/leds/leds-as3645a.c b/drivers/leds/leds-as3645a.c
index e8922fa03379620..80411d41e802d46 100644
--- a/drivers/leds/leds-as3645a.c
+++ b/drivers/leds/leds-as3645a.c
@@ -545,6 +545,7 @@ static int as3645a_parse_node(struct as3645a *flash,
 	if (!flash->indicator_node) {
 		dev_warn(&flash->client->dev,
 			 "can't find indicator node\n");
+		rval = -ENODEV;
 		goto out_err;
 	}
 
-- 
2.26.0.106.g9fadedd



^ permalink raw reply related	[flat|nested] 3+ messages in thread

* Re: [PATCH 1/1] leds: as3645a: Fix error return code in as3645a_parse_node()
  2021-05-15  3:06 [PATCH 1/1] leds: as3645a: Fix error return code in as3645a_parse_node() Zhen Lei
@ 2021-05-25 16:42 ` Sakari Ailus
  2021-06-23 20:15 ` Pavel Machek
  1 sibling, 0 replies; 3+ messages in thread
From: Sakari Ailus @ 2021-05-25 16:42 UTC (permalink / raw)
  To: Zhen Lei
  Cc: Pavel Machek, Mauro Carvalho Chehab, Jacek Anaszewski, linux-leds

On Sat, May 15, 2021 at 11:06:46AM +0800, Zhen Lei wrote:
> Return error code -ENODEV rather than '0' when the indicator node can not
> be found.
> 
> Fixes: a56ba8fbcb55 ("media: leds: as3645a: Add LED flash class driver")
> Reported-by: Hulk Robot <hulkci@huawei.com>
> Signed-off-by: Zhen Lei <thunder.leizhen@huawei.com>

Acked-by: Sakari Ailus <sakari.ailus@linux.intel.com>

-- 
Sakari Ailus

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: [PATCH 1/1] leds: as3645a: Fix error return code in as3645a_parse_node()
  2021-05-15  3:06 [PATCH 1/1] leds: as3645a: Fix error return code in as3645a_parse_node() Zhen Lei
  2021-05-25 16:42 ` Sakari Ailus
@ 2021-06-23 20:15 ` Pavel Machek
  1 sibling, 0 replies; 3+ messages in thread
From: Pavel Machek @ 2021-06-23 20:15 UTC (permalink / raw)
  To: Zhen Lei
  Cc: Sakari Ailus, Mauro Carvalho Chehab, Jacek Anaszewski, linux-leds

[-- Attachment #1: Type: text/plain, Size: 399 bytes --]

On Sat 2021-05-15 11:06:46, Zhen Lei wrote:
> Return error code -ENODEV rather than '0' when the indicator node can not
> be found.
> 
> Fixes: a56ba8fbcb55 ("media: leds: as3645a: Add LED flash class driver")
> Reported-by: Hulk Robot <hulkci@huawei.com>
> Signed-off-by: Zhen Lei <thunder.leizhen@huawei.com>

Thanks, applied.
								Pavel
-- 
http://www.livejournal.com/~pavelmachek

[-- Attachment #2: Digital signature --]
[-- Type: application/pgp-signature, Size: 181 bytes --]

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2021-06-23 20:15 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-05-15  3:06 [PATCH 1/1] leds: as3645a: Fix error return code in as3645a_parse_node() Zhen Lei
2021-05-25 16:42 ` Sakari Ailus
2021-06-23 20:15 ` Pavel Machek

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.