diff options
author | Dmitry Artamonow <mad_soft@inbox.ru> | 2009-11-27 05:58:35 -0500 |
---|---|---|
committer | Russell King <rmk+kernel@arm.linux.org.uk> | 2009-12-06 11:52:54 -0500 |
commit | cf5a87d80a70958b0622042b0b447f61aca1caf8 (patch) | |
tree | a98414b45611e95eb7f2c4fe5773ff44772df872 /arch | |
parent | 2a83709199adf4e89254e03981c0f9ff6558691f (diff) |
ARM: 5812/1: SA1100: h3100/h3600: separate machine-specific LCD helpers
h3100 and h3600 have different sets of LCD-controlling gpios,
which mapped to the same "abstracted" EGPIO.
As we plan to get rid of those abstracted egpios completely, we
need to separate these helper functions.
Signed-off-by: Dmitry Artamonow <mad_soft@inbox.ru>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
Diffstat (limited to 'arch')
-rw-r--r-- | arch/arm/mach-sa1100/h3600.c | 29 |
1 files changed, 20 insertions, 9 deletions
diff --git a/arch/arm/mach-sa1100/h3600.c b/arch/arm/mach-sa1100/h3600.c index 021cecb1bd06..1297c11c030a 100644 --- a/arch/arm/mach-sa1100/h3600.c +++ b/arch/arm/mach-sa1100/h3600.c | |||
@@ -191,14 +191,6 @@ static void __init h3xxx_mach_init(void) | |||
191 | sa11x0_register_mtd(&h3xxx_flash_data, &h3xxx_flash_resource, 1); | 191 | sa11x0_register_mtd(&h3xxx_flash_data, &h3xxx_flash_resource, 1); |
192 | } | 192 | } |
193 | 193 | ||
194 | /* | ||
195 | * helper for sa1100fb | ||
196 | */ | ||
197 | static void h3xxx_lcd_power(int enable) | ||
198 | { | ||
199 | assign_h3600_egpio(IPAQ_EGPIO_LCD_POWER, enable); | ||
200 | } | ||
201 | |||
202 | static struct map_desc h3600_io_desc[] __initdata = { | 194 | static struct map_desc h3600_io_desc[] __initdata = { |
203 | { /* static memory bank 2 CS#2 */ | 195 | { /* static memory bank 2 CS#2 */ |
204 | .virtual = H3600_BANK_2_VIRT, | 196 | .virtual = H3600_BANK_2_VIRT, |
@@ -240,7 +232,6 @@ static void __init h3xxx_map_io(void) | |||
240 | PCFR = PCFR_OPDE; | 232 | PCFR = PCFR_OPDE; |
241 | PSDR = 0; | 233 | PSDR = 0; |
242 | 234 | ||
243 | sa1100fb_lcd_power = h3xxx_lcd_power; | ||
244 | } | 235 | } |
245 | 236 | ||
246 | /************************* H3100 *************************/ | 237 | /************************* H3100 *************************/ |
@@ -321,11 +312,21 @@ static void h3100_control_egpio(enum ipaq_egpio_type x, int setp) | |||
321 | | GPIO_H3100_AUD_PWR_ON \ | 312 | | GPIO_H3100_AUD_PWR_ON \ |
322 | | GPIO_H3100_IR_ON \ | 313 | | GPIO_H3100_IR_ON \ |
323 | | GPIO_H3100_IR_FSEL) | 314 | | GPIO_H3100_IR_FSEL) |
315 | /* | ||
316 | * helper for sa1100fb | ||
317 | */ | ||
318 | static void h3100_lcd_power(int enable) | ||
319 | { | ||
320 | assign_h3600_egpio(IPAQ_EGPIO_LCD_POWER, enable); | ||
321 | } | ||
322 | |||
324 | 323 | ||
325 | static void __init h3100_map_io(void) | 324 | static void __init h3100_map_io(void) |
326 | { | 325 | { |
327 | h3xxx_map_io(); | 326 | h3xxx_map_io(); |
328 | 327 | ||
328 | sa1100fb_lcd_power = h3100_lcd_power; | ||
329 | |||
329 | /* Initialize h3100-specific values here */ | 330 | /* Initialize h3100-specific values here */ |
330 | GPCR = 0x0fffffff; /* All outputs are set low by default */ | 331 | GPCR = 0x0fffffff; /* All outputs are set low by default */ |
331 | GPDR = GPIO_H3600_L3_CLOCK | | 332 | GPDR = GPIO_H3600_L3_CLOCK | |
@@ -455,10 +456,20 @@ static void h3600_control_egpio(enum ipaq_egpio_type x, int setp) | |||
455 | } | 456 | } |
456 | } | 457 | } |
457 | 458 | ||
459 | /* | ||
460 | * helper for sa1100fb | ||
461 | */ | ||
462 | static void h3600_lcd_power(int enable) | ||
463 | { | ||
464 | assign_h3600_egpio(IPAQ_EGPIO_LCD_POWER, enable); | ||
465 | } | ||
466 | |||
458 | static void __init h3600_map_io(void) | 467 | static void __init h3600_map_io(void) |
459 | { | 468 | { |
460 | h3xxx_map_io(); | 469 | h3xxx_map_io(); |
461 | 470 | ||
471 | sa1100fb_lcd_power = h3600_lcd_power; | ||
472 | |||
462 | /* Initialize h3600-specific values here */ | 473 | /* Initialize h3600-specific values here */ |
463 | 474 | ||
464 | GPCR = 0x0fffffff; /* All outputs are set low by default */ | 475 | GPCR = 0x0fffffff; /* All outputs are set low by default */ |