Re: [U-Boot] [PATCH] env_nand: align NAND buffers

2012-09-02 Thread Wolfgang Denk
Dear Stephen Warren,

In message <1343669918-2114-1-git-send-email-swar...@wwwdotorg.org> you wrote:
> From: Stephen Warren 
> 
> This allows cache flush/invalidate operations to succeed on the buffers.
> 
> Signed-off-by: Stephen Warren 
> ---
>  common/env_nand.c |   10 +-
>  1 files changed, 5 insertions(+), 5 deletions(-)

Applied, thanks.

Best regards,

Wolfgang Denk

-- 
DENX Software Engineering GmbH, MD: Wolfgang Denk & Detlev Zundel
HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany
Phone: (+49)-8142-66989-10 Fax: (+49)-8142-66989-80 Email: w...@denx.de
Violence in reality is quite different from theory.
-- Spock, "The Cloud Minders", stardate 5818.4
___
U-Boot mailing list
U-Boot@lists.denx.de
http://lists.denx.de/mailman/listinfo/u-boot


Re: [U-Boot] [PATCH] env_nand: align NAND buffers

2012-07-31 Thread Scott Wood
On 07/31/2012 10:59 AM, Tom Warren wrote:
> Scott,
> 
>> -Original Message-
>> From: Scott Wood [mailto:scottw...@freescale.com]
>> Sent: Monday, July 30, 2012 4:01 PM
>> To: Stephen Warren
>> Cc: Tom Warren; Simon Glass; U-Boot Mailing List; Stephen Warren
>> Subject: Re: [PATCH] env_nand: align NAND buffers
>>
>> On 07/30/2012 12:38 PM, Stephen Warren wrote:
>>> From: Stephen Warren 
>>>
>>> This allows cache flush/invalidate operations to succeed on the buffers.
>>>
>>> Signed-off-by: Stephen Warren 
>>> ---
>>>  common/env_nand.c |   10 +-
>>>  1 files changed, 5 insertions(+), 5 deletions(-)
>>
>> Acked-by: Scott Wood 
>>
>> I'm assuming you want it to go with the Tegra patches and not via my tree.
> I'm fine with taking the env_nand and cmd_nand changes thru the Tegra tree. 
> Let me know if that's OK with you.

It's OK with me.

-Scott


___
U-Boot mailing list
U-Boot@lists.denx.de
http://lists.denx.de/mailman/listinfo/u-boot


Re: [U-Boot] [PATCH] env_nand: align NAND buffers

2012-07-30 Thread Scott Wood
On 07/30/2012 12:38 PM, Stephen Warren wrote:
> From: Stephen Warren 
> 
> This allows cache flush/invalidate operations to succeed on the buffers.
> 
> Signed-off-by: Stephen Warren 
> ---
>  common/env_nand.c |   10 +-
>  1 files changed, 5 insertions(+), 5 deletions(-)

Acked-by: Scott Wood 

I'm assuming you want it to go with the Tegra patches and not via my tree.

-Scott


___
U-Boot mailing list
U-Boot@lists.denx.de
http://lists.denx.de/mailman/listinfo/u-boot


Re: [U-Boot] [PATCH] env_nand: align NAND buffers

2012-07-30 Thread Simon Glass
Hi Wolfgang,

On Mon, Jul 30, 2012 at 10:10 PM, Wolfgang Denk  wrote:
> Dear Simon Glass,
>
> In message 
>  you 
> wrote:
>>
>> > -   env_t   env_new;
>> > +   ALLOC_CACHE_ALIGN_BUFFER(env_t, env_new, sizeof(env_t));
>>
>> I think this should b
>
> Should be ... ???

Sorry, I started a comment, but thought better of it. It looks fine to me.

>
> Best regards,
>
> Wolfgang Denk
>
> --
> DENX Software Engineering GmbH, MD: Wolfgang Denk & Detlev Zundel
> HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany
> Phone: (+49)-8142-66989-10 Fax: (+49)-8142-66989-80 Email: w...@denx.de
> Be wiser than other people if you can, but do not tell them so.
>-- Philip Earl of Chesterfield

