# HG changeset patch # User Mychaela Falconia # Date 1451513555 0 # Node ID d92e4aadeeb39ef964b21e708837a3061e1f4568 # Parent a7b0b426f9ca58bd3a93f0a26a710013490174b0 target-utils/c139explore: a cleaner way of setting the fixed UART base address diff -r a7b0b426f9ca -r d92e4aadeeb3 target-utils/c139explore/Makefile --- a/target-utils/c139explore/Makefile Wed Dec 30 21:28:41 2015 +0000 +++ b/target-utils/c139explore/Makefile Wed Dec 30 22:12:35 2015 +0000 @@ -5,7 +5,7 @@ OBJCOPY=arm-elf-objcopy PROG= c139explore -OBJS= crt0.o backlight.o cmdtab.o lcd.o main.o mygetchar.o uwire.o +OBJS= crt0.o backlight.o cmdtab.o lcd.o main.o mygetchar.o uartbase.o uwire.o LIBS= ../libcommon/libcommon.a ../libprintf/libprintf.a ../libbase/libbase.a LDS= ../env/compalram.lds diff -r a7b0b426f9ca -r d92e4aadeeb3 target-utils/c139explore/main.c --- a/target-utils/c139explore/main.c Wed Dec 30 21:28:41 2015 +0000 +++ b/target-utils/c139explore/main.c Wed Dec 30 22:12:35 2015 +0000 @@ -1,13 +1,9 @@ #include "types.h" -#include "ns16550.h" - -struct ns16550_regs *uart_base; main() { /* delay kludge workaround for defect in fc-compalram */ osmo_delay_ms(30); - uart_base = (struct ns16550_regs *) 0xFFFF5800; printf("C139 hardware exploration utility running\n"); /* GPIO init */ *(volatile u16 *)0xfffe4802 = 0x0002; diff -r a7b0b426f9ca -r d92e4aadeeb3 target-utils/c139explore/uartbase.S --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/target-utils/c139explore/uartbase.S Wed Dec 30 22:12:35 2015 +0000 @@ -0,0 +1,5 @@ + .section .rodata + .balign 4 + .globl uart_base +uart_base: + .word 0xFFFF5800