Commit d34a13fc authored by Henrik Nordstrom's avatar Henrik Nordstrom
Browse files

felboot: Even closer to u-boot

parent c4ae8f2e
...@@ -14,7 +14,7 @@ UBOOT=$(HOME)/SRC/u-boot/ ...@@ -14,7 +14,7 @@ UBOOT=$(HOME)/SRC/u-boot/
# U-boot object path (O=... when building u-boot). # U-boot object path (O=... when building u-boot).
UBOOTOBJ=$(UBOOT)build/$(BOARD)/ UBOOTOBJ=$(UBOOT)build/$(BOARD)/
CFLAGS=-g -O2 -marm -mno-thumb-interwork -mabi=aapcs-linux -march=armv7-a -fno-common -ffixed-r8 -msoft-float -I$(UBOOTOBJ)include2 -I$(UBOOTOBJ)include -I$(UBOOT)include CFLAGS=-g -O2 -marm -mno-thumb-interwork -mabi=aapcs-linux -march=armv7-a -fno-common -fno-builtin -ffreestanding -ffixed-r8 -msoft-float -D__KERNEL__ -I$(UBOOTOBJ)include2 -I$(UBOOTOBJ)include -I$(UBOOT)include
all: fel-boot-$(BOARD).bin all: fel-boot-$(BOARD).bin
......
#ifndef _COMMON_H
#define _COMMON_H
#include <stdint.h>
#define u32 uint32_t
#define u16 uint16_t
#define u8 uint8_t
#define s32 int32_t
#define s16 int16_t
#define s8 int8_t
#define __u8 u8
#define __u16 u16
#define __u32 u32
#define __s8 s8
#define __s16 s16
#define __s32 s32
#include "io.h"
#include "cpu.h"
#endif
...@@ -29,6 +29,7 @@ ...@@ -29,6 +29,7 @@
#include "early_print.h" #include "early_print.h"
#include <asm/arch/gpio.h> #include <asm/arch/gpio.h>
#include <asm/arch/clock.h> #include <asm/arch/clock.h>
#include "io.h"
static int uart_initialized = 0; static int uart_initialized = 0;
......
...@@ -17,15 +17,15 @@ ...@@ -17,15 +17,15 @@
* MA 02111-1307 USA * MA 02111-1307 USA
*/ */
#include "config.h" #include <common.h>
#include "common.h"
__attribute__ ((section (".text.start"))) void _start(void) __attribute__ ((section (".text.start"))) void _start(void)
{ {
s_init(); s_init();
} }
int gdata; DECLARE_GLOBAL_DATA_PTR;
gd_t gdata __attribute__ ((section(".data")));
void dcache_enable(void) void dcache_enable(void)
{ {
...@@ -70,11 +70,10 @@ int putchar(int ch) ...@@ -70,11 +70,10 @@ int putchar(int ch)
return 0; return 0;
} }
int puts(const char *str) void puts(const char *str)
{ {
while(*str) while(*str)
putchar(*str++); putchar(*str++);
return 0;
} }
#else #else
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment