From patchwork Tue Oct 1 08:27:36 2013 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Prabhakar Kushwaha X-Patchwork-Id: 279369 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 AF4DC2C0091 for ; Tue, 1 Oct 2013 18:28:40 +1000 (EST) Received: from localhost (localhost [127.0.0.1]) by theia.denx.de (Postfix) with ESMTP id 35E164A092; Tue, 1 Oct 2013 10:28:13 +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 OLC94-hmbLem; Tue, 1 Oct 2013 10:28:13 +0200 (CEST) Received: from theia.denx.de (localhost [127.0.0.1]) by theia.denx.de (Postfix) with ESMTP id B22E04A0C5; Tue, 1 Oct 2013 10:28:09 +0200 (CEST) Received: from localhost (localhost [127.0.0.1]) by theia.denx.de (Postfix) with ESMTP id 8CE474A080 for ; Tue, 1 Oct 2013 10:28:03 +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 1GH0gyMxIzEX for ; Tue, 1 Oct 2013 10:27:58 +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 db9outboundpool.messaging.microsoft.com (mail-db9lp0249.outbound.messaging.microsoft.com [213.199.154.249]) by theia.denx.de (Postfix) with ESMTPS id 727994A0C5 for ; Tue, 1 Oct 2013 10:27:47 +0200 (CEST) Received: from mail55-db9-R.bigfish.com (10.174.16.239) by DB9EHSOBE035.bigfish.com (10.174.14.98) with Microsoft SMTP Server id 14.1.225.22; Tue, 1 Oct 2013 08:27:45 +0000 Received: from mail55-db9 (localhost [127.0.0.1]) by mail55-db9-R.bigfish.com (Postfix) with ESMTP id 82CD8400089 for ; Tue, 1 Oct 2013 08:27:45 +0000 (UTC) X-Forefront-Antispam-Report: CIP:70.37.183.190; KIP:(null); UIP:(null); IPV:NLI; H:mail.freescale.net; RD:none; EFVD:NLI X-SpamScore: 0 X-BigFish: VS0(zzzz1f42h208ch1ee6h1de0h1fdah2073h1202h1e76h1d1ah1d2ah1fc6hzz1de098h1de097h8275bhz2dh2a8h839hd24he5bhf0ah1288h12a5h12a9h12bdh12e5h137ah139eh13b6h1441h1504h1537h162dh1631h1758h1898h18e1h1946h19b5h1ad9h1b0ah1b2fh1fb3h1d0ch1d2eh1d3fh1dc1h1dfeh1dffh1e23h1fe8h1ff5h1155h) Received: from mail55-db9 (localhost.localdomain [127.0.0.1]) by mail55-db9 (MessageSwitch) id 1380616064488567_17518; Tue, 1 Oct 2013 08:27:44 +0000 (UTC) Received: from DB9EHSMHS011.bigfish.com (unknown [10.174.16.245]) by mail55-db9.bigfish.com (Postfix) with ESMTP id 6838F320041 for ; Tue, 1 Oct 2013 08:27:44 +0000 (UTC) Received: from mail.freescale.net (70.37.183.190) by DB9EHSMHS011.bigfish.com (10.174.14.21) with Microsoft SMTP Server (TLS) id 14.16.227.3; Tue, 1 Oct 2013 08:27:44 +0000 Received: from az84smr01.freescale.net (10.64.34.197) by 039-SN1MMR1-005.039d.mgd.msft.net (10.84.1.17) with Microsoft SMTP Server (TLS) id 14.3.158.2; Tue, 1 Oct 2013 08:27:42 +0000 Received: from b32579-VirtualBox.ap.freescale.net (B32579-02-010232132087.ap.freescale.net [10.232.132.87]) by az84smr01.freescale.net (8.14.3/8.14.0) with ESMTP id r918RakK021836; Tue, 1 Oct 2013 01:27:40 -0700 From: Prabhakar Kushwaha To: Date: Tue, 1 Oct 2013 13:57:36 +0530 Message-ID: <1380616056-11196-1-git-send-email-prabhakar@freescale.com> X-Mailer: git-send-email 1.7.9.5 MIME-Version: 1.0 X-OriginatorOrg: freescale.com X-FOPE-CONNECTOR: Id%0$Dn%*$RO%0$TLS%0$FQDN%$TlsDn% Cc: yorksun@freescale.com Subject: [U-Boot] [PATCH 3/6] common/env: Point default envirenoment for GD 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 GD(Global Data) structure has pointer to envirenoment variable array. but, it is not being assigned for SPL framwork. So update GD pointer with env variable array. Signed-off-by: Prabhakar Kushwaha --- Based upon git://git.denx.de/u-boot-mpc85xx.git branch next common/env_common.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/common/env_common.c b/common/env_common.c index 1ac3377..84843e1 100644 --- a/common/env_common.c +++ b/common/env_common.c @@ -162,6 +162,9 @@ int env_import(const char *buf, int check) if (himport_r(&env_htab, (char *)ep->data, ENV_SIZE, '\0', 0, 0, NULL)) { gd->flags |= GD_FLG_ENV_READY; +#ifdef CONFIG_SPL_BUILD + gd->env_addr = ep->data; +#endif return 1; }