public inbox for u-boot@lists.denx.de
 help / color / mirror / Atom feed
* [U-Boot] [PATCH v2 0/3] MIPS: Fix failed run of MAKEALL mips script
@ 2011-02-03 13:17 daniel.schwierzeck at googlemail.com
  2011-02-03 13:17 ` [U-Boot] [PATCH v2 1/3] MIPS: VCT: Fix enabling of unwanted options if networking or USB support are disabled daniel.schwierzeck at googlemail.com
                   ` (3 more replies)
  0 siblings, 4 replies; 5+ messages in thread
From: daniel.schwierzeck at googlemail.com @ 2011-02-03 13:17 UTC (permalink / raw)
  To: u-boot

Currently MAKEALL mips covers 21 boards and 15 of them have compile
errors with gcc-4.3.3. This patch series fixes these boards.

Changes for v2:
- make brace style consistent in vct.h
- delete unused board/dbau1x00/flash.c

Daniel Schwierzeck (3):
  MIPS: VCT: Fix enabling of unwanted options if networking or USB
    support are disabled
  MIPS: Purple: Fix multiple definition error on final linking of
    u-boot binary
  MIPS: dbau1x00: Remove unused flash driver stub

 board/dbau1x00/Makefile |    2 +-
 board/dbau1x00/flash.c  |   43 -------------------------------------------
 board/purple/u-boot.lds |    5 -----
 include/configs/vct.h   |    7 +++++--
 4 files changed, 6 insertions(+), 51 deletions(-)
 delete mode 100644 board/dbau1x00/flash.c

--
1.7.3.5

^ permalink raw reply	[flat|nested] 5+ messages in thread

* [U-Boot] [PATCH v2 1/3] MIPS: VCT: Fix enabling of unwanted options if networking or USB support are disabled
  2011-02-03 13:17 [U-Boot] [PATCH v2 0/3] MIPS: Fix failed run of MAKEALL mips script daniel.schwierzeck at googlemail.com
@ 2011-02-03 13:17 ` daniel.schwierzeck at googlemail.com
  2011-02-03 13:17 ` [U-Boot] [PATCH v2 2/3] MIPS: Purple: Fix multiple definition error on final linking of u-boot binary daniel.schwierzeck at googlemail.com
                   ` (2 subsequent siblings)
  3 siblings, 0 replies; 5+ messages in thread
From: daniel.schwierzeck at googlemail.com @ 2011-02-03 13:17 UTC (permalink / raw)
  To: u-boot

Some VCT boards lacks the support of networking or USB.
Additionally that support is disabled in small image
configurations.

If CONFIG_CMD_NET should not used the CONFIG_CMD_NFS option
have to be disabled too. Otherwise the linker fails with
unresolved symbols.

If CONFIG_VCT_SMALL_IMAGE is set than CONFIG_CMD_NET and
CONFIG_CMD_USB are disabled at the end of vct.h.
This is not adequate because CONFIG_CMD_USB enables additional
options and the linker fails again with unresolved symbols.

This patch adds an early check against CONFIG_VCT_SMALL_IMAGE
so the additional options are only enabled if they are really
needed.

Signed-off-by: Daniel Schwierzeck <daniel.schwierzeck@googlemail.com>
Acked-by: Stefan Roese <sr@denx.de>
---
 include/configs/vct.h |    7 +++++--
 1 files changed, 5 insertions(+), 2 deletions(-)

diff --git a/include/configs/vct.h b/include/configs/vct.h
index 4894969..325ac8c 100644
--- a/include/configs/vct.h
+++ b/include/configs/vct.h
@@ -109,17 +109,20 @@
 /*
  * Only Premium/Platinum have ethernet support right now
  */
-#if defined(CONFIG_VCT_PREMIUM) || defined(CONFIG_VCT_PLATINUM)
+#if (defined(CONFIG_VCT_PREMIUM) || defined(CONFIG_VCT_PLATINUM)) && \
+	!defined(CONFIG_VCT_SMALL_IMAGE)
 #define CONFIG_CMD_PING
 #define CONFIG_CMD_SNTP
 #else
 #undef CONFIG_CMD_NET
+#undef CONFIG_CMD_NFS
 #endif

 /*
  * Only Premium/Platinum have USB-EHCI support right now
  */
-#if defined(CONFIG_VCT_PREMIUM) || defined(CONFIG_VCT_PLATINUM)
+#if (defined(CONFIG_VCT_PREMIUM) || defined(CONFIG_VCT_PLATINUM)) && \
+	!defined(CONFIG_VCT_SMALL_IMAGE)
 #define CONFIG_CMD_USB
 #define CONFIG_CMD_FAT
 #endif
--
1.7.3.5

^ permalink raw reply related	[flat|nested] 5+ messages in thread

* [U-Boot] [PATCH v2 2/3] MIPS: Purple: Fix multiple definition error on final linking of u-boot binary
  2011-02-03 13:17 [U-Boot] [PATCH v2 0/3] MIPS: Fix failed run of MAKEALL mips script daniel.schwierzeck at googlemail.com
  2011-02-03 13:17 ` [U-Boot] [PATCH v2 1/3] MIPS: VCT: Fix enabling of unwanted options if networking or USB support are disabled daniel.schwierzeck at googlemail.com
