-
Notifications
You must be signed in to change notification settings - Fork 7k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
drivers: led: lp50xx: check the number of LED colors
The current code assumes (especially in the lp50xx_set_color function) that the number of LED colors defined in DT is not greater than 3. But since this is not checked, then this is not necessarily the case... This patch consolidates the initialization of the lp50xx LED driver by checking the number of colors for each LED found in DT. Signed-off-by: Simon Guinot <simon.guinot@sequanux.org> (cherry picked from commit ffbb8f9)
- Loading branch information
1 parent
546386c
commit af81a8b
Showing
1 changed file
with
18 additions
and
5 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters