diff options
author | Helmut Schaa <helmut.schaa@googlemail.com> | 2009-02-14 16:22:39 +0100 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@suse.de> | 2009-03-16 17:52:57 -0700 |
commit | b4604897bc55cc5caffee43cc62e1da174b9e3e4 (patch) | |
tree | 3e2ff963d2e428fae1dcc56e5b7c1f33c0d91657 | |
parent | 3599c9c24e57eba1427c604e4a7ae3b0864affda (diff) |
sdhci: fix led naming
commit 5dbace0c9ba110c1a3810a89fa6bf12b7574b5a3 upstream.
Fix the led device naming for the sdhci driver.
The led class documentation defines the led name to have the
form "devicename:colour:function" while not applicable sections
should be left blank.
To comply with the documentation the led device name is changed
from "mmc*" to "mmc*::".
Signed-off-by: Helmut Schaa <helmut.schaa@googlemail.com>
Signed-off-by: Pierre Ossman <drzeus@drzeus.cx>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
-rw-r--r-- | drivers/mmc/host/sdhci.c | 4 | ||||
-rw-r--r-- | drivers/mmc/host/sdhci.h | 1 |
2 files changed, 4 insertions, 1 deletions
diff --git a/drivers/mmc/host/sdhci.c b/drivers/mmc/host/sdhci.c index e3a8133560a..cc0feaeb249 100644 --- a/drivers/mmc/host/sdhci.c +++ b/drivers/mmc/host/sdhci.c @@ -1690,7 +1690,9 @@ int sdhci_add_host(struct sdhci_host *host) #endif #ifdef CONFIG_LEDS_CLASS - host->led.name = mmc_hostname(mmc); + snprintf(host->led_name, sizeof(host->led_name), + "%s::", mmc_hostname(mmc)); + host->led.name = host->led_name; host->led.brightness = LED_OFF; host->led.default_trigger = mmc_hostname(mmc); host->led.brightness_set = sdhci_led_control; diff --git a/drivers/mmc/host/sdhci.h b/drivers/mmc/host/sdhci.h index 197d4a05f4a..590d78fe9d6 100644 --- a/drivers/mmc/host/sdhci.h +++ b/drivers/mmc/host/sdhci.h @@ -220,6 +220,7 @@ struct sdhci_host { #ifdef CONFIG_LEDS_CLASS struct led_classdev led; /* LED control */ + char led_name[32]; #endif spinlock_t lock; /* Mutex */ |