From patchwork Fri Oct 15 13:16:16 2010 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Tanmay Upadhyay X-Patchwork-Id: 71869 Return-Path: X-Original-To: wd@gemini.denx.de Delivered-To: wd@gemini.denx.de Received: from diddl.denx.de (diddl.denx.de [10.0.0.6]) by gemini.denx.de (Postfix) with ESMTP id 8A09E1365CC for ; Fri, 15 Oct 2010 15:12:27 +0200 (CEST) Received: from diddl.denx.de (localhost.localdomain [127.0.0.1]) by diddl.denx.de (Postfix) with ESMTP id 744CC3230C06 for ; Fri, 15 Oct 2010 15:12:27 +0200 (CEST) Received: from pop.mnet-online.de by diddl.denx.de with POP3 (fetchmail-6.3.17) for (single-drop); Fri, 15 Oct 2010 15:12:27 +0200 (CEST) Received: from murder ([192.168.8.180]) by backend2 (Cyrus v2.2.12) with LMTPA; Fri, 15 Oct 2010 15:12:17 +0200 X-Sieve: CMU Sieve 2.2 Received: from mail.m-online.net (localhost [127.0.0.1]) by frontend1.mail.m-online.net (Cyrus v2.2.12) with LMTPA; Fri, 15 Oct 2010 15:12:16 +0200 Received: from scanner-3.m-online.net (unknown [192.168.6.168]) by mail.m-online.net (Postfix) with ESMTP id 7F3111C00324; Fri, 15 Oct 2010 15:12:16 +0200 (CEST) Received: from theia.denx.de (theia.denx.de [85.214.87.163]) by mxin-3.m-online.net (Postfix) with ESMTP id 4D9B946C0A4; Fri, 15 Oct 2010 15:12:14 +0200 (CEST) Received: from localhost (localhost [127.0.0.1]) by theia.denx.de (Postfix) with ESMTP id EA71B2809D; Fri, 15 Oct 2010 15:12:02 +0200 (CEST) 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 roCrPMmrXz3X; Fri, 15 Oct 2010 15:12:02 +0200 (CEST) Received: from theia.denx.de (localhost [127.0.0.1]) by theia.denx.de (Postfix) with ESMTP id 499A42809C; Fri, 15 Oct 2010 15:11:51 +0200 (CEST) Received: from localhost (localhost [127.0.0.1]) by theia.denx.de (Postfix) with ESMTP id 19C4228084 for ; Fri, 15 Oct 2010 15:11:49 +0200 (CEST) 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 Z6HJ+HIS9Z5u for ; Fri, 15 Oct 2010 15:11:48 +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 ahm.einfochips.com (ahm.einfochips.com [203.88.139.151]) by theia.denx.de (Postfix) with ESMTP id B25CD2808B for ; Fri, 15 Oct 2010 15:11:46 +0200 (CEST) Received: from localhost (localhost.localdomain [127.0.0.1]) by ahm.einfochips.com (Postfix) with ESMTP id B1EB3A608039; Fri, 15 Oct 2010 18:40:18 +0530 (IST) Received: from ahm.einfochips.com ([127.0.0.1]) by localhost (ahm.einfochips.com [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id oAYWPJ4RqpJB; Fri, 15 Oct 2010 18:40:18 +0530 (IST) Received: from localhost.localdomain (unknown [192.168.8.253]) by ahm.einfochips.com (Postfix) with ESMTPA id 9CC32A60801E; Fri, 15 Oct 2010 18:40:18 +0530 (IST) From: Tanmay Upadhyay To: prafulla@marvell.com, simon.kagstrom@netinsight.net Date: Fri, 15 Oct 2010 18:46:16 +0530 Message-Id: <1287148576-25446-1-git-send-email-tanmay.upadhyay@einfochips.com> X-Mailer: git-send-email 1.6.6.1 Cc: u-boot@lists.denx.de, Tanmay Upadhyay Subject: [U-Boot] [PATCH 2/2] Kirkwood: OpenRD: Initialize MPPs during early init 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: , MIME-Version: 1.0 Sender: u-boot-bounces@lists.denx.de Errors-To: u-boot-bounces@lists.denx.de X-Virus-Scanned: by amavisd-new at m-online.net This patch adds board_early_init_f function for OpenRD boards. The function initializes MPPs so that peripherals can work at early stage. Signed-off-by: Tanmay Upadhyay --- board/Marvell/openrd/openrd.c | 6 +++++- include/configs/openrd.h | 2 ++ 2 files changed, 7 insertions(+), 1 deletions(-) diff --git a/board/Marvell/openrd/openrd.c b/board/Marvell/openrd/openrd.c index 3953282..2d34a24 100644 --- a/board/Marvell/openrd/openrd.c +++ b/board/Marvell/openrd/openrd.c @@ -41,7 +41,7 @@ DECLARE_GLOBAL_DATA_PTR; -int board_init(void) +int board_early_init_f(void) { /* * default gpio configuration @@ -108,7 +108,11 @@ int board_init(void) }; kirkwood_mpp_conf(kwmpp_config); + return 0; +} +int board_init(void) +{ /* * arch number of board */ diff --git a/include/configs/openrd.h b/include/configs/openrd.h index c4dcad6..850dbae 100644 --- a/include/configs/openrd.h +++ b/include/configs/openrd.h @@ -110,4 +110,6 @@ #define CONFIG_SYS_ATA_IDE1_OFFSET MV_SATA_PORT1_OFFSET #endif /*CONFIG_MVSATA_IDE*/ +/* board_early_init_f function in openrd.c initializes all MPP settings */ +#define CONFIG_BOARD_EARLY_INIT_F #endif /* _CONFIG_OPENRD_H */