@ 2011-02-03 13:17 ` daniel.schwierzeck at googlemail.com
  2011-02-03 13:17 ` [U-Boot] [PATCH v2 3/3] MIPS: dbau1x00: Remove unused flash driver stub daniel.schwierzeck at googlemail.com
  2011-02-05 13:57 ` [U-Boot] [PATCH v2 0/3] MIPS: Fix failed run of MAKEALL mips script Shinya Kuribayashi
  3 siblings, 0 replies; 5+ messages in thread
From: daniel.schwierzeck at googlemail.com @ 2011-02-03 13:17 UTC (permalink / raw)
  To: u-boot

The linker of recent toolchains complains about multiple definitions
on final linking of u-boot binary. This patch removes all redundant
object files from u-boot.lds those are already added to .text section
by the linker.

That patch could not be tested but the resulting u-boot.map still looks
good. The start symbol is at 0xB0000000, the environment at 0xB0008000
so u-boot should boot.

Signed-off-by: Daniel Schwierzeck <daniel.schwierzeck@googlemail.com>
Cc: Wolfgang Denk <wd@denx.de>
---
 board/purple/u-boot.lds |    5 -----
 1 files changed, 0 insertions(+), 5 deletions(-)

diff --git a/board/purple/u-boot.lds b/board/purple/u-boot.lds
index 542601a..719f268 100644
--- a/board/purple/u-boot.lds
+++ b/board/purple/u-boot.lds
@@ -36,11 +36,6 @@ SECTIONS
 	{
 	  arch/mips/cpu/start.o		(.text)
 	  board/purple/lowlevel_init.o	(.text)
-	  arch/mips/cpu/cache.o		(.text)
-	  common/main.o			(.text)
-	  common/dlmalloc.o		(.text)
-	  common/cmd_boot.o		(.text)
-	  lib/zlib.o		(.text)
 	  . = DEFINED(env_offset) ? env_offset : .;
 	  common/env_embedded.o	(.ppcenv)

--
1.7.3.5

^ permalink raw reply related	[flat|nested] 5+ messages in thread

* [U-Boot] [PATCH v2 3/3] MIPS: dbau1x00: Remove unused flash driver stub
  2011-02-03 13:17 [U-Boot] [PATCH v2 0/3] MIPS: Fix failed run of MAKEALL mips script daniel.schwierzeck at googlemail.com
  2011-02-03 13:17 ` [U-Boot] [PATCH v2 1/3] MIPS: VCT: Fix enabling of unwanted options if networking or USB support are disabled daniel.schwierzeck at googlemail.com
  2011-02-03 13:17 ` [U-Boot] [PATCH v2 2/3] MIPS: Purple: Fix multiple definition error on final linking of u-boot binary daniel.schwierzeck at googlemail.com
@ 2011-02-03 13:17 ` daniel.schwierzeck at googlemail.com
  2011-02-05 13:57 ` [U-Boot] [PATCH v2 0/3] MIPS: Fix failed run of MAKEALL mips script Shinya Kuribayashi
  3 siblings, 0 replies; 5+ messages in thread
From: daniel.schwierzeck at googlemail.com @ 2011-02-03 13:17 UTC (permalink / raw)
  To: u-boot

All dbau1x00 boards use the CFI driver so this stub driver is useless
and should not be compiled.

This patch fixes the error:

u-boot-git/board/dbau1x00/flash.c:34: multiple definition of `flash_init'
drivers/mtd/libmtd.o:u-boot-git/drivers/mtd/cfi_flash.c:2084: first defined here
board/dbau1x00/libdbau1x00.o: In function `write_buff':
u-boot-git/board/dbau1x00/flash.c:40: multiple definition of `write_buff'
drivers/mtd/libmtd.o:u-boot-git/drivers/mtd/cfi_flash.c:1265: first defined here

Signed-off-by: Daniel Schwierzeck <daniel.schwierzeck@googlemail.com>
Cc: Wolfgang Denk <wd@denx.de>
---
 board/dbau1x00/Makefile |    2 +-
 board/dbau1x00/flash.c  |   43 -------------------------------------------
 2 files changed, 1 insertions(+), 44 deletions(-)
 delete mode 100644 board/dbau1x00/flash.c

diff --git a/board/dbau1x00/Makefile b/board/dbau1x00/Makefile
index f1594a2..e36a9d2 100644
--- a/board/dbau1x00/Makefile
+++ b/board/dbau1x00/Makefile
@@ -25,7 +25,7 @@ include $(TOPDIR)/config.mk

 LIB	= $(obj)lib$(BOARD).o

-COBJS	= $(BOARD).o flash.o
+COBJS	= $(BOARD).o
 SOBJS	= lowlevel_init.o

 SRCS	:= $(SOBJS:.o=.S) $(COBJS:.o=.c)
diff --git a/board/dbau1x00/flash.c b/board/dbau1x00/flash.c
deleted file mode 100644
index a2fed1d..0000000
--- a/board/dbau1x00/flash.c
+++ /dev/null
@@ -1,43 +0,0 @@
-/*
- * (C) Copyright 2003
- * Wolfgang Denk, DENX Software Engineering, wd at denx.de.
- *
- * 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>
-
-flash_info_t flash_info[CONFIG_SYS_MAX_FLASH_BANKS];	/* info for FLASH chips */
-
-/*-----------------------------------------------------------------------
- * flash_init()
- *
- * sets up flash_info and returns size of FLASH (bytes)
- */
-unsigned long flash_init (void)
-{
-	printf ("Skipping flash_init\n");
-	return (0);
-}
-
-int write_buff (flash_info_t * info, uchar * src, ulong addr, ulong cnt)
-{
-	printf ("write_buff not implemented\n");
-	return (-1);
-}
--
1.7.3.5

^ permalink raw reply related	[flat|nested] 5+ messages in thread

* [U-Boot] [PATCH v2 0/3] MIPS: Fix failed run of MAKEALL mips script
  2011-02-03 13:17 [U-Boot] [PATCH v2 0/3] MIPS: Fix failed run of MAKEALL mips script daniel.schwierzeck at googlemail.com
                   ` (2 preceding siblings ...)
  2011-02-03 13:17 ` [U-Boot] [PATCH v2 3/3] MIPS: dbau1x00: Remove unused flash driver stub daniel.schwierzeck at googlemail.com
@ 2011-02-05 13:57 ` Shinya Kuribayashi
  3 siblings, 0 replies; 5+ messages in thread
From: Shinya Kuribayashi @ 2011-02-05 13:57 UTC (permalink / raw)
  To: u-boot

On 02/03/2011 10:17 PM, daniel.schwierzeck at googlemail.com wrote:
> Currently MAKEALL mips covers 21 boards and 15 of them have compile
> errors with gcc-4.3.3. This patch series fixes these boards.
> 
> Changes for v2:
> - make brace style consistent in vct.h
> - delete unused board/dbau1x00/flash.c

All three patches applied, thanks.

^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2011-02-05 13:57 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2011-02-03 13:17 [U-Boot] [PATCH v2 0/3] MIPS: Fix failed run of MAKEALL mips script daniel.schwierzeck at googlemail.com
2011-02-03 13:17 ` [U-Boot] [PATCH v2 1/3] MIPS: VCT: Fix enabling of unwanted options if networking or USB support are disabled daniel.schwierzeck at googlemail.com
2011-02-03 13:17 ` [U-Boot] [PATCH v2 2/3] MIPS: Purple: Fix multiple definition error on final linking of u-boot binary daniel.schwierzeck at googlemail.com
2011-02-03 13:17 ` [U-Boot] [PATCH v2 3/3] MIPS: dbau1x00: Remove unused flash driver stub daniel.schwierzeck at googlemail.com
2011-02-05 13:57 ` [U-Boot] [PATCH v2 0/3] MIPS: Fix failed run of MAKEALL mips script Shinya Kuribayashi

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox