From patchwork Wed Sep 11 11:17:39 2013 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Valentin Longchamp X-Patchwork-Id: 274244 X-Patchwork-Delegate: yorksun@freescale.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 CE22F2C017E for ; Wed, 11 Sep 2013 21:18:40 +1000 (EST) Received: from localhost (localhost [127.0.0.1]) by theia.denx.de (Postfix) with ESMTP id 85F854A07B; Wed, 11 Sep 2013 13:18:38 +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 bXT4ppZiQtLb; Wed, 11 Sep 2013 13:18:38 +0200 (CEST) Received: from theia.denx.de (localhost [127.0.0.1]) by theia.denx.de (Postfix) with ESMTP id 296F64A099; Wed, 11 Sep 2013 13:18:11 +0200 (CEST) Received: from localhost (localhost [127.0.0.1]) by theia.denx.de (Postfix) with ESMTP id E50B64A08B for ; Wed, 11 Sep 2013 13:18:06 +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 M+rOFG5-GQ+b for ; Wed, 11 Sep 2013 13:18:06 +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 mail-de.keymile.com (mail-de.keymile.com [195.8.104.250]) by theia.denx.de (Postfix) with ESMTPS id 5B6B34A060 for ; Wed, 11 Sep 2013 13:17:55 +0200 (CEST) Received: from [10.9.1.54] (port=41348 helo=mailrelay.de.keymile.net) by mail-de.keymile.com with esmtp (Exim 4.76) (envelope-from ) id 1VJiQj-0008Aw-11; Wed, 11 Sep 2013 13:17:53 +0200 Received: from chber1-10533x.keymile.net (chber1-10533x.keymile.net [172.31.40.3]) by mailrelay.de.keymile.net (8.12.2/8.12.2) with ESMTP id r8BBFT1b006908; Wed, 11 Sep 2013 13:15:34 +0200 (MEST) From: Valentin Longchamp To: Andy Fleming , Scott Wood , York Sun Date: Wed, 11 Sep 2013 13:17:39 +0200 Message-Id: <1378898265-10818-6-git-send-email-valentin.longchamp@keymile.com> X-Mailer: git-send-email 1.8.0.1 In-Reply-To: <1378898265-10818-1-git-send-email-valentin.longchamp@keymile.com> References: <1378898265-10818-1-git-send-email-valentin.longchamp@keymile.com> Cc: U-Boot Mailing List , Holger Brunck , Valentin Longchamp Subject: [U-Boot] [PATCH v3 05/11] KM: add CONFIG_KM_COMMON_ETH_INIT for km common eth init X-BeenThere: u-boot@lists.denx.de X-Mailman-Version: 2.1.11 Precedence: list List-Id: U-Boot discussion List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Sender: u-boot-bounces@lists.denx.de Errors-To: u-boot-bounces@lists.denx.de This must be defined by a board support file that want to use the keymile common.c board_eth_init function that requires ethernet_present to be defined. Currently all the km architectures use it but the kmp204x architecture later supported in this series does use another board_eth_init function and thus does not define it. Signed-off-by: Valentin Longchamp --- Changes in v3: None Changes in v2: - add CONFIG_KM_COMMON_ETH_INIT for the km board that need the common.c board_eth_init board/keymile/common/common.c | 2 ++ include/configs/km/km-powerpc.h | 3 +++ include/configs/km/km_arm.h | 1 + 3 files changed, 6 insertions(+) diff --git a/board/keymile/common/common.c b/board/keymile/common/common.c index cc71d89..305ad98 100644 --- a/board/keymile/common/common.c +++ b/board/keymile/common/common.c @@ -142,6 +142,7 @@ void i2c_init_board(void) } #endif +#if defined(CONFIG_KM_COMMON_ETH_INIT) int board_eth_init(bd_t *bis) { if (ethernet_present()) @@ -149,6 +150,7 @@ int board_eth_init(bd_t *bis) return -1; } +#endif /* * do_setboardid command diff --git a/include/configs/km/km-powerpc.h b/include/configs/km/km-powerpc.h index 1a12399..c648fde 100644 --- a/include/configs/km/km-powerpc.h +++ b/include/configs/km/km-powerpc.h @@ -17,6 +17,9 @@ #define CONFIG_CMD_DTT #define CONFIG_JFFS2_CMDLINE +/* standard km ethernet_present for piggy */ +#define CONFIG_KM_COMMON_ETH_INIT + /* EEprom support 24C08, 24C16, 24C64 */ #define CONFIG_SYS_I2C_MULTI_EEPROMS #define CONFIG_SYS_EEPROM_PAGE_WRITE_ENABLE diff --git a/include/configs/km/km_arm.h b/include/configs/km/km_arm.h index 36c2fba..e74f85f 100644 --- a/include/configs/km/km_arm.h +++ b/include/configs/km/km_arm.h @@ -164,6 +164,7 @@ #define CONFIG_MVGBE_PORTS {1, 0} /* enable port 0 only */ #define CONFIG_PHY_BASE_ADR 0 #define CONFIG_ENV_OVERWRITE /* ethaddr can be reprogrammed */ +#define CONFIG_KM_COMMON_ETH_INIT /* standard km ethernet_present for piggy */ /* * UBI related stuff