diff options
author | wdenk <wdenk> | 2004-07-10 23:48:41 +0000 |
---|---|---|
committer | wdenk <wdenk> | 2004-07-10 23:48:41 +0000 |
commit | 857cad37a41c431582a74be56f858ee0476cd0d9 (patch) | |
tree | ad20b07944687e5996418e91111a6cef5b2e319e | |
parent | fabd46acff08edd9f945340338caa07bb0534e64 (diff) | |
download | u-boot-imx-857cad37a41c431582a74be56f858ee0476cd0d9.zip u-boot-imx-857cad37a41c431582a74be56f858ee0476cd0d9.tar.gz u-boot-imx-857cad37a41c431582a74be56f858ee0476cd0d9.tar.bz2 |
Patches by Yasushi Shoji, 29 Jun 2004:
- add empty include/asm-microblaze/processor.h
- add to CREDITS and MAINTAINERS
- add gd initialization
- add MicroBlaze and SUZAKU board to MAKEALL script
- add reset support for SUZAKU
- add flush_cache() for MicroBlaze
- add CFG_FLASH_SIZE to include/configs/suzaku.h since we have fixed
size flash memory on SUZAKU
-rw-r--r-- | CHANGELOG | 10 | ||||
-rw-r--r-- | CREDITS | 4 | ||||
-rw-r--r-- | MAINTAINERS | 11 | ||||
-rw-r--r-- | MAKEALL | 7 | ||||
-rw-r--r-- | README | 2 | ||||
-rw-r--r-- | board/AtmarkTechno/suzaku/suzaku.c | 5 | ||||
-rw-r--r-- | drivers/serial_xuartlite.c | 2 | ||||
-rw-r--r-- | examples/stubs.c | 2 | ||||
-rw-r--r-- | include/asm-microblaze/processor.h | 1 | ||||
-rw-r--r-- | include/asm-microblaze/suzaku.h | 4 | ||||
-rw-r--r-- | include/configs/suzaku.h | 13 | ||||
-rw-r--r-- | lib_microblaze/Makefile | 2 | ||||
-rw-r--r-- | lib_microblaze/board.c | 13 | ||||
-rw-r--r-- | lib_microblaze/cache.c | 31 | ||||
-rw-r--r-- | microblaze_config.mk | 2 |
15 files changed, 102 insertions, 7 deletions
@@ -2,6 +2,16 @@ Changes since U-Boot 1.1.1: ====================================================================== +* Patches by Yasushi Shoji, 29 Jun 2004: + - add empty include/asm-microblaze/processor.h + - add to CREDITS and MAINTAINERS + - add gd initialization + - add MicroBlaze and SUZAKU board to MAKEALL script + - add reset support for SUZAKU + - add flush_cache() for MicroBlaze + - add CFG_FLASH_SIZE to include/configs/suzaku.h since we have fixed + size flash memory on SUZAKU + * Patch by Prakash Kumar, 27 Jun 2004: Add support for the PXA250 based Intrinsyc Cerf board. @@ -348,6 +348,10 @@ N: Robert Schwebel E: r.schwebel@pengutronix.de D: Support for csb226, logodl and innokom boards (PXA2xx) +N: Yasushi Shoji +E: yashi@atmark-techno.com +D: Support for Xilinx MicroBlaze, for Atmark Techno SUZAKU FPGA board + N: Kurt Stremerch E: kurt@exys.be D: Support for Exys XSEngine board diff --git a/MAINTAINERS b/MAINTAINERS index 6ffdead..9e62246 100644 --- a/MAINTAINERS +++ b/MAINTAINERS @@ -425,5 +425,16 @@ Scott McNutt <smcnutt@psyent.com> DK1C20 Nios-32 ######################################################################### +# MicroBlaze Systems: # +# # +# Maintainer Name, Email Address # +# Board CPU # +######################################################################### + +Yasushi Shoji <yashi@atmark-techno.com> + + SUZAKU MicroBlaze + +######################################################################### # End of MAINTAINERS list # ######################################################################### @@ -187,6 +187,12 @@ LIST_nios=" \ DK1S10 DK1S10_standard_32 DK1S10_mtx_ldk_20 \ " +######################################################################### +## MicroBlaze Systems +######################################################################### + +LIST_microblaze="suzaku" + #----------------------------------------------------------------------- #----- for now, just run PPC by default ----- @@ -211,6 +217,7 @@ do case "$arg" in ppc|5xx|5xxx|8xx|824x|8260|85xx|4xx|7xx|74xx| \ arm|SA|ARM7|ARM9|pxa|ixp| \ + microblaze| \ mips| \ nios| \ x86|I486) @@ -242,7 +242,7 @@ The following options need to be configured: MicroBlaze based CPUs: ---------------------- - CONFIG_MICROBLZE + CONFIG_MICROBLAZE - Board Type: Define exactly one of diff --git a/board/AtmarkTechno/suzaku/suzaku.c b/board/AtmarkTechno/suzaku/suzaku.c index 3a47aa5..afe124a 100644 --- a/board/AtmarkTechno/suzaku/suzaku.c +++ b/board/AtmarkTechno/suzaku/suzaku.c @@ -22,8 +22,11 @@ * MA 02111-1307 USA */ -#include <common.h> +/* This is a board specific file. It's OK to include board specific + * header files */ +#include <asm/suzaku.h> void do_reset(void) { + *((unsigned long *)(MICROBLAZE_SYSREG_BASE_ADDR)) = MICROBLAZE_SYSREG_RECONFIGURE; } diff --git a/drivers/serial_xuartlite.c b/drivers/serial_xuartlite.c index da2e746..ed59abe 100644 --- a/drivers/serial_xuartlite.c +++ b/drivers/serial_xuartlite.c @@ -24,7 +24,7 @@ #include <config.h> -#ifdef CONFIG_MICROBLZE +#ifdef CONFIG_MICROBLAZE #include <asm/serial_xuartlite.h> diff --git a/examples/stubs.c b/examples/stubs.c index 324a953..c3d2a77 100644 --- a/examples/stubs.c +++ b/examples/stubs.c @@ -98,7 +98,7 @@ gd_t *global_data; " move.l (%%a0), %%a0\n" \ " jmp (%%a0)\n" \ : : "i"(offsetof(gd_t, jt)), "i"(XF_ ## x * sizeof(void *)) : "a0"); -#elif defined(CONFIG_MICROBLZE) +#elif defined(CONFIG_MICROBLAZE) /* * r31 holds the pointer to the global_data. r5 is a call-clobbered. */ diff --git a/include/asm-microblaze/processor.h b/include/asm-microblaze/processor.h new file mode 100644 index 0000000..78b8976 --- /dev/null +++ b/include/asm-microblaze/processor.h @@ -0,0 +1 @@ +/* FIXME: Implement this! */ diff --git a/include/asm-microblaze/suzaku.h b/include/asm-microblaze/suzaku.h index 4d2b270..c57a144 100644 --- a/include/asm-microblaze/suzaku.h +++ b/include/asm-microblaze/suzaku.h @@ -22,4 +22,6 @@ * MA 02111-1307 USA */ -/* EMPTY FILE */ +/* System Register (GPIO) */ +#define MICROBLAZE_SYSREG_BASE_ADDR 0xFFFFA000 +#define MICROBLAZE_SYSREG_RECONFIGURE (1 << 0) diff --git a/include/configs/suzaku.h b/include/configs/suzaku.h index 5c5cdf4..e8c4373 100644 --- a/include/configs/suzaku.h +++ b/include/configs/suzaku.h @@ -36,7 +36,7 @@ * (easy to change) */ -#define CONFIG_MICROBLZE 1 /* This is an MicroBlaze CPU */ +#define CONFIG_MICROBLAZE 1 /* This is an MicroBlaze CPU */ #define CONFIG_SUZAKU 1 /* on an SUZAKU Board */ /*----------------------------------------------------------------------- @@ -47,6 +47,7 @@ #define CFG_SDRAM_BASE 0x80000000 #define CFG_SDRAM_SIZE 0x01000000 #define CFG_FLASH_BASE 0xfff00000 +#define CFG_FLASH_SIZE 0x00400000 #define CFG_RESET_ADDRESS 0xfff00100 #define CFG_MONITOR_LEN (256 << 10) /* Reserve 256 kB for Monitor */ #define CFG_MONITOR_BASE (CFG_SDRAM_BASE + CFG_SDRAM_SIZE - (1024 * 1024)) @@ -87,4 +88,14 @@ #define CFG_ENV_SIZE 0x10000 /* Total Size of Environment Sector */ #define CFG_ENV_SECT_SIZE 0x10000 /* see README - env sector total size */ +/*----------------------------------------------------------------------- + * Definitions for initial stack pointer and data area (in DPRAM) + */ + +#define CFG_INIT_RAM_ADDR 0x80000000 /* inside of SDRAM */ +#define CFG_INIT_RAM_END 0x2000 /* End of used area in RAM */ +#define CFG_GBL_DATA_SIZE 128 /* size in bytes reserved for initial data */ +#define CFG_GBL_DATA_OFFSET (CFG_INIT_RAM_END - CFG_GBL_DATA_SIZE) +#define CFG_INIT_SP_OFFSET CFG_GBL_DATA_OFFSET + #endif /* __CONFIG_H */ diff --git a/lib_microblaze/Makefile b/lib_microblaze/Makefile index b683da8..ec01722 100644 --- a/lib_microblaze/Makefile +++ b/lib_microblaze/Makefile @@ -27,7 +27,7 @@ LIB = lib$(ARCH).a AOBJS = -COBJS = board.o microblaze_linux.o time.o +COBJS = board.o microblaze_linux.o time.o cache.o OBJS = $(AOBJS) $(COBJS) diff --git a/lib_microblaze/board.c b/lib_microblaze/board.c index b720e82..bc987a3 100644 --- a/lib_microblaze/board.c +++ b/lib_microblaze/board.c @@ -72,8 +72,21 @@ init_fnc_t *init_sequence[] = { void board_init(void) { + DECLARE_GLOBAL_DATA_PTR; + + bd_t *bd; init_fnc_t **init_fnc_ptr; + /* Pointer is writable since we allocated a register for it. */ + gd = (gd_t *)CFG_GBL_DATA_OFFSET; + memset((void *)gd, 0, CFG_GBL_DATA_SIZE); + + gd->bd = (bd_t *)(gd+1); /* At end of global data */ + gd->baudrate = CONFIG_BAUDRATE; + + bd = gd->bd; + bd->bi_baudrate = CONFIG_BAUDRATE; + for (init_fnc_ptr = init_sequence; *init_fnc_ptr; ++init_fnc_ptr) { WATCHDOG_RESET (); if ((*init_fnc_ptr) () != 0) { diff --git a/lib_microblaze/cache.c b/lib_microblaze/cache.c new file mode 100644 index 0000000..a2f7493 --- /dev/null +++ b/lib_microblaze/cache.c @@ -0,0 +1,31 @@ +/* + * (C) Copyright 2004 Atmark Techno, Inc. + * + * Yasushi SHOJI <yashi@atmark-techno.com> + * + * See file CREDITS for list of people who contributed to this + * project. + * + * This program is free software; you can redistribute it and/or + * modify it under the terms of the GNU General Public License as + * published by the Free Software Foundation; either version 2 of + * the License, or (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 59 Temple Place, Suite 330, Boston, + * MA 02111-1307 USA + */ + +#include <common.h> + +void flush_cache (ulong addr, ulong size) +{ + /* MicroBlaze have write thruough cache. nothing to do. */ + return; +} diff --git a/microblaze_config.mk b/microblaze_config.mk index cd7548c..b3ac8e0 100644 --- a/microblaze_config.mk +++ b/microblaze_config.mk @@ -22,6 +22,8 @@ # MA 02111-1307 USA # +PLATFORM_CPPFLAGS += -ffixed-r31 + ifdef CONFIG_MICROBLAZE_HARD_MULT PLATFORM_CPPFLAGS += -mno-xl-soft-mul endif |