Skip to contentSkip to conversation

mgcoge, mgsuvd: use in_*/out_* accesors

U-Boot Applied Heiko Schocher 2 participants 2 messages Oct 17, 2008

lore
Share & tools
lore
#0 lore raw
---
 board/keymile/mgcoge/mgcoge.c |    5 +++--
 board/keymile/mgsuvd/mgsuvd.c |    5 +++--
 2 files changed, 6 insertions(+), 4 deletions(-)
board/keymile/mgcoge/mgcoge.c +3 -2
index bf6ce87..f35716b 100644
@@ -25,6 +25,7 @@
 #include <mpc8260.h>
 #include <ioports.h>
 #include <malloc.h>
+#include <asm/io.h>
 
 #if defined(CONFIG_OF_BOARD_SETUP) && defined(CONFIG_OF_LIBFDT)
 #include <libfdt.h>
@@ -295,8 +296,8 @@ int checkboard(void)
 int board_early_init_r (void)
 {
 	/* setup the UPIOx */
-	*(char *)(CONFIG_SYS_PIGGY_BASE + 0x02) = 0xc0;
-	*(char *)(CONFIG_SYS_PIGGY_BASE + 0x03) = 0x15;
+	out_8((u8 *)(CONFIG_SYS_PIGGY_BASE + 0x02), 0xc0);
+	out_8((u8 *)(CONFIG_SYS_PIGGY_BASE + 0x03), 0x15);
 	return 0;
 }
 
board/keymile/mgsuvd/mgsuvd.c +3 -2
index de4668c..9719cd0 100644
@@ -22,6 +22,7 @@
  */
 #include <common.h>
 #include <mpc8xx.h>
+#include <asm/io.h>
 
 #if defined(CONFIG_OF_BOARD_SETUP) && defined(CONFIG_OF_LIBFDT)
 #include <libfdt.h>
@@ -137,8 +138,8 @@ phys_size_t initdram (int board_type)
 int board_early_init_r(void)
 {
 	/* setup the UPIOx */
-	*(char *)(CONFIG_SYS_PIGGY_BASE + 0x02) = 0xc0;
-	*(char *)(CONFIG_SYS_PIGGY_BASE + 0x03) = 0x35;
+	out_8((u8 *)(CONFIG_SYS_PIGGY_BASE + 0x02), 0xc0);
+	out_8((u8 *)(CONFIG_SYS_PIGGY_BASE + 0x03), 0x35);
 	return 0;
 }
 
Signature · 5 lines
1.5.6.1

-- 
DENX Software Engineering GmbH,     MD: Wolfgang Denk & Detlev Zundel
HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany
#1 lore raw

Dear Heiko Schocher,

Quoted 5 lines · In message <[email protected]> you wrote:
---
 board/keymile/mgcoge/mgcoge.c |    5 +++--
 board/keymile/mgsuvd/mgsuvd.c |    5 +++--
 2 files changed, 6 insertions(+), 4 deletions(-)

Applied to "next"-Branch.

Best regards,

Wolfgang Denk

Signature · 6 lines
DENX Software Engineering GmbH,     MD: Wolfgang Denk & Detlev Zundel
HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany
Phone: (+49)-8142-66989-10 Fax: (+49)-8142-66989-80 Email: wd at denx.de
The more complex the mind, the greater the need for the simplicity of
play.
	-- Kirk, "Shore Leave", stardate 3025.8