From patchwork Wed Feb 27 18:48:41 2013 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Barak Wasserstrom X-Patchwork-Id: 223682 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 6E64C2C0079 for ; Thu, 28 Feb 2013 05:54:02 +1100 (EST) Received: from localhost (localhost [127.0.0.1]) by theia.denx.de (Postfix) with ESMTP id 23CC84A018; Wed, 27 Feb 2013 19:53:58 +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 jCW81BGV8Xet; Wed, 27 Feb 2013 19:53:57 +0100 (CET) Received: from theia.denx.de (localhost [127.0.0.1]) by theia.denx.de (Postfix) with ESMTP id 6EC064A01C; Wed, 27 Feb 2013 19:53:55 +0100 (CET) Received: from localhost (localhost [127.0.0.1]) by theia.denx.de (Postfix) with ESMTP id E540A4A01C for ; Wed, 27 Feb 2013 19:53:53 +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 tt+aB+ktqHRj for ; Wed, 27 Feb 2013 19:53:51 +0100 (CET) X-Greylist: delayed 301 seconds by postgrey-1.27 at theia; Wed, 27 Feb 2013 19:53:50 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-ee0-f53.google.com (mail-ee0-f53.google.com [74.125.83.53]) by theia.denx.de (Postfix) with ESMTPS id 86F164A018 for ; Wed, 27 Feb 2013 19:53:50 +0100 (CET) Received: by mail-ee0-f53.google.com with SMTP id e53so779386eek.12 for ; Wed, 27 Feb 2013 10:53:49 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=x-received:user-agent:date:subject:from:to:message-id:thread-topic :in-reply-to:mime-version:content-type:content-transfer-encoding; bh=MYuY7FTplEVfDqVY2Os5LY0JEhqOiHDRi4hI3C4t8h0=; b=XniRnrCAiIGj7/4uMrGJ8uSwgvTAxq+us3AeOo1t9CiALgc8fJuGGKf3a8DTr1/a7f mVljG4W8Ky0KgVYiMRxAxS23TLnfsy8vpDifelUb1ANl1QsY5apFQ/S60u3Tf9nGBDoK fsDhrDUb7F1wxMNncG4bySeDAkTLYoz/6vBGQErqC3uJhP5wobLM6Rj5iHg3h/xE3Igv LwZ3xhe5MaYSLtNGtoefGY4Urm+ZwMJO/dLgtHUJ022c+rHlX6zt4JcYebeExWI0FMJA jtj2Xxzxv9CzC6hr0iceXZC3aPf1vPMEP1qN7zAnfysfFHg+aqveFMyFujqDy7tagjq7 KHcw== X-Received: by 10.14.3.70 with SMTP id 46mr8802236eeg.2.1361990929235; Wed, 27 Feb 2013 10:48:49 -0800 (PST) Received: from [192.168.0.101] (bzq-84-108-224-134.cablep.bezeqint.net. [84.108.224.134]) by mx.google.com with ESMTPS id 3sm7866978eej.6.2013.02.27.10.48.46 (version=TLSv1 cipher=RC4-SHA bits=128/128); Wed, 27 Feb 2013 10:48:47 -0800 (PST) User-Agent: Microsoft-MacOutlook/14.2.5.121010 Date: Wed, 27 Feb 2013 20:48:41 +0200 From: Barak Wasserstrom To: U-Boot Mailing List Message-ID: Thread-Topic: [U-Boot] [PATCH] common/main: move set_working_fdt_addr to enable usage of $fdtaddr In-Reply-To: <1356548233-5570-12-git-send-email-sjg@chromium.org> Mime-version: 1.0 Subject: [U-Boot] [PATCH] common/main: move set_working_fdt_addr to enable usage of $fdtaddr 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: , Sender: u-boot-bounces@lists.denx.de Errors-To: u-boot-bounces@lists.denx.de When using $fdtaddr in $bootcmd and $bootcmd is automatically called, $fdtaddr is yet not defined. Signed-off-by: Barak Wasserstrom --- common/main.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/common/main.c b/common/main.c index e2d2e09..77b9076 100644 --- a/common/main.c +++ b/common/main.c @@ -378,6 +378,10 @@ void main_loop (void) bootstage_mark_name(BOOTSTAGE_ID_MAIN_LOOP, "main_loop"); +#if defined CONFIG_OF_CONTROL + set_working_fdt_addr((void *)gd->fdt_blob); +#endif /* CONFIG_OF_CONTROL */ + #ifdef CONFIG_BOOTCOUNT_LIMIT bootcount = bootcount_load(); bootcount++; @@ -500,10 +504,6 @@ void main_loop (void) #endif /* CONFIG_MENUKEY */ #endif /* CONFIG_BOOTDELAY */ -#if defined CONFIG_OF_CONTROL - set_working_fdt_addr((void *)gd->fdt_blob); -#endif /* CONFIG_OF_CONTROL */ - /* * Main Loop for Monitor Command Processing */