summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorKiran Gunda <kgunda@codeaurora.org>2017-11-14 15:24:50 +0530
committerGerrit - the friendly Code Review server <code-review@localhost>2019-02-15 03:16:57 -0800
commit77b03b194ee4680b3af83cd61e77dd101a8a1b91 (patch)
treecf8e12b42680d02c9d59d96abd216a2339fefbe9
parent244c45dfecca189bb1f1f8711d43a5ccea8d247d (diff)
leds: qpnp-flash: Add snapshot of leds-qpnp-flash driver
This is snapshot of the leds-qpnp-flash driver as of msm-4.4 'commit d851b0621739 ("leds: qpnp-flash: Fix Use-after-free(UAF) for debugfs")'. Change-Id: I9753ab4e0fee03a957960003efc2941bc48616ac Signed-off-by: Kiran Gunda <kgunda@codeaurora.org> Signed-off-by: Shilpa Suresh <sbsure@codeaurora.org>
-rw-r--r--Documentation/devicetree/bindings/leds/leds-qpnp-flash.txt6
-rw-r--r--drivers/leds/Kconfig2
-rw-r--r--drivers/leds/leds-qpnp-flash.c2
3 files changed, 5 insertions, 5 deletions
diff --git a/Documentation/devicetree/bindings/leds/leds-qpnp-flash.txt b/Documentation/devicetree/bindings/leds/leds-qpnp-flash.txt
index ed1ddf597016..a7a2eda6c5a7 100644
--- a/Documentation/devicetree/bindings/leds/leds-qpnp-flash.txt
+++ b/Documentation/devicetree/bindings/leds/leds-qpnp-flash.txt
@@ -1,10 +1,10 @@
-Qualcomm Technologies PNP Flash LED
+Qualcomm Technologies Inc. PNP Flash LED
-QPNP (Qualcomm Technologies Plug N Play) Flash LED (Light
+QPNP (Qualcomm Technologies Inc. Plug N Play) Flash LED (Light
Emitting Diode) driver is used to provide illumination to
camera sensor when background light is dim to capture good
picture. It can also be used for flashlight/torch application.
-It is part of PMIC on Qualcomm Technologies reference platforms.
+It is part of PMIC on Qualcomm Technologies Inc. reference platforms.
The PMIC is connected to the host processor via SPMI bus.
Required properties:
diff --git a/drivers/leds/Kconfig b/drivers/leds/Kconfig
index 259dc27e99b6..ab4d40857421 100644
--- a/drivers/leds/Kconfig
+++ b/drivers/leds/Kconfig
@@ -598,7 +598,7 @@ config LEDS_QPNP
config LEDS_QPNP_FLASH
tristate "Support for QPNP Flash LEDs"
- depends on LEDS_CLASS && SPMI
+ depends on LEDS_CLASS && MFD_SPMI_PMIC
help
This driver supports the flash LED functionality of Qualcomm
Technologies, Inc. QPNP PMICs. This driver supports PMICs up through
diff --git a/drivers/leds/leds-qpnp-flash.c b/drivers/leds/leds-qpnp-flash.c
index 493631774936..3b07af86b5c9 100644
--- a/drivers/leds/leds-qpnp-flash.c
+++ b/drivers/leds/leds-qpnp-flash.c
@@ -1269,7 +1269,7 @@ static void qpnp_flash_led_work(struct work_struct *work)
int max_curr_avail_ma = 0;
int total_curr_ma = 0;
int i;
- u8 val;
+ u8 val = 0;
uint temp;
mutex_lock(&led->flash_led_lock);