public inbox for u-boot@lists.denx.de
 help / color / mirror / Atom feed
* [U-Boot] [PATCH 3/6] common/env: Point default envirenoment for GD
@ 2013-10-01  8:27 Prabhakar Kushwaha
  2013-10-24 18:02 ` York Sun
  0 siblings, 1 reply; 2+ messages in thread
From: Prabhakar Kushwaha @ 2013-10-01  8:27 UTC (permalink / raw)
  To: u-boot

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 <prabhakar@freescale.com>
---
 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;
 	}
 
-- 
1.7.9.5

^ permalink raw reply related	[flat|nested] 2+ messages in thread

* [U-Boot] [PATCH 3/6] common/env: Point default envirenoment for GD
  2013-10-01  8:27 [U-Boot] [PATCH 3/6] common/env: Point default envirenoment for GD Prabhakar Kushwaha
@ 2013-10-24 18:02 ` York Sun
  0 siblings, 0 replies; 2+ messages in thread
From: York Sun @ 2013-10-24 18:02 UTC (permalink / raw)
  To: u-boot

On 10/01/2013 01:27 AM, Prabhakar Kushwaha wrote:
> 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 <prabhakar@freescale.com>
> ---
>  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


You are assigning a pointer to a interger. This introduces compiling warning

env_common.c:166:16: warning: assignment makes integer from pointer
without a cast [enabled by default]

Please fix.

York

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2013-10-24 18:02 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2013-10-01  8:27 [U-Boot] [PATCH 3/6] common/env: Point default envirenoment for GD Prabhakar Kushwaha
2013-10-24 18:02 ` York Sun

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox