linux-leds.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Heiner Kallweit <hkallweit1@gmail.com>
To: Jacek Anaszewski <j.anaszewski@samsung.com>
Cc: linux-leds@vger.kernel.org
Subject: Re: [PATCH] led: core: fix misleading comment after workqueue removal from drivers
Date: Thu, 21 Jan 2016 10:50:30 +0100	[thread overview]
Message-ID: <CAFSsGVv-7dmjoo2kShhEMXi-597gsPXuKeV1x8Va9zzoYj4A-Q@mail.gmail.com> (raw)
In-Reply-To: <56A09EC8.1080807@samsung.com>

On Thu, Jan 21, 2016 at 10:03 AM, Jacek Anaszewski
<j.anaszewski@samsung.com> wrote:
> Hi Heiner,
>
> On 01/10/2016 06:16 PM, Heiner Kallweit wrote:
>>
>> Now that workqueues have been removed from individual drivers and
>> were replaced with a core-internal workqueue we shouldn't
>> encourage people to add new workqueues to drivers.
>>
>> Signed-off-by: Heiner Kallweit <hkallweit1@gmail.com>
>> ---
>>   include/linux/leds.h | 5 ++++-
>>   1 file changed, 4 insertions(+), 1 deletion(-)
>>
>> diff --git a/include/linux/leds.h b/include/linux/leds.h
>> index bc1476f..4429887 100644
>> --- a/include/linux/leds.h
>> +++ b/include/linux/leds.h
>> @@ -50,7 +50,10 @@ struct led_classdev {
>>   #define LED_DEV_CAP_FLASH     (1 << 23)
>>
>>         /* Set LED brightness level */
>> -       /* Must not sleep, use a workqueue if needed */
>> +       /* Must not sleep. If no non-blocking version can be provided
>> +        * set brightness_set_blocking only. The LED core will use an
>> +        * internal work queue to create a non-blocking version.
>> +        */
>
>
> This comment isn't easily comprehensible at first glance.
>
> How about:
>
> "Must not sleep. Use brightness_set_blocking for drivers
> that can sleep while setting brightness."
>
Yes, this is better. It's simpler and clearer.
Are you going to fix the comment on your own or would you like me
to submit it as a patch?

Regards, Heiner

>>         void            (*brightness_set)(struct led_classdev *led_cdev,
>>                                           enum led_brightness brightness);
>>         /*
>>
>
>
> --
> Best Regards,
> Jacek Anaszewski

  reply	other threads:[~2016-01-21  9:50 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-01-10 17:16 [PATCH] led: core: fix misleading comment after workqueue removal from drivers Heiner Kallweit
2016-01-21  9:03 ` Jacek Anaszewski
2016-01-21  9:50   ` Heiner Kallweit [this message]
2016-01-21 11:05     ` Jacek Anaszewski

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=CAFSsGVv-7dmjoo2kShhEMXi-597gsPXuKeV1x8Va9zzoYj4A-Q@mail.gmail.com \
    --to=hkallweit1@gmail.com \
    --cc=j.anaszewski@samsung.com \
    --cc=linux-leds@vger.kernel.org \
    /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).