lkml.org 
[lkml]   [2022]   [Jun]   [10]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH v1 1/1] leds: trigger: gpio: Convert to use kstrtox()
On Thu, Jun 09, 2022 at 07:18:29PM +0300, Andy Shevchenko wrote:
> sscanf() is a heavy one and moreover requires additional boundary checks.
> Convert driver to use kstrtox() and replace kstrtoul() by kstrtobool()
> in gpio_trig_inverted_store().

> While here, check the desired brightness against maximum defined for
> a certain LED.

I realize that this part may be wrong. I have to drop it in the next version.

--
With Best Regards,
Andy Shevchenko


\
 
 \ /
  Last update: 2022-06-10 13:40    [W:0.026 / U:0.168 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site