From 4440673a95e63ad888a41db596edaa0c55d3a332 Mon Sep 17 00:00:00 2001 From: Uwe Kleine-König Date: Tue, 24 May 2011 17:13:29 -0700 Subject: leds: provide helper to register "leds-gpio" devices MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit This function makes a deep copy of the platform data to allow it to live in init memory. For a kernel that supports several machines and so includes the definition for several leds-gpio devices this saves quite some memory because all but one definition can be free'd after boot. As the function is used by arch code it must be builtin and so cannot go into leds-gpio.c. [akpm@linux-foundation.org: s/CONFIG_LED_REGISTER_GPIO/CONFIG_LEDS_REGISTER_GPIO/] Signed-off-by: Uwe Kleine-König Cc: Russell King Acked-by: Richard Purdie Cc: Fabio Estevam Cc: Sascha Hauer Tested-by: H Hartley Sweeten Signed-off-by: Andrew Morton Signed-off-by: Linus Torvalds --- drivers/leds/Kconfig | 7 +++++++ 1 file changed, 7 insertions(+) (limited to 'drivers/leds/Kconfig') diff --git a/drivers/leds/Kconfig b/drivers/leds/Kconfig index a4a77734ab6e..1d027b475b22 100644 --- a/drivers/leds/Kconfig +++ b/drivers/leds/Kconfig @@ -14,6 +14,13 @@ config LEDS_CLASS This option enables the led sysfs class in /sys/class/leds. You'll need this to do anything useful with LEDs. If unsure, say N. +config LEDS_GPIO_REGISTER + bool + help + This option provides the function gpio_led_register_device. + As this function is used by arch code it must not be compiled as a + module. + if NEW_LEDS comment "LED drivers" -- cgit v1.2.3