lkml.org 
[lkml]   [2020]   [Oct]   [29]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH v7 4/6] drivers: leds: Add the IEI WT61P803 PUZZLE LED driver
Hi!

> Add support for the IEI WT61P803 PUZZLE LED driver.
> Currently only the front panel power LED is supported,
> since it is the only LED on this board wired through the
> MCU.
>
> The LED is wired directly to the on-board MCU controller
> and is toggled using an MCU command.
>
> Support for more LEDs is going to be added in case more
> boards implement this microcontroller, as LEDs use many
> different GPIOs.

Not too bad.

> This driver depends on the IEI WT61P803 PUZZLE MFD driver.
>
> Signed-off-by: Luka Kovacic <luka.kovacic@sartura.hr>
> Cc: Luka Perkov <luka.perkov@sartura.hr>
> Cc: Robert Marko <robert.marko@sartura.hr>
> ---
> drivers/leds/Kconfig | 8 ++
> drivers/leds/Makefile | 1 +
> drivers/leds/leds-iei-wt61p803-puzzle.c | 161 ++++++++++++++++++++++++
> 3 files changed, 170 insertions(+)

Can you put it into drivers/leds/simple? You'll have to create it.

> +++ b/drivers/leds/leds-iei-wt61p803-puzzle.c
> @@ -0,0 +1,161 @@
> +// SPDX-License-Identifier: GPL-2.0-only

Make sure this is consistent with MODULE_LICENSE("GPL");. GPLv2+ would
be nicer if you can.

> + struct mutex lock;

Mutex is _way_ overkill for this. Please check that locking provided
by LED core is not sufficient. If not, please use atomic_t or
something.

Best regards,
Pavel
--
http://www.livejournal.com/~pavelmachek
[unhandled content-type:application/pgp-signature]
\
 
 \ /
  Last update: 2020-10-29 18:59    [W:0.238 / U:0.276 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site