From: Erik M. <er...@us...> - 2001-10-28 20:27:40
|
Update of /cvsroot/blob/blob/src/blob In directory usw-pr-cvs1:/tmp/cvs-serv29407 Modified Files: h3600.c Log Message: Remember the EGPIO register cause it is write-only Index: h3600.c =================================================================== RCS file: /cvsroot/blob/blob/src/blob/h3600.c,v retrieving revision 1.1 retrieving revision 1.2 diff -u -d -r1.1 -r1.2 --- h3600.c 2001/10/27 21:04:20 1.1 +++ h3600.c 2001/10/28 20:27:38 1.2 @@ -34,7 +34,7 @@ /* flash descriptor for H3600 flash */ -/* 2x Intel ??? (16MB) */ +/* 2x 28F640J3A (16MB) */ static flash_descriptor_t h3600_flash_descriptors[] = { { @@ -61,8 +61,14 @@ /* H3600 EGPIO register */ -static u32 *egpio = (u32 *)0x49000000; +static u32 *EGPIO = (u32 *)0x49000000; +/* the EGPIO register is write only, so we need a shadow register to + * remember the state + */ +static u32 shadow_egpio; + + /* taken from Linux include/asm-arm/arch-sa1100/h3600.h */ #define EGPIO_H3600_VPP_ON (1 << 0) #define EGPIO_H3600_RS232_ON (1 << 7) /* UART3 transceiver force on. Active high. */ @@ -71,7 +77,8 @@ static void h3600_init_egpio(void) { /* enable RS232 tranceiver */ - *egpio = EGPIO_H3600_RS232_ON; + shadow_egpio = EGPIO_H3600_RS232_ON; + *EGPIO = shadow_egpio; } |