[PATCH] collie: don't read GPSR
Lothar Waßmann
LW at KARO-electronics.de
Fri Jun 17 10:49:31 EDT 2011
Hi,
Dmitry Eremin-Solenikov writes:
> 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
___________________________________________________________
More information about the linux-arm-kernel
mailing list