summaryrefslogtreecommitdiff
path: root/common/cmd_led.c
diff options
context:
space:
mode:
authorOtavio Salvador <otavio@ossystems.com.br>2013-02-23 02:43:07 +0000
committerStefano Babic <sbabic@denx.de>2013-03-07 17:22:57 +0100
commitaf73034c6ba131a93ed215098f43595637ef6ac3 (patch)
tree72e41ca439d2733d4f3361968f92d7b4a0ea6070 /common/cmd_led.c
parent920178d38133e76da8b0394b0d3f088e7afbaee7 (diff)
led: Use STATUS_LED_ON and STATUS_LED_OFF when calling __led_set
This fixes the gpio_led driver which needs to compare againt a STATUS_LED_ON to enable a led. Signed-off-by: Otavio Salvador <otavio@ossystems.com.br>
Diffstat (limited to 'common/cmd_led.c')
-rw-r--r--common/cmd_led.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/common/cmd_led.c b/common/cmd_led.c
index 7f5ab43c7f..84f79fae00 100644
--- a/common/cmd_led.c
+++ b/common/cmd_led.c
@@ -110,13 +110,15 @@ int do_led (cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[])
if (led_commands[i].on)
led_commands[i].on();
else
- __led_set(led_commands[i].mask, 1);
+ __led_set(led_commands[i].mask,
+ STATUS_LED_ON);
break;
case LED_OFF:
if (led_commands[i].off)
led_commands[i].off();
else
- __led_set(led_commands[i].mask, 0);
+ __led_set(led_commands[i].mask,
+ STATUS_LED_OFF);
break;
case LED_TOGGLE:
if (led_commands[i].toggle)