diff options
author | Pinkava J <Jiri.Pinkava@vscht.cz> | 2010-05-06 09:21:16 -0400 |
---|---|---|
committer | Ben Dooks <ben-linux@fluff.org> | 2010-05-06 20:41:32 -0400 |
commit | 319887ee800f889e4c81d73f0ee4bcf532f9c34d (patch) | |
tree | c16548388e0ac2568d6e10c7e29d33ad81799df7 /arch/arm/mach-s3c2410 | |
parent | 8ecad34918174580b069f7d4dcef3f46a099e8f7 (diff) |
ARM: n35: Add support for LEDs on Acer n35
Signed-off-by: Jiri Pinkava <jiri.pinkava@vscht.cz>
Signed-off-by: Ben Dooks <ben-linux@fluff.org>
Diffstat (limited to 'arch/arm/mach-s3c2410')
-rw-r--r-- | arch/arm/mach-s3c2410/mach-n30.c | 33 |
1 files changed, 33 insertions, 0 deletions
diff --git a/arch/arm/mach-s3c2410/mach-n30.c b/arch/arm/mach-s3c2410/mach-n30.c index ce1172ef5b72..b83eabdf709b 100644 --- a/arch/arm/mach-s3c2410/mach-n30.c +++ b/arch/arm/mach-s3c2410/mach-n30.c | |||
@@ -264,6 +264,14 @@ static struct s3c24xx_led_platdata n30_blue_led_pdata = { | |||
264 | .def_trigger = "", | 264 | .def_trigger = "", |
265 | }; | 265 | }; |
266 | 266 | ||
267 | /* This is the blue LED on the device. Originaly used to indicate GPS activity | ||
268 | * by flashing. */ | ||
269 | static struct s3c24xx_led_platdata n35_blue_led_pdata = { | ||
270 | .name = "blue_led", | ||
271 | .gpio = S3C2410_GPD(8), | ||
272 | .def_trigger = "", | ||
273 | }; | ||
274 | |||
267 | /* This LED is driven by the battery microcontroller, and is blinking | 275 | /* This LED is driven by the battery microcontroller, and is blinking |
268 | * red, blinking green or solid green when the battery is low, | 276 | * red, blinking green or solid green when the battery is low, |
269 | * charging or full respectively. By driving GPD9 low, it's possible | 277 | * charging or full respectively. By driving GPD9 low, it's possible |
@@ -275,6 +283,13 @@ static struct s3c24xx_led_platdata n30_warning_led_pdata = { | |||
275 | .def_trigger = "", | 283 | .def_trigger = "", |
276 | }; | 284 | }; |
277 | 285 | ||
286 | static struct s3c24xx_led_platdata n35_warning_led_pdata = { | ||
287 | .name = "warning_led", | ||
288 | .flags = S3C24XX_LEDF_ACTLOW | S3C24XX_LEDF_TRISTATE, | ||
289 | .gpio = S3C2410_GPD(9), | ||
290 | .def_trigger = "", | ||
291 | }; | ||
292 | |||
278 | static struct platform_device n30_blue_led = { | 293 | static struct platform_device n30_blue_led = { |
279 | .name = "s3c24xx_led", | 294 | .name = "s3c24xx_led", |
280 | .id = 1, | 295 | .id = 1, |
@@ -283,6 +298,14 @@ static struct platform_device n30_blue_led = { | |||
283 | }, | 298 | }, |
284 | }; | 299 | }; |
285 | 300 | ||
301 | static struct platform_device n35_blue_led = { | ||
302 | .name = "s3c24xx_led", | ||
303 | .id = 1, | ||
304 | .dev = { | ||
305 | .platform_data = &n35_blue_led_pdata, | ||
306 | }, | ||
307 | }; | ||
308 | |||
286 | static struct platform_device n30_warning_led = { | 309 | static struct platform_device n30_warning_led = { |
287 | .name = "s3c24xx_led", | 310 | .name = "s3c24xx_led", |
288 | .id = 2, | 311 | .id = 2, |
@@ -291,6 +314,14 @@ static struct platform_device n30_warning_led = { | |||
291 | }, | 314 | }, |
292 | }; | 315 | }; |
293 | 316 | ||
317 | static struct platform_device n35_warning_led = { | ||
318 | .name = "s3c24xx_led", | ||
319 | .id = 2, | ||
320 | .dev = { | ||
321 | .platform_data = &n35_warning_led_pdata, | ||
322 | }, | ||
323 | }; | ||
324 | |||
294 | static struct s3c2410fb_display n30_display __initdata = { | 325 | static struct s3c2410fb_display n30_display __initdata = { |
295 | .type = S3C2410_LCDCON1_TFT, | 326 | .type = S3C2410_LCDCON1_TFT, |
296 | .width = 240, | 327 | .width = 240, |
@@ -338,6 +369,8 @@ static struct platform_device *n35_devices[] __initdata = { | |||
338 | &s3c_device_rtc, | 369 | &s3c_device_rtc, |
339 | &s3c_device_usbgadget, | 370 | &s3c_device_usbgadget, |
340 | &n35_button_device, | 371 | &n35_button_device, |
372 | &n35_blue_led, | ||
373 | &n35_warning_led, | ||
341 | }; | 374 | }; |
342 | 375 | ||
343 | static struct s3c2410_platform_i2c __initdata n30_i2ccfg = { | 376 | static struct s3c2410_platform_i2c __initdata n30_i2ccfg = { |