summaryrefslogtreecommitdiff
path: root/board/imgtec
diff options
context:
space:
mode:
authorPaul Burton <paul.burton@imgtec.com>2013-11-08 11:18:51 +0000
committerDaniel Schwierzeck <daniel.schwierzeck@gmail.com>2013-11-09 17:21:01 +0100
commite0ada6319bb3eb8bc1f97c00f05508ac0cfffc34 (patch)
treeab5313cdf21b77a1944ed4b271ff0a5ccc24e691 /board/imgtec
parentbaf37f06c5cc51d2b9d71a2c83d5d92de60203a9 (diff)
malta: display "U-boot" on the LCD screen
Displaying a message on the LCD screen is a simple yet effective way to show the user that the board has booted successfully. Signed-off-by: Paul Burton <paul.burton@imgtec.com>
Diffstat (limited to 'board/imgtec')
-rw-r--r--board/imgtec/malta/malta.c19
1 files changed, 19 insertions, 0 deletions
diff --git a/board/imgtec/malta/malta.c b/board/imgtec/malta/malta.c
index 2af00672daa..119546ae166 100644
--- a/board/imgtec/malta/malta.c
+++ b/board/imgtec/malta/malta.c
@@ -29,6 +29,24 @@ enum sys_con {
SYSCON_MSC01,
};
+static void malta_lcd_puts(const char *str)
+{
+ int i;
+ void *reg = (void *)CKSEG1ADDR(MALTA_ASCIIPOS0);
+
+ /* print up to 8 characters of the string */
+ for (i = 0; i < min(strlen(str), 8); i++) {
+ __raw_writel(str[i], reg);
+ reg += MALTA_ASCIIPOS1 - MALTA_ASCIIPOS0;
+ }
+
+ /* fill the rest of the display with spaces */
+ for (; i < 8; i++) {
+ __raw_writel(' ', reg);
+ reg += MALTA_ASCIIPOS1 - MALTA_ASCIIPOS0;
+ }
+}
+
static enum core_card malta_core_card(void)
{
u32 corid, rev;
@@ -71,6 +89,7 @@ int checkboard(void)
{
enum core_card core;
+ malta_lcd_puts("U-boot");
puts("Board: MIPS Malta");
core = malta_core_card();