aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--drivers/leds/leds-lp5521.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/leds/leds-lp5521.c b/drivers/leds/leds-lp5521.c
index 0415b9e6d77..e5071b185fd 100644
--- a/drivers/leds/leds-lp5521.c
+++ b/drivers/leds/leds-lp5521.c
@@ -144,7 +144,7 @@ static ssize_t set_mode(struct device *dev, struct device_attribute *attr,
mask = (0x3 << (id * 2));
- for (i = LP5521_REG_OP_MODE; i <= LP5521_MODE_DIRECT; i++) {
+ for (i = LP5521_MODE_DISABLE; i <= LP5521_MODE_DIRECT; i++) {
if (!strncmp(buf, lp5521_ch_mode[i], strlen(lp5521_ch_mode[i]))) {
reg_set_bit_mask(lp,
LP5521_REG_OP_MODE, mask, (i << (id * 2)));