Regards,
Simon
___
U-Boot mailing list
U-Boot@lists.denx.de
http://lists.denx.de/mailman/listinfo/u-boot


Re: [U-Boot] [PATCH] env_nand: align NAND buffers

2012-07-30 Thread Wolfgang Denk
Dear Simon Glass,

In message  
you wrote:
>
> > -   env_t   env_new;
> > +   ALLOC_CACHE_ALIGN_BUFFER(env_t, env_new, sizeof(env_t));
> 
> I think this should b

Should be ... ???

Best regards,

Wolfgang Denk

-- 
DENX Software Engineering GmbH, MD: Wolfgang Denk & Detlev Zundel
HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany
Phone: (+49)-8142-66989-10 Fax: (+49)-8142-66989-80 Email: w...@denx.de
Be wiser than other people if you can, but do not tell them so.
   -- Philip Earl of Chesterfield
___
U-Boot mailing list
U-Boot@lists.denx.de
http://lists.denx.de/mailman/listinfo/u-boot


Re: [U-Boot] [PATCH] env_nand: align NAND buffers

2012-07-30 Thread Simon Glass
On Mon, Jul 30, 2012 at 6:38 PM, Stephen Warren  wrote:
> From: Stephen Warren 
>
> This allows cache flush/invalidate operations to succeed on the buffers.
>
> Signed-off-by: Stephen Warren 

Acked-by: Simon Glass 

> ---
>  common/env_nand.c |   10 +-
>  1 files changed, 5 insertions(+), 5 deletions(-)
>
> diff --git a/common/env_nand.c b/common/env_nand.c
> index e8daec9..e635472 100644
> --- a/common/env_nand.c
> +++ b/common/env_nand.c
> @@ -226,7 +226,7 @@ int saveenv(void)
>  int saveenv(void)
>  {
> int ret = 0;
> -   env_t   env_new;
> +   ALLOC_CACHE_ALIGN_BUFFER(env_t, env_new, sizeof(env_t));

I think this should b
> ssize_t len;
> char*res;
> nand_erase_options_t nand_erase_options;
> @@ -238,20 +238,20 @@ int saveenv(void)
> if (CONFIG_ENV_RANGE < CONFIG_ENV_SIZE)
> return 1;
>
> -   res = (char *)&env_new.data;
> +   res = (char *)&env_new->data;
> len = hexport_r(&env_htab, '\0', &res, ENV_SIZE, 0, NULL);
> if (len < 0) {
> error("Cannot export environment: errno = %d\n", errno);
> return 1;
> }
> -   env_new.crc = crc32(0, env_new.data, ENV_SIZE);
> +   env_new->crc = crc32(0, env_new->data, ENV_SIZE);
>
> puts("Erasing Nand...\n");
> if (nand_erase_opts(&nand_info[0], &nand_erase_options))
> return 1;
>
> puts("Writing to Nand... ");
> -   if (writeenv(CONFIG_ENV_OFFSET, (u_char *)&env_new)) {
> +   if (writeenv(CONFIG_ENV_OFFSET, (u_char *)env_new)) {
> puts("FAILED!\n");
> return 1;
> }
> @@ -398,7 +398,7 @@ void env_relocate_spec(void)
>  {
>  #if !defined(ENV_IS_EMBEDDED)
> int ret;
> -   char buf[CONFIG_ENV_SIZE];
> +   ALLOC_CACHE_ALIGN_BUFFER(char, buf, CONFIG_ENV_SIZE);
>
>  #if defined(CONFIG_ENV_OFFSET_OOB)
> ret = get_nand_env_oob(&nand_info[0], &nand_env_oob_offset);
> --
> 1.7.0.4
>
___
U-Boot mailing list
U-Boot@lists.denx.de
http://lists.denx.de/mailman/listinfo/u-boot