From patchwork Fri Sep 30 11:19:01 2011 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Sanjeev Premi X-Patchwork-Id: 117099 X-Patchwork-Delegate: trini@ti.com Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from theia.denx.de (theia.denx.de [85.214.87.163]) by ozlabs.org (Postfix) with ESMTP id 2D071B6F72 for ; Fri, 30 Sep 2011 21:20:33 +1000 (EST) Received: from localhost (localhost [127.0.0.1]) by theia.denx.de (Postfix) with ESMTP id 79BAD285D6; Fri, 30 Sep 2011 13:20:15 +0200 (CEST) X-Virus-Scanned: Debian amavisd-new at theia.denx.de Received: from theia.denx.de ([127.0.0.1]) by localhost (theia.denx.de [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id Iw-KqzDWbFqb; Fri, 30 Sep 2011 13:20:15 +0200 (CEST) Received: from theia.denx.de (localhost [127.0.0.1]) by theia.denx.de (Postfix) with ESMTP id E6C57285D4; Fri, 30 Sep 2011 13:20:08 +0200 (CEST) Received: from localhost (localhost [127.0.0.1]) by theia.denx.de (Postfix) with ESMTP id 1DA7C28586 for ; Fri, 30 Sep 2011 13:19:32 +0200 (CEST) X-Virus-Scanned: Debian amavisd-new at theia.denx.de Received: from theia.denx.de ([127.0.0.1]) by localhost (theia.denx.de [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id ySOlsInNN-vN for ; Fri, 30 Sep 2011 13:19:31 +0200 (CEST) X-policyd-weight: NOT_IN_SBL_XBL_SPAMHAUS=-1.5 NOT_IN_SPAMCOP=-1.5 NOT_IN_BL_NJABL=-1.5 (only DNSBL check requested) Received: from comal.ext.ti.com (comal.ext.ti.com [198.47.26.152]) by theia.denx.de (Postfix) with ESMTPS id 506922851C for ; Fri, 30 Sep 2011 13:19:21 +0200 (CEST) Received: from dbdp20.itg.ti.com ([172.24.170.38]) by comal.ext.ti.com (8.13.7/8.13.7) with ESMTP id p8UBJGue001377 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO) for ; Fri, 30 Sep 2011 06:19:18 -0500 Received: from dbde70.ent.ti.com (localhost [127.0.0.1]) by dbdp20.itg.ti.com (8.13.8/8.13.8) with ESMTP id p8UBJF4J001790 for ; Fri, 30 Sep 2011 16:49:15 +0530 (IST) Received: from dbdp31.itg.ti.com (172.24.170.98) by DBDE70.ent.ti.com (172.24.170.148) with Microsoft SMTP Server id 8.3.106.1; Fri, 30 Sep 2011 16:49:15 +0530 Received: from localhost.localdomain (dbdp20.itg.ti.com [172.24.170.38]) by dbdp31.itg.ti.com (8.13.8/8.13.8) with ESMTP id p8UBJ7q2004583; Fri, 30 Sep 2011 16:49:15 +0530 (IST) From: Sanjeev Premi To: Date: Fri, 30 Sep 2011 16:49:01 +0530 Message-ID: <1317381541-2137-7-git-send-email-premi@ti.com> X-Mailer: git-send-email 1.7.0.4 In-Reply-To: <1317381541-2137-1-git-send-email-premi@ti.com> References: <1317381541-2137-1-git-send-email-premi@ti.com> MIME-Version: 1.0 Subject: [U-Boot] [PATCH 6/6] omap3evm: fix errors caused by multiple definitions X-BeenThere: u-boot@lists.denx.de X-Mailman-Version: 2.1.9 Precedence: list List-Id: U-Boot discussion List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: u-boot-bounces@lists.denx.de Errors-To: u-boot-bounces@lists.denx.de Fix these errors when building with recently added omap3_evm_quick_nand_config: env_nowhere.o: In function `env_relocate_spec': /home/premi/u-boot/common/env_nowhere.c:40: multiple definition of `env_relocate_spec' env_nand.o:/home/premi/u-boot/common/env_nand.c:416: first defi ned here env_nowhere.o: In function `env_get_char_spec': /home/premi/u-boot/common/env_nowhere.c:44: multiple definition of `env_get_char_spec' env_nand.o:/home/premi/u-boot/common/env_nand.c:77: first defin ed here env_nowhere.o: In function `env_init': /home/premi/u-boot/common/env_nowhere.c:54: multiple definition of `env_init' env_nand.o:/home/premi/u-boot/common/env_nand.c:144: first defi ned here env_nowhere.o: In function `env_relocate_spec': /home/premi/u-boot/common/env_nowhere.c:40: multiple definition of `env_ptr' env_nand.o:/home/premi/u-boot/common/env_nand.c:77: first defin ed here Signed-off-by: Sanjeev Premi --- include/configs/omap3_evm_common.h | 7 ++++++- 1 files changed, 6 insertions(+), 1 deletions(-) diff --git a/include/configs/omap3_evm_common.h b/include/configs/omap3_evm_common.h index baa74bf..7a5f602 100644 --- a/include/configs/omap3_evm_common.h +++ b/include/configs/omap3_evm_common.h @@ -239,15 +239,20 @@ #define CONFIG_NAND_OMAP_GPMC #define GPMC_NAND_ECC_LP_x16_LAYOUT -#define CONFIG_ENV_IS_IN_NAND #define CONFIG_ENV_OFFSET SMNAND_ENV_OFFSET #elif defined(CONFIG_CMD_ONENAND) #define CONFIG_SYS_FLASH_BASE PISMO1_ONEN_BASE #define CONFIG_SYS_ONENAND_BASE ONENAND_MAP +#endif +#if !defined(CONFIG_ENV_IS_NOWHERE) +#if defined(CONFIG_CMD_NAND) +#define CONFIG_ENV_IS_IN_NAND +#elif defined(CONFIG_CMD_ONENAND) #define CONFIG_ENV_IS_IN_ONENAND #define CONFIG_ENV_OFFSET ONENAND_ENV_OFFSET #endif +#endif /* CONFIG_ENV_IS_NOWHERE */ #define CONFIG_ENV_ADDR CONFIG_ENV_OFFSET