summaryrefslogtreecommitdiffstats
path: root/arch/arm/mach-sa1100
diff options
context:
space:
mode:
authorRussell King <rmk+kernel@arm.linux.org.uk>2012-01-24 10:23:19 +0100
committerRussell King <rmk+kernel@arm.linux.org.uk>2012-02-09 16:34:12 +0100
commit4f592e6d1a6711b2ef140b5c76342dbe2506c8cb (patch)
tree5e650d8f630797d4740383e72ac0c119612334de /arch/arm/mach-sa1100
parentARM: sa11x0: assabet: deassert QMUTE to codec while codec is unpowered (diff)
downloadlinux-4f592e6d1a6711b2ef140b5c76342dbe2506c8cb.tar.xz
linux-4f592e6d1a6711b2ef140b5c76342dbe2506c8cb.zip
ARM: sa11x0: assabet: avoid glitching GPIOs when setting outputs
Avoid glitching the GPIO signals during initialization, which can have undesirable effects. Ensure that the desired pin state is set before we change the GPIO pin direction to be an output. Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
Diffstat (limited to 'arch/arm/mach-sa1100')
-rw-r--r--arch/arm/mach-sa1100/assabet.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/arch/arm/mach-sa1100/assabet.c b/arch/arm/mach-sa1100/assabet.c
index 3a3282e08a70..6356896587bf 100644
--- a/arch/arm/mach-sa1100/assabet.c
+++ b/arch/arm/mach-sa1100/assabet.c
@@ -202,8 +202,8 @@ static void __init assabet_init(void)
/*
* Ensure that the power supply is in "high power" mode.
*/
- GPDR |= GPIO_GPIO16;
GPSR = GPIO_GPIO16;
+ GPDR |= GPIO_GPIO16;
/*
* Ensure that these pins are set as outputs and are driving
@@ -211,8 +211,8 @@ static void __init assabet_init(void)
* the WS latch in the CPLD, and we don't float causing
* excessive power drain. --rmk
*/
- GPDR |= GPIO_SSP_TXD | GPIO_SSP_SCLK | GPIO_SSP_SFRM;
GPCR = GPIO_SSP_TXD | GPIO_SSP_SCLK | GPIO_SSP_SFRM;
+ GPDR |= GPIO_SSP_TXD | GPIO_SSP_SCLK | GPIO_SSP_SFRM;
/*
* Set up registers for sleep mode.