From patchwork Fri Feb 8 15:12:16 2013 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Simon Glass X-Patchwork-Id: 219195 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 9724F2C0082 for ; Sat, 9 Feb 2013 02:17:49 +1100 (EST) Received: from localhost (localhost [127.0.0.1]) by theia.denx.de (Postfix) with ESMTP id 4DC7C4A18D; Fri, 8 Feb 2013 16:17:16 +0100 (CET) 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 BSBX53-hHTmU; Fri, 8 Feb 2013 16:17:16 +0100 (CET) Received: from theia.denx.de (localhost [127.0.0.1]) by theia.denx.de (Postfix) with ESMTP id E28BB4A18E; Fri, 8 Feb 2013 16:14:38 +0100 (CET) Received: from localhost (localhost [127.0.0.1]) by theia.denx.de (Postfix) with ESMTP id BA61A4A147 for ; Fri, 8 Feb 2013 16:14:23 +0100 (CET) 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 atvMe4ux+or2 for ; Fri, 8 Feb 2013 16:14:21 +0100 (CET) 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-we0-f202.google.com (mail-we0-f202.google.com [74.125.82.202]) by theia.denx.de (Postfix) with ESMTPS id 91B724A111 for ; Fri, 8 Feb 2013 16:13:52 +0100 (CET) Received: by mail-we0-f202.google.com with SMTP id t11so265239wey.1 for ; Fri, 08 Feb 2013 07:13:52 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20120113; h=x-received:from:to:cc:subject:date:message-id:x-mailer:in-reply-to :references:x-gm-message-state; bh=E0JmW3OPdtCdlXUrSVwUOYSDEapQOwabLqaqlV8Xna0=; b=bPjYFYoqgmKcrEZMRXj3Hc87MCx4V0LXUVTJOgxx1GP22zKW0b860+imioGUCnaEqj T+AWYb9SOItJAT/CimVDBs/vIzgPQPKecmoBurwMUqZEGcEdd2iii6qKcXXSDl5+ZG57 Ji/vGETGDgPItbH1b5MhzCRDSPB0jVOMkVfAIEb9CuVwtgX9vGwL2o+abRuFnzFnNUg+ OiWZAsLRb1Zlrl/3pWG6A31tH/SuhQO4xua2cS42iGjBnNGxd0aUuQsS7UeiMk/QGZFH 9TUigDxBph5TNi83FVqp8XyHPaAiTrH2EP1p+EfEQyDAvaViDA4/LI1anIuStgwkS3Op P93Q== X-Received: by 10.14.211.1 with SMTP id v1mr5383096eeo.0.1360336432382; Fri, 08 Feb 2013 07:13:52 -0800 (PST) Received: from corp2gmr1-1.eem.corp.google.com (corp2gmr1-1.eem.corp.google.com [172.25.138.99]) by gmr-mx.google.com with ESMTPS id m6si7541116een.1.2013.02.08.07.13.52 (version=TLSv1.1 cipher=AES128-SHA bits=128/128); Fri, 08 Feb 2013 07:13:52 -0800 (PST) Received: from kaka.mtv.corp.google.com (kaka.mtv.corp.google.com [172.22.73.79]) by corp2gmr1-1.eem.corp.google.com (Postfix) with ESMTP id 25B2A1CA129; Fri, 8 Feb 2013 07:13:52 -0800 (PST) Received: by kaka.mtv.corp.google.com (Postfix, from userid 121222) id D3DEE16074A; Fri, 8 Feb 2013 07:13:51 -0800 (PST) From: Simon Glass To: U-Boot Mailing List Date: Fri, 8 Feb 2013 07:12:16 -0800 Message-Id: <1360336339-10703-21-git-send-email-sjg@chromium.org> X-Mailer: git-send-email 1.8.1 In-Reply-To: <1360336339-10703-1-git-send-email-sjg@chromium.org> References: <1360336339-10703-1-git-send-email-sjg@chromium.org> X-Gm-Message-State: ALoCoQk5pWH9K5KBvhclWKseKQf5KKidyYahixvQhbgYK5dUxBqNTOrD2RMKnxPk+wV9KtI/DdbqtZuAQRR4MxzNZnSrrbpQcmaTU+Oknj5U3V23SVqbO2dKIn/0jgj3lzZAJAoukgTwMBJoUMOY2hPx/muovEGM+q32nAR02Y2fBcj6AQGlD/CgIzboYH/05OKZ98pMt44l Cc: Graeme Russ , Tom Rini , Vadim Bendebury Subject: [U-Boot] [PATCH v5 20/23] x86: Adjust board_r.c for x86 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 For x86 the global_data is managed entirely by the start.S code so we do not need to touch it. However, we do have some more initcalls to add. Signed-off-by: Simon Glass --- Changes in v5: - Add new patch to adjust board_r.c for x86 Changes in v4: None Changes in v3: None Changes in v2: None common/board_r.c | 23 +++++++++++++++++++++-- 1 file changed, 21 insertions(+), 2 deletions(-) diff --git a/common/board_r.c b/common/board_r.c index 24d8a17..1a26a04 100644 --- a/common/board_r.c +++ b/common/board_r.c @@ -63,6 +63,9 @@ #include #endif #include +#ifdef CONFIG_X86 +#include +#endif #include DECLARE_GLOBAL_DATA_PTR; @@ -716,6 +719,9 @@ init_fnc_t init_sequence_r[] = { #ifdef CONFIG_CLOCKS set_cpu_clk_info, /* Setup clock information */ #endif +#ifdef CONFIG_X86 + init_bd_struct_r, +#endif initr_reloc_global_data, initr_serial, initr_announce, @@ -763,11 +769,16 @@ init_fnc_t init_sequence_r[] = { initr_flash, #endif INIT_FUNC_WATCHDOG_RESET -#ifdef CONFIG_PPC +#if defined(CONFIG_PPC) || defined(CONFIG_X86) /* initialize higher level parts of CPU like time base and timers */ cpu_init_r, +#endif +#ifdef CONFIG_PPC initr_spi, #endif +#if defined(CONFIG_X86) && defined(CONFIG_SPI) + init_func_spi, +#endif #ifdef CONFIG_CMD_NAND initr_nand, #endif @@ -821,10 +832,16 @@ init_fnc_t init_sequence_r[] = { #ifdef CONFIG_CMD_KGDB initr_kgdb, #endif +#ifdef CONFIG_X86 + board_early_init_r, +#endif interrupt_init, -#ifdef CONFIG_ARM +#if defined(CONFIG_ARM) || defined(CONFIG_x86) initr_enable_interrupts, #endif +#ifdef CONFIG_X86 + timer_init, /* initialize timer */ +#endif #if defined(CONFIG_STATUS_LED) && defined(STATUS_LED_BOOT) initr_status_led, #endif @@ -886,7 +903,9 @@ init_fnc_t init_sequence_r[] = { void board_init_r(gd_t *new_gd, ulong dest_addr) { +#ifndef CONFIG_X86 gd = new_gd; +#endif if (initcall_run_list(init_sequence_r)) hang();