aboutsummaryrefslogtreecommitdiffstats
path: root/arch
diff options
context:
space:
mode:
authorDmitry Artamonow <mad_soft@inbox.ru>2009-11-27 06:07:11 -0500
committerRussell King <rmk+kernel@arm.linux.org.uk>2009-12-06 11:52:55 -0500
commit51834901faee2850e55865589cefd7588202cbf7 (patch)
treea1ee086951429d13c8271354e135d5e243f17197 /arch
parentca912b17c0af886d9090449d5933ac6ca9a7a20f (diff)
ARM: 5817/1: SA1100: h3100/h3600: configure all unused gpios as inputs
After conversion to gpiolib there's still some GPIOs left, that get configured in *_mach_init() as outputs (using direct operations on GPCR/GPDR registers), but otherwise unused. These GPIOs are mainly sound related and should be configured by corresponding driver once it is written. Drop this initialisation and configure all GPIOs as input. 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.c26
1 files changed, 3 insertions, 23 deletions
diff --git a/arch/arm/mach-sa1100/h3600.c b/arch/arm/mach-sa1100/h3600.c
index 6792dd14b6e7..3d52190a2690 100644
--- a/arch/arm/mach-sa1100/h3600.c
+++ b/arch/arm/mach-sa1100/h3600.c
@@ -297,20 +297,14 @@ static void __init h3xxx_map_io(void)
297 PCFR = PCFR_OPDE; 297 PCFR = PCFR_OPDE;
298 PSDR = 0; 298 PSDR = 0;
299 299
300 GPCR = 0x0fffffff; /* All outputs are set low by default */
301 GPDR = 0; /* Configure all GPIOs as input */
300} 302}
301 303
302/************************* H3100 *************************/ 304/************************* H3100 *************************/
303 305
304#ifdef CONFIG_SA1100_H3100 306#ifdef CONFIG_SA1100_H3100
305 307
306#define H3100_DIRECT_EGPIO (GPIO_H3100_BT_ON \
307 | GPIO_H3100_GPIO3 \
308 | GPIO_H3100_QMUTE \
309 | GPIO_H3100_LCD_3V_ON \
310 | GPIO_H3100_AUD_ON \
311 | GPIO_H3100_AUD_PWR_ON \
312 | GPIO_H3100_IR_ON \
313 | GPIO_H3100_IR_FSEL)
314/* 308/*
315 * helper for sa1100fb 309 * helper for sa1100fb
316 */ 310 */
@@ -330,16 +324,9 @@ static void __init h3100_map_io(void)
330 324
331 sa1100fb_lcd_power = h3100_lcd_power; 325 sa1100fb_lcd_power = h3100_lcd_power;
332 326
333 /* Initialize h3100-specific values here */
334 GPCR = 0x0fffffff; /* All outputs are set low by default */
335 GPDR = GPIO_H3600_L3_CLOCK |
336 GPIO_H3600_L3_MODE | GPIO_H3600_L3_DATA |
337 GPIO_H3600_CLK_SET1 | GPIO_H3600_CLK_SET0 |
338 H3100_DIRECT_EGPIO;
339
340 /* Older bootldrs put GPIO2-9 in alternate mode on the 327 /* Older bootldrs put GPIO2-9 in alternate mode on the
341 assumption that they are used for video */ 328 assumption that they are used for video */
342 GAFR &= ~H3100_DIRECT_EGPIO; 329 GAFR &= ~0x000001fb;
343} 330}
344 331
345/* 332/*
@@ -424,13 +411,6 @@ static void __init h3600_map_io(void)
424 h3xxx_map_io(); 411 h3xxx_map_io();
425 412
426 sa1100fb_lcd_power = h3600_lcd_power; 413 sa1100fb_lcd_power = h3600_lcd_power;
427
428 /* Initialize h3600-specific values here */
429
430 GPCR = 0x0fffffff; /* All outputs are set low by default */
431 GPDR = GPIO_H3600_L3_CLOCK |
432 GPIO_H3600_L3_MODE | GPIO_H3600_L3_DATA |
433 GPIO_H3600_CLK_SET1 | GPIO_H3600_CLK_SET0;
434} 414}
435 415
436/* 416/*