On StrongARM GPSR is write-only according to docs, so don't read from
it. Just set the required GPIO.
Signed-off-by: Dmitry Eremin-Solenikov <redacted>
---
arch/arm/mach-sa1100/collie.c | 2 +-
1 files changed, 1 insertions(+), 1 deletions(-)
On StrongARM GPSR is write-only according to docs, so don't read from
it. Just set the required GPIO.
Anyway GPSR (and GPCR) is a bit oriented register that allows
asserting individual bits without the need for read-modify-write
cycles, making the access inherently multithread safe. Using
read-modify-write on this register is contrary to the HW design.
A quick grep of the kernel source shows another abuse like this in
drivers/video/sa1100fb.c: GPSR |= SHANNON_GPIO_DISP_EN;
drivers/video/sa1100fb.c: GPCR |= SHANNON_GPIO_DISP_EN;
Lothar Wa?mann
--
___________________________________________________________
Ka-Ro electronics GmbH | Pascalstra?e 22 | D - 52076 Aachen
Phone: +49 2408 1402-0 | Fax: +49 2408 1402-10
Gesch?ftsf?hrer: Matthias Kaussen
Handelsregistereintrag: Amtsgericht Aachen, HRB 4996
www.karo-electronics.de | info at karo-electronics.de
___________________________________________________________
From: Eric Miao <hidden> Date: 2011-06-17 15:07:59
Would it be better to switch to use gpio_* API instead of manipulating
GPxR directly?
On Fri, Jun 17, 2011 at 10:11 PM, Dmitry Eremin-Solenikov
[off-list ref] wrote:
quoted hunk
On StrongARM GPSR is write-only according to docs, so don't read from
it. Just set the required GPIO.
Signed-off-by: Dmitry Eremin-Solenikov <redacted>
---
?arch/arm/mach-sa1100/collie.c | ? ?2 +-
?1 files changed, 1 insertions(+), 1 deletions(-)
Would it be better to switch to use gpio_* API instead of manipulating
GPxR directly?
Yes. Probably. But this would require a much bigger cleanup effort. Waiting
for spare time for it.
On Fri, Jun 17, 2011 at 10:11 PM, Dmitry Eremin-Solenikov
[off-list ref] wrote:
quoted
On StrongARM GPSR is write-only according to docs, so don't read from
it. Just set the required GPIO.
Signed-off-by: Dmitry Eremin-Solenikov <redacted>
---
arch/arm/mach-sa1100/collie.c | 2 +-
1 files changed, 1 insertions(+), 1 deletions(-)