History

backlight: lm3630a: Add firmware node support

Add fwnode support to the lm3630a driver and optionally allow configuring the label, default brightness level, and maximum brightness level. The two outputs can be controlled by bank A and B independently or bank A can control both outputs. If the platform data was not configured, then the driver defaults to enabling both banks. This patch changes the default value to disable both banks before parsing the firmware node so that just a single bank can be enabled if desired. There are no in-tree users of this driver. Driver was tested on a LG Nexus 5 (hammerhead) phone.

Brian Masney committed 7 years ago

Commit 8fbce8e1 parent 32fcb752 files · +148 −5Browse files

Showing the changes to include/linux (1 of 2 files). Show all

Unified · Split

include/linux/platform_data/lm3630a_bl.h+4−0
@@ -38,9 +38,11 @@ enum lm3630a_ledb_ctrl { · 37 unmodified lines
3838
3939 #define LM3630A_MAX_BRIGHTNESS 255
4040 /*
41+ *@leda_label : optional led a label.
4142 *@leda_init_brt : led a init brightness. 4~255
4243 *@leda_max_brt : led a max brightness. 4~255
4344 *@leda_ctrl : led a disable, enable linear, enable exponential
45+ *@ledb_label : optional led b label.
4446 *@ledb_init_brt : led b init brightness. 4~255
4547 *@ledb_max_brt : led b max brightness. 4~255
4648 *@ledb_ctrl : led b disable, enable linear, enable exponential
@@ -50,10 +52,12 @@ enum lm3630a_ledb_ctrl { · 3 unmodified lines
5052 struct lm3630a_platform_data {
5153
5254 /* led a config. */
55+ const char *leda_label;
5356 int leda_init_brt;
5457 int leda_max_brt;
5558 enum lm3630a_leda_ctrl leda_ctrl;
5659 /* led b config. */
60+ const char *ledb_label;
5761 int ledb_init_brt;
5862 int ledb_max_brt;
5963 enum lm3630a_ledb_ctrl ledb_ctrl;

Keyboard shortcuts

General

Show keyboard shortcuts
?
Focus the current search
/

Issues and pull requests

Open filters
f

Issues, pull requests and Inbox

Select next item
j↓
Select previous item
k↑
Open selected item
Enter
Dismiss filters or clear selection
Esc

Repository code

Go to file
t