diff options
Diffstat (limited to 'board/MAI/AmigaOneG3SE')
-rw-r--r-- | board/MAI/AmigaOneG3SE/AmigaOneG3SE.c | 9 | ||||
-rw-r--r-- | board/MAI/AmigaOneG3SE/Makefile | 13 | ||||
-rw-r--r-- | board/MAI/AmigaOneG3SE/articiaS.c | 5 | ||||
-rw-r--r-- | board/MAI/AmigaOneG3SE/articiaS_pci.c | 10 | ||||
-rw-r--r-- | board/MAI/AmigaOneG3SE/config.mk | 2 | ||||
-rw-r--r-- | board/MAI/AmigaOneG3SE/video.c | 6 |
6 files changed, 26 insertions, 19 deletions
diff --git a/board/MAI/AmigaOneG3SE/AmigaOneG3SE.c b/board/MAI/AmigaOneG3SE/AmigaOneG3SE.c index 0cf5388..9d5c24e 100644 --- a/board/MAI/AmigaOneG3SE/AmigaOneG3SE.c +++ b/board/MAI/AmigaOneG3SE/AmigaOneG3SE.c @@ -76,9 +76,8 @@ __asm(" .globl send_kb \n int checkboard (void) { - printf ("AmigaOneG3SE\n"); - - return 1; + printf ("Board: AmigaOneG3SE\n"); + return 0; } long initdram (int board_type) @@ -88,9 +87,9 @@ long initdram (int board_type) -void after_reloc (ulong dest_addr) +void after_reloc (ulong dest_addr, gd_t *gd) { - DECLARE_GLOBAL_DATA_PTR; +/* HJF: DECLARE_GLOBAL_DATA_PTR; */ board_init_r (gd, dest_addr); } diff --git a/board/MAI/AmigaOneG3SE/Makefile b/board/MAI/AmigaOneG3SE/Makefile index 7271746..785f01f 100644 --- a/board/MAI/AmigaOneG3SE/Makefile +++ b/board/MAI/AmigaOneG3SE/Makefile @@ -35,13 +35,16 @@ AOBJS = board_asm_init.o memio.o OBJS = $(COBJS) $(AOBJS) -## FIXME !!! -# EMUOBJS = ../bios_emulator/scitech/src/x86emu/*.o +EMUDIR = ../bios_emulator/scitech/src/x86emu/ +EMUOBJ = $(EMUDIR)decode.o $(EMUDIR)ops2.o $(EMUDIR)fpu.o $(EMUDIR)prim_ops.o \ + $(EMUDIR)ops.o $(EMUDIR)sys.o +EMUSRC = $(EMUOBJ:.o=.c) - -$(LIB): .depend $(OBJS) $(EMUOBJS) +$(LIB): .depend $(OBJS) $(EMUSRC) + make libx86emu.a -C ../bios_emulator/scitech/src/x86emu -f makefile.uboot CROSS_COMPILE=$(CROSS_COMPILE) -rm $(LIB) - $(AR) crv $@ $(OBJS) $(EMUOBJS) + $(AR) crv $@ $(OBJS) $(EMUOBJ) + ######################################################################### diff --git a/board/MAI/AmigaOneG3SE/articiaS.c b/board/MAI/AmigaOneG3SE/articiaS.c index af85444..5eddfc6 100644 --- a/board/MAI/AmigaOneG3SE/articiaS.c +++ b/board/MAI/AmigaOneG3SE/articiaS.c @@ -82,8 +82,9 @@ static inline unsigned short NSto10PS (unsigned char spd_byte) long detect_sdram (uint8 * rom, int dimmNum, struct dimm_bank *banks) { + DECLARE_GLOBAL_DATA_PTR; int dimm_address = (dimmNum == 0) ? SM_DIMM0_ADDR : SM_DIMM1_ADDR; - uint32 busclock = get_bus_freq (0); + uint32 busclock = gd->bus_clk; uint32 memclock = busclock; uint32 tmemclock = 1000000000 / (memclock / 100); uint32 datawidth; @@ -404,7 +405,7 @@ long articiaS_ram_init (void) uint32 total_ram = 0; struct dimm_bank banks[4]; /* FIXME: Move to initram */ - uint32 busclock = get_bus_freq (0); + uint32 busclock = gd->bus_clk; uint32 memclock = busclock; uint32 reg32; uint32 refresh_clocks; diff --git a/board/MAI/AmigaOneG3SE/articiaS_pci.c b/board/MAI/AmigaOneG3SE/articiaS_pci.c index 774c32d..2a7763d 100644 --- a/board/MAI/AmigaOneG3SE/articiaS_pci.c +++ b/board/MAI/AmigaOneG3SE/articiaS_pci.c @@ -26,7 +26,7 @@ #include "memio.h" #include "articiaS.h" -//#define ARTICIA_PCI_DEBUG +#undef ARTICIA_PCI_DEBUG #ifdef ARTICIA_PCI_DEBUG #define PRINTF(fmt,args...) printf (fmt ,##args) @@ -512,7 +512,11 @@ int articiaS_init_vga (void) PRINTF("Searching for class 0x%x on bus %d\n", classes[classnr], busnr); /* Find the first of this class on this bus */ dev = pci_hose_find_class(&articiaS_hose, busnr, classes[classnr], 0); - if (dev != ~0) break; + if (dev != ~0) + { + PRINTF("Found VGA Card at %02x:%02x:%02x\n", PCI_BUS(dev), PCI_DEV(dev), PCI_FUNC(dev)); + break; + } busnr++; if (busnr > articiaS_hose.last_busno) { @@ -552,7 +556,7 @@ int articiaS_init_vga (void) /* * Now try to run the bios */ - + PRINTF("Trying to run bios now\n"); if (execute_bios(dev, gd->relocaddr)) { printf("OK\n"); diff --git a/board/MAI/AmigaOneG3SE/config.mk b/board/MAI/AmigaOneG3SE/config.mk index 0537cd9..d7d0e6b 100644 --- a/board/MAI/AmigaOneG3SE/config.mk +++ b/board/MAI/AmigaOneG3SE/config.mk @@ -29,5 +29,5 @@ X86EMU = -I../bios_emulator/scitech/include -I../bios_emulator/scitech/src/x86e TEXT_BASE = 0xfff00000 -PLATFORM_CPPFLAGS += -DTEXT_BASE=$(TEXT_BASE) -Wa,-mregnames -DEASTEREGG $(X86EMU) #-DDEBUG +PLATFORM_CPPFLAGS += -DTEXT_BASE=$(TEXT_BASE) -Wa,-mregnames -DEASTEREGG $(X86EMU) -Dprintk=printf #-DDEBUG diff --git a/board/MAI/AmigaOneG3SE/video.c b/board/MAI/AmigaOneG3SE/video.c index d0e366c..e80288b 100644 --- a/board/MAI/AmigaOneG3SE/video.c +++ b/board/MAI/AmigaOneG3SE/video.c @@ -474,13 +474,13 @@ void video_easteregg(void) } #endif -extern bd_t *bd_global; extern block_dev_desc_t * ide_get_dev(int dev); extern char version_string[]; void video_banner(void) { block_dev_desc_t *ide; + DECLARE_GLOBAL_DATA_PTR; int i; char *s; int maxdev; @@ -513,8 +513,8 @@ void video_banner(void) video_clear(); printf("%s\n\nCPU: ", version_string); checkcpu(); - printf("DRAM: %ld MB\n", bd_global->bi_memsize/(1024*1024)); - printf("FSB: %ld MHz\n", bd_global->bi_busfreq/1000000); + printf("DRAM: %ld MB\n", gd->bd->bi_memsize/(1024*1024)); + printf("FSB: %ld MHz\n", gd->bd->bi_busfreq/1000000); printf("\n---- Disk summary ----\n"); for (i = 0; i < maxdev; i++) |