summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJason Jin <Jason.jin@freescale.com>2007-07-13 12:14:59 +0800
committerWolfgang Denk <wd@denx.de>2007-08-06 01:51:08 +0200
commit5618332409bb96f4448d1712899369fc80c0b489 (patch)
tree255ee187095815c0157f9e5f56690c7c08cc6595
parent0f460a1ee148b648ee242c3157650287d4296260 (diff)
downloadu-boot-imx-5618332409bb96f4448d1712899369fc80c0b489.zip
u-boot-imx-5618332409bb96f4448d1712899369fc80c0b489.tar.gz
u-boot-imx-5618332409bb96f4448d1712899369fc80c0b489.tar.bz2
Fix some compile issues for MAI board.
Signed-off-by: Jason Jin <Jason.jin@freescale.com>
-rw-r--r--board/MAI/AmigaOneG3SE/AmigaOneG3SE.c86
-rw-r--r--board/MAI/AmigaOneG3SE/video.c1
-rw-r--r--include/configs/AmigaOneG3SE.h2
3 files changed, 46 insertions, 43 deletions
diff --git a/board/MAI/AmigaOneG3SE/AmigaOneG3SE.c b/board/MAI/AmigaOneG3SE/AmigaOneG3SE.c
index 40f41c7..b472176 100644
--- a/board/MAI/AmigaOneG3SE/AmigaOneG3SE.c
+++ b/board/MAI/AmigaOneG3SE/AmigaOneG3SE.c
@@ -30,49 +30,49 @@
#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)
diff --git a/board/MAI/AmigaOneG3SE/video.c b/board/MAI/AmigaOneG3SE/video.c
index f6327f7..fc27c68 100644
--- a/board/MAI/AmigaOneG3SE/video.c
+++ b/board/MAI/AmigaOneG3SE/video.c
@@ -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)
{
diff --git a/include/configs/AmigaOneG3SE.h b/include/configs/AmigaOneG3SE.h
index 661149e..d914dcc 100644
--- a/include/configs/AmigaOneG3SE.h
+++ b/include/configs/AmigaOneG3SE.h
@@ -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
*/