From f6fd4140a5c7141a58a4e890951c9415be5347c4 Mon Sep 17 00:00:00 2001 From: Gabor Juhos Date: Sun, 26 May 2013 12:11:31 +0200 Subject: nds32: adp-ag102: use 'faraday/ftpci100.h' for pci_ftpci_init Due to improper external function declaration, building U-Boot for the adp-ag102 board shows this warning: adp-ag102.c: In function 'pci_init_board': adp-ag102.c:95: warning: function declaration isn't a prototype Include the 'faraday/ftpci100.h' header which provides the proper declaration and remove the local declaration to get rid of the warning. Compile tested only. Cc: Macpaul Lin Signed-off-by: Gabor Juhos --- board/AndesTech/adp-ag102/adp-ag102.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) (limited to 'board/AndesTech') diff --git a/board/AndesTech/adp-ag102/adp-ag102.c b/board/AndesTech/adp-ag102/adp-ag102.c index 5a25632..1b56dac 100644 --- a/board/AndesTech/adp-ag102/adp-ag102.c +++ b/board/AndesTech/adp-ag102/adp-ag102.c @@ -25,6 +25,7 @@ #include #include +#include #include #ifdef CONFIG_FTSMC020 #include @@ -92,8 +93,6 @@ ulong board_flash_get_legacy(ulong base, int banknum, flash_info_t *info) void pci_init_board(void) { /* should be pci_ftpci100_init() */ - extern void pci_ftpci_init(); - pci_ftpci_init(); } #endif -- cgit v1.1 From 3c016704d9c5418479e68e4690759cb2be6f90d3 Mon Sep 17 00:00:00 2001 From: ken kuo Date: Sat, 8 Jun 2013 11:14:09 +0800 Subject: nds32: Enable two banks of SDRAM on Andes board The original adp-ag101/adp-ag101p initialize only one bank(64MB) by default at boot time, but it is not enough for some application, so increasing to two banks(128M). Signed-off-by: Kuan-Yu Kuo Cc: Macpaul Lin --- board/AndesTech/adp-ag101/adp-ag101.c | 10 +++++++++- board/AndesTech/adp-ag101p/adp-ag101p.c | 10 +++++++++- 2 files changed, 18 insertions(+), 2 deletions(-) (limited to 'board/AndesTech') diff --git a/board/AndesTech/adp-ag101/adp-ag101.c b/board/AndesTech/adp-ag101/adp-ag101.c index 82ce4c9..ebc20a5 100644 --- a/board/AndesTech/adp-ag101/adp-ag101.c +++ b/board/AndesTech/adp-ag101/adp-ag101.c @@ -50,7 +50,7 @@ int board_init(void) int dram_init(void) { unsigned long sdram_base = PHYS_SDRAM_0; - unsigned long expected_size = PHYS_SDRAM_0_SIZE; + unsigned long expected_size = PHYS_SDRAM_0_SIZE + PHYS_SDRAM_1_SIZE; unsigned long actual_size; actual_size = get_ram_size((void *)sdram_base, expected_size); @@ -65,6 +65,14 @@ int dram_init(void) return 0; } +void dram_init_banksize(void) +{ + gd->bd->bi_dram[0].start = PHYS_SDRAM_0; + gd->bd->bi_dram[0].size = PHYS_SDRAM_0_SIZE; + gd->bd->bi_dram[1].start = PHYS_SDRAM_1; + gd->bd->bi_dram[1].size = PHYS_SDRAM_1_SIZE; +} + int board_eth_init(bd_t *bd) { return ftmac100_initialize(bd); diff --git a/board/AndesTech/adp-ag101p/adp-ag101p.c b/board/AndesTech/adp-ag101p/adp-ag101p.c index 8dd2043..26d67e2 100644 --- a/board/AndesTech/adp-ag101p/adp-ag101p.c +++ b/board/AndesTech/adp-ag101p/adp-ag101p.c @@ -50,7 +50,7 @@ int board_init(void) int dram_init(void) { unsigned long sdram_base = PHYS_SDRAM_0; - unsigned long expected_size = PHYS_SDRAM_0_SIZE; + unsigned long expected_size = PHYS_SDRAM_0_SIZE + PHYS_SDRAM_1_SIZE; unsigned long actual_size; actual_size = get_ram_size((void *)sdram_base, expected_size); @@ -65,6 +65,14 @@ int dram_init(void) return 0; } +void dram_init_banksize(void) +{ + gd->bd->bi_dram[0].start = PHYS_SDRAM_0; + gd->bd->bi_dram[0].size = PHYS_SDRAM_0_SIZE; + gd->bd->bi_dram[1].start = PHYS_SDRAM_1; + gd->bd->bi_dram[1].size = PHYS_SDRAM_1_SIZE; +} + int board_eth_init(bd_t *bd) { return ftmac100_initialize(bd); -- cgit v1.1 From 951344b778d6ac67b94011d942a5a55da7202027 Mon Sep 17 00:00:00 2001 From: ken kuo Date: Thu, 25 Jul 2013 02:24:54 +0800 Subject: nds32: Convert Makefiles to use COBJS-y style Signed-off-by: Kuan-Yu Kuo Cc: Macpaul Lin --- board/AndesTech/adp-ag101/Makefile | 6 +++--- board/AndesTech/adp-ag101p/Makefile | 6 +++--- board/AndesTech/adp-ag102/Makefile | 4 ++-- 3 files changed, 8 insertions(+), 8 deletions(-) (limited to 'board/AndesTech') diff --git a/board/AndesTech/adp-ag101/Makefile b/board/AndesTech/adp-ag101/Makefile index d55a799..867e1cf 100644 --- a/board/AndesTech/adp-ag101/Makefile +++ b/board/AndesTech/adp-ag101/Makefile @@ -26,10 +26,10 @@ include $(TOPDIR)/config.mk LIB = $(obj)lib$(BOARD).o -COBJS := adp-ag101.o +COBJS-y := adp-ag101.o -SRCS := $(SOBJS:.o=.S) $(COBJS:.o=.c) -OBJS := $(addprefix $(obj),$(COBJS) $(SOBJS)) +SRCS := $(SOBJS-y:.o=.S) $(COBJS-y:.o=.c) +OBJS := $(addprefix $(obj),$(COBJS-y) $(SOBJS-y)) $(LIB): $(OBJS) $(call cmd_link_o_target, $(OBJS)) diff --git a/board/AndesTech/adp-ag101p/Makefile b/board/AndesTech/adp-ag101p/Makefile index 03c3ff4..5f513c8 100644 --- a/board/AndesTech/adp-ag101p/Makefile +++ b/board/AndesTech/adp-ag101p/Makefile @@ -26,10 +26,10 @@ include $(TOPDIR)/config.mk LIB = $(obj)lib$(BOARD).o -COBJS := adp-ag101p.o +COBJS-y := adp-ag101p.o -SRCS := $(SOBJS:.o=.S) $(COBJS:.o=.c) -OBJS := $(addprefix $(obj),$(COBJS) $(SOBJS)) +SRCS := $(SOBJS-y:.o=.S) $(COBJS-y:.o=.c) +OBJS := $(addprefix $(obj),$(COBJS-y) $(SOBJS-y)) $(LIB): $(OBJS) $(call cmd_link_o_target, $(OBJS)) diff --git a/board/AndesTech/adp-ag102/Makefile b/board/AndesTech/adp-ag102/Makefile index 1cbf2d4..44f117d 100644 --- a/board/AndesTech/adp-ag102/Makefile +++ b/board/AndesTech/adp-ag102/Makefile @@ -27,8 +27,8 @@ LIB = $(obj)lib$(BOARD).o COBJS := adp-ag102.o -SRCS := $(SOBJS:.o=.S) $(COBJS:.o=.c) -OBJS := $(addprefix $(obj),$(COBJS) $(SOBJS)) +SRCS := $(SOBJS-y:.o=.S) $(COBJS-y:.o=.c) +OBJS := $(addprefix $(obj),$(COBJS-y) $(SOBJS-y)) $(LIB): $(OBJS) $(call cmd_link_o_target, $(OBJS)) -- cgit v1.1