Dear Charles Krinke,

In message <aanlktikjfqlx4lra7bzsaq2njy0ehinh+evwe8cso...@mail.gmail.com> you 
wrote:
>
>     up_data = (end_addr + 1 - ((long)flash_addr + CONFIG_ENV_SIZE));
>     debug("2 Data to save 0x%lx  end:%lx new:%lx\n", up_data, end_addr,
> flash_addr);
>     if (up_data) {
>         if ((saved_data = malloc(up_data)) == NULL) {
>             printf("Unable to save the rest of sector (%ld)\n",
>                 up_data);
>             goto done;
>         }
> 
> At the debug statement, up_data = 0x1E000, end_addr = 0xFE07FFFF and
> flash_addr = 0xFE060000. The end_addr and flash_addr seem reasonable to me
> as the flash in 128Kb sectors in the MPC8323ERDB so the first few sectors
> are:

Hmm...

        up_data = (end_addr + 1 - ((long)flash_addr + CONFIG_ENV_SIZE));

so

        CONFIG_ENV_SIZE = up_data + flash_addr - end_addr - 1
                        = 0x1E000 + 0xFE060000 - 0xFE07FFFF - 1
                        = -8192

The values you give here make no sense to me, as CONFIG_ENV_SIZE is
supposed to be a positive number.


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
If something is different, it's either better or worse,  and  usually
both.                                                    - Larry Wall
_______________________________________________
U-Boot mailing list
U-Boot@lists.denx.de
http://lists.denx.de/mailman/listinfo/u-boot

Reply via email to