Fix some compile issues for MAI board.
authorJason Jin <Jason.jin@freescale.com>
Fri, 13 Jul 2007 04:14:59 +0000 (12:14 +0800)
committerWolfgang Denk <wd@denx.de>
Sun, 5 Aug 2007 23:51:08 +0000 (01:51 +0200)
Signed-off-by: Jason Jin <Jason.jin@freescale.com>
board/MAI/AmigaOneG3SE/AmigaOneG3SE.c
board/MAI/AmigaOneG3SE/video.c
include/configs/AmigaOneG3SE.h

index 40f41c78185dbf6de24cc6fe3822af5650029fcb..b472176635bf66f55fd5d3bb9a7566cf773fe507 100644 (file)
 #include "memio.h"
 #include "via686.h"
 
-__asm(" .globl send_kb                                      \n
-       send_kb:                                            \n
-               lis     r9, 0xfe00                          \n
-                                                           \n
-               li      r4, 0x10        # retries           \n
-               mtctr   r4                                  \n
-                                                           \n
-       idle:                                               \n
-               lbz     r4, 0x64(r9)                        \n
-               andi.   r4, r4, 0x02                        \n
-               bne     idle                                \n
-                                                           \n
-       ready:                                              \n
-               stb     r3, 0x60(r9)                        \n
-                                                           \n
-       check:                                              \n
-               lbz     r4, 0x64(r9)                        \n
-               andi.   r4, r4, 0x01                        \n
-               beq     check                               \n
-                                                           \n
-               lbz     r4, 0x60(r9)                        \n
-               cmpwi   r4, 0xfa                            \n
-               beq     done                                \n
-                                                           \n
-               bdnz    idle                                \n
-                                                           \n
-               li      r3, 0                               \n
-               blr                                         \n
-                                                           \n
-       done:                                               \n
-               li      r3, 1                               \n
-               blr                                         \n
-                                                           \n
-       .globl test_kb                                      \n
-       test_kb:                                            \n
-               mflr    r10                                 \n
-               li      r3, 0xed                            \n
-               bl      send_kb                             \n
-               li      r3, 0x01                            \n
-               bl      send_kb                             \n
-               mtlr    r10                                 \n
-               blr                                         \n
-");
+__asm__(" .globl send_kb                                   \n "
+       "send_kb:                                           \n "
+       "       lis     r9, 0xfe00                          \n "
+       "                                                   \n "
+       "       li      r4, 0x10        # retries           \n "
+       "       mtctr   r4                                  \n "
+       "                                                   \n "
+       "idle:                                              \n "
+       "       lbz     r4, 0x64(r9)                        \n "
+       "       andi.   r4, r4, 0x02                        \n "
+       "       bne     idle                                \n "
+
+       "ready:                                             \n "
+       "       stb     r3, 0x60(r9)                        \n "
+       "                                                   \n "
+       "check:                                             \n "
+       "       lbz     r4, 0x64(r9)                        \n "
+       "       andi.   r4, r4, 0x01                        \n "
+       "       beq     check                               \n "
+       "                                                   \n "
+       "       lbz     r4, 0x60(r9)                        \n "
+       "       cmpwi   r4, 0xfa                            \n "
+       "       beq     done                                \n "
+
+       "       bdnz    idle                                \n "
+
+       "       li      r3, 0                               \n "
+       "       blr                                         \n "
+
+       "done:                                              \n "
+       "       li      r3, 1                               \n "
+       "       blr                                         \n "
+
+       ".globl test_kb                                     \n "
+       "test_kb:                                           \n "
+       "       mflr    r10                                 \n "
+       "       li      r3, 0xed                            \n "
+       "       bl      send_kb                             \n "
+       "       li      r3, 0x01                            \n "
+       "       bl      send_kb                             \n "
+       "       mtlr    r10                                 \n "
+       "       blr                                         "
+);
 
 
 int checkboard (void)
index f6327f72038c83862c9483b7fd9cd28b54a95aaf..fc27c685835fe0ed570275cb2a897010fbb56126 100644 (file)
@@ -56,6 +56,7 @@ int  video_rows(void);
 int  video_cols(void);
 
 char *prompt_string = "=>";
+unsigned char video_get_attr(void);
 
 void video_set_color(unsigned char attr)
 {
index 661149e66b68399e762efb4219935e241c64f23d..d914dccfbb4d922830dc77314897f19c7dca7b0b 100644 (file)
@@ -95,6 +95,8 @@
 /* #define CONFIG_PCI_SCAN_SHOW 1 */
 #define CONFIG_PCI_PNP         1       /* PCI plug-and-play */
 
+#define atoi(x)                simple_strtoul(x,NULL,10)
+
 /*
  * Miscellaneous configurable options
  */