linux-leds.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] leds: blinkm: clean up double assignment to data->i2c_addr
@ 2019-03-30 20:37 Colin King
  2019-03-31  7:18 ` Mukesh Ojha
                   ` (2 more replies)
  0 siblings, 3 replies; 4+ messages in thread
From: Colin King @ 2019-03-30 20:37 UTC (permalink / raw)
  To: Jan-Simon Moeller, Jacek Anaszewski, Pavel Machek, linux-leds
  Cc: kernel-janitors, linux-kernel

From: Colin Ian King <colin.king@canonical.com>

Currently data->i2c_addr is being assigned twice, first with the
value 0x09 and then immediately afterwards with the value 0x08.
The first assignment is redundant and can be removed.

Signed-off-by: Colin Ian King <colin.king@canonical.com>
---
 drivers/leds/leds-blinkm.c | 1 -
 1 file changed, 1 deletion(-)

diff --git a/drivers/leds/leds-blinkm.c b/drivers/leds/leds-blinkm.c
index 851c1920b63c..11b771fb933b 100644
--- a/drivers/leds/leds-blinkm.c
+++ b/drivers/leds/leds-blinkm.c
@@ -594,7 +594,6 @@ static int blinkm_probe(struct i2c_client *client,
 		goto exit;
 	}
 
-	data->i2c_addr = 0x09;
 	data->i2c_addr = 0x08;
 	/* i2c addr  - use fake addr of 0x08 initially (real is 0x09) */
 	data->fw_ver = 0xfe;
-- 
2.20.1

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

* Re: [PATCH] leds: blinkm: clean up double assignment to data->i2c_addr
  2019-03-30 20:37 [PATCH] leds: blinkm: clean up double assignment to data->i2c_addr Colin King
@ 2019-03-31  7:18 ` Mukesh Ojha
  2019-03-31 18:38 ` Pavel Machek
  2019-04-02 19:05 ` Jacek Anaszewski
  2 siblings, 0 replies; 4+ messages in thread
From: Mukesh Ojha @ 2019-03-31  7:18 UTC (permalink / raw)
  To: Colin King, Jan-Simon Moeller, Jacek Anaszewski, Pavel Machek,
	linux-leds
  Cc: kernel-janitors, linux-kernel

On 3/31/2019 2:07 AM, Colin King wrote:
> From: Colin Ian King <colin.king@canonical.com>
>
> Currently data->i2c_addr is being assigned twice, first with the
> value 0x09 and then immediately afterwards with the value 0x08.
> The first assignment is redundant and can be removed.
>
> Signed-off-by: Colin Ian King <colin.king@canonical.com>
Reviewed-by: Mukesh Ojha <mojha@codeaurora.org>

Cheers,
-Mukesh
> ---
>   drivers/leds/leds-blinkm.c | 1 -
>   1 file changed, 1 deletion(-)
>
> diff --git a/drivers/leds/leds-blinkm.c b/drivers/leds/leds-blinkm.c
> index 851c1920b63c..11b771fb933b 100644
> --- a/drivers/leds/leds-blinkm.c
> +++ b/drivers/leds/leds-blinkm.c
> @@ -594,7 +594,6 @@ static int blinkm_probe(struct i2c_client *client,
>   		goto exit;
>   	}
>   
> -	data->i2c_addr = 0x09;
>   	data->i2c_addr = 0x08;
>   	/* i2c addr  - use fake addr of 0x08 initially (real is 0x09) */
>   	data->fw_ver = 0xfe;

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

* Re: [PATCH] leds: blinkm: clean up double assignment to data->i2c_addr
  2019-03-30 20:37 [PATCH] leds: blinkm: clean up double assignment to data->i2c_addr Colin King
  2019-03-31  7:18 ` Mukesh Ojha
@ 2019-03-31 18:38 ` Pavel Machek
  2019-04-02 19:05 ` Jacek Anaszewski
  2 siblings, 0 replies; 4+ messages in thread
From: Pavel Machek @ 2019-03-31 18:38 UTC (permalink / raw)
  To: Colin King
  Cc: Jan-Simon Moeller, Jacek Anaszewski, linux-leds, kernel-janitors,
	linux-kernel

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

On Sat 2019-03-30 20:37:57, Colin King wrote:
> From: Colin Ian King <colin.king@canonical.com>
> 
> Currently data->i2c_addr is being assigned twice, first with the
> value 0x09 and then immediately afterwards with the value 0x08.
> The first assignment is redundant and can be removed.
> 
> Signed-off-by: Colin Ian King <colin.king@canonical.com>

Acked-by: Pavel Machek <pavel@ucw.cz>

-- 
(english) http://www.livejournal.com/~pavelmachek
(cesky, pictures) http://atrey.karlin.mff.cuni.cz/~pavel/picture/horses/blog.html

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

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

* Re: [PATCH] leds: blinkm: clean up double assignment to data->i2c_addr
  2019-03-30 20:37 [PATCH] leds: blinkm: clean up double assignment to data->i2c_addr Colin King
  2019-03-31  7:18 ` Mukesh Ojha
  2019-03-31 18:38 ` Pavel Machek
@ 2019-04-02 19:05 ` Jacek Anaszewski
  2 siblings, 0 replies; 4+ messages in thread
From: Jacek Anaszewski @ 2019-04-02 19:05 UTC (permalink / raw)
  To: Colin King
  Cc: Jan-Simon Moeller, Pavel Machek, linux-leds, kernel-janitors,
	linux-kernel

Hi Colin,

Thank you for the patch.

On 3/30/19 9:37 PM, Colin King wrote:
> From: Colin Ian King <colin.king@canonical.com>
> 
> Currently data->i2c_addr is being assigned twice, first with the
> value 0x09 and then immediately afterwards with the value 0x08.
> The first assignment is redundant and can be removed.
> 
> Signed-off-by: Colin Ian King <colin.king@canonical.com>
> ---
>   drivers/leds/leds-blinkm.c | 1 -
>   1 file changed, 1 deletion(-)
> 
> diff --git a/drivers/leds/leds-blinkm.c b/drivers/leds/leds-blinkm.c
> index 851c1920b63c..11b771fb933b 100644
> --- a/drivers/leds/leds-blinkm.c
> +++ b/drivers/leds/leds-blinkm.c
> @@ -594,7 +594,6 @@ static int blinkm_probe(struct i2c_client *client,
>   		goto exit;
>   	}
>   
> -	data->i2c_addr = 0x09;
>   	data->i2c_addr = 0x08;
>   	/* i2c addr  - use fake addr of 0x08 initially (real is 0x09) */
>   	data->fw_ver = 0xfe;
> 

Applied.

-- 
Best regards,
Jacek Anaszewski

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

end of thread, other threads:[~2019-04-02 19:05 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2019-03-30 20:37 [PATCH] leds: blinkm: clean up double assignment to data->i2c_addr Colin King
2019-03-31  7:18 ` Mukesh Ojha
2019-03-31 18:38 ` Pavel Machek
2019-04-02 19:05 ` Jacek Anaszewski

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).