linux-leds.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Dan Murphy <dmurphy@ti.com>
To: "Marek Behún" <marek.behun@nic.cz>, "Pavel Machek" <pavel@ucw.cz>
Cc: <linux-leds@vger.kernel.org>, <jacek.anaszewski@gmail.com>
Subject: Re: [PATCH v7 2/3] leds: initial support for Turris Omnia LEDs
Date: Fri, 24 Jul 2020 09:56:01 -0500	[thread overview]
Message-ID: <05728170-2cbd-5f5d-e245-c80e24896c0d@ti.com> (raw)
In-Reply-To: <20200724140829.74167055@dellmb.labs.office.nic.cz>

Marek

On 7/24/20 7:08 AM, Marek Behún wrote:
> On Fri, 24 Jul 2020 12:58:25 +0200
> Pavel Machek <pavel@ucw.cz> wrote:
>
>> Hi!
>>
>>> This adds basic support for LEDs on the front side of CZ.NIC's
>>> Turris Omnia router.
>>>
>>> There are 12 RGB LEDs. The controller supports HW triggering mode
>>> for the LEDs, but this driver does not support it yet, and sets all
>>> the LEDs defined in device-tree into SW mode upon probe.
>>>
>>> This driver uses the multicolor LED framework.
>>>
>>> Signed-off-by: Marek Behún <marek.behun@nic.cz>
>>> Reviewed-by: Dan Murphy <dmurphy@ti.com>
>>> ---
>>>   drivers/leds/Kconfig             |  11 ++
>>>   drivers/leds/Makefile            |   1 +
>>>   drivers/leds/leds-turris-omnia.c | 295
>>> +++++++++++++++++++++++++++++++ 3 files changed, 307 insertions(+)
>>>   create mode 100644 drivers/leds/leds-turris-omnia.c
>> Whoever told you to use defines here was evil:
> I think it was that way when it was first proposed, sometime last year,
> but Dan complained about magic numbers, so I changed it to macros :D

Ah yes I did make a comment about magic numbers but did not explicitly 
ask for macros, enum would have sufficed and

I was more concerned about the buffer length being consistent in the 
file since it was hard coded twice in two different functions.

So I am only partially evil.

Dan



  reply	other threads:[~2020-07-24 14:56 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-07-23 12:53 [PATCH v7 0/3] Add Turris Omnia LEDs driver Marek Behún
2020-07-23 12:53 ` [PATCH v7 1/3] dt-bindings: leds: add cznic,turris-omnia-leds binding Marek Behún
2020-07-28 17:49   ` Rob Herring
2020-07-23 12:53 ` [PATCH v7 2/3] leds: initial support for Turris Omnia LEDs Marek Behún
2020-07-24 10:58   ` Pavel Machek
2020-07-24 12:08     ` Marek Behún
2020-07-24 14:56       ` Dan Murphy [this message]
2020-07-23 12:53 ` [PATCH v7 3/3] Documentation: ABI: leds-turris-omnia: document sysfs attribute Marek Behún

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=05728170-2cbd-5f5d-e245-c80e24896c0d@ti.com \
    --to=dmurphy@ti.com \
    --cc=jacek.anaszewski@gmail.com \
    --cc=linux-leds@vger.kernel.org \
    --cc=marek.behun@nic.cz \
    --cc=pavel@ucw.cz \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
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).