From: Marek Vasut <marek.vasut@gmail.com>
To: u-boot@lists.denx.de
Subject: [U-Boot] [PATCH 05/11] arm/pxa: fix environment location/length for vpac270 and related bugs.
Date: Thu, 26 Aug 2010 13:41:38 +0200 [thread overview]
Message-ID: <201008261341.38594.marek.vasut@gmail.com> (raw)
In-Reply-To: <1282819683-655-5-git-send-email-mikhail.kshevetskiy@gmail.com>
Dne ?t 26. srpna 2010 12:48:00 Mikhail Kshevetskiy napsal(a):
> Define MONITOR_BASE on the base of used flash type. Define ENV_ADDR as
> MONITOR_BASE + MONITOR_LEN. Fix environment sector size (NOR: 32Kb for
> first four sectors and 128Kb for other; OneNAND: 128Kb).
>
> Last but not least: we have MONITOR_LEN = 0x40000, one sector for
> environment and one sector for its redundancy copy (2 * 0x20000 = 256Kb).
> So the kernel may start from 0x00080000 only.
>
> Signed-off-by: Mikhail Kshevetskiy <mikhail.kshevetskiy@gmail.com>
> ---
> include/configs/vpac270.h | 10 ++++++----
> 1 files changed, 6 insertions(+), 4 deletions(-)
>
> diff --git a/include/configs/vpac270.h b/include/configs/vpac270.h
> index 4c162bd..d3e805a 100644
> --- a/include/configs/vpac270.h
> +++ b/include/configs/vpac270.h
> @@ -49,7 +49,7 @@
> "if usb reset && fatload usb 0 0xa4000000 uImage; then " \
> "bootm 0xa4000000; " \
> "fi; " \
> - "bootm 0x40000;"
> + "bootm 0x00080000;"
Good catch, but let's make it 0x60000 as spare env isn't used.
> #define CONFIG_BOOTARGS "console=tty0
console=ttyS0,115200"
> #define CONFIG_TIMESTAMP
> #define CONFIG_BOOTDELAY 2 /* Autoboot delay */
> @@ -188,6 +188,7 @@
> #if defined(CONFIG_CMD_FLASH) /* NOR */
> #define PHYS_FLASH_1 0x00000000 /* Flash Bank #1
*/
> #define PHYS_FLASH_2 0x02000000 /* Flash Bank #2
*/
> +#define CONFIG_SYS_MONITOR_BASE PHYS_FLASH_1
This is always 0 ... that's why it's defined in common place.
>
> #define CONFIG_SYS_FLASH_CFI
> #define CONFIG_FLASH_CFI_DRIVER 1
> @@ -207,18 +208,19 @@
> #elif defined(CONFIG_CMD_ONENAND) /* OneNAND */
> #define CONFIG_SYS_NO_FLASH
> #define CONFIG_SYS_ONENAND_BASE 0x00000000
> +#define CONFIG_SYS_MONITOR_BASE CONFIG_SYS_ONENAND_BASE
> #define CONFIG_ENV_IS_IN_ONENAND 1
>
> #else /* No flash */
> #define CONFIG_SYS_NO_FLASH
> #define CONFIG_SYS_ENV_IS_NOWHERE
> +#define CONFIG_SYS_MONITOR_BASE 0x000000
> #endif
>
> -#define CONFIG_SYS_MONITOR_BASE 0x000000
> #define CONFIG_SYS_MONITOR_LEN 0x40000
>
> -#define CONFIG_ENV_ADDR (CONFIG_SYS_MONITOR_LEN)
> -#define CONFIG_ENV_SECT_SIZE 0x40000
> +#define CONFIG_ENV_ADDR (CONFIG_SYS_MONITOR_BASE +
> CONFIG_SYS_MONITOR_LEN) +#define CONFIG_ENV_SECT_SIZE 0x20000
> #define CONFIG_ENV_ADDR_REDUND (CONFIG_ENV_ADDR + CONFIG_ENV_SECT_SIZE)
> #define CONFIG_ENV_SIZE_REDUND (CONFIG_ENV_SIZE)
Please rebase the patch on top of for-wd-master.
next prev parent reply other threads:[~2010-08-26 11:41 UTC|newest]
Thread overview: 14+ messages / expand[flat|nested] mbox.gz Atom feed top
2010-08-26 10:47 [U-Boot] [PATCH 01/11] arm/pxa: remove unused u-boot.lds from board/vpac270 Mikhail Kshevetskiy
2010-08-26 10:47 ` [U-Boot] [PATCH 02/11] arm/pxa: fix board/vpac270/vpac270.c compilation if usb support is disabled Mikhail Kshevetskiy
2010-08-26 10:47 ` [U-Boot] [PATCH 03/11] arm/pxa: enable stuart/btuart for vpac270 Mikhail Kshevetskiy
2010-08-26 10:47 ` [U-Boot] [PATCH 04/11] arm/pxa: cleanup vpac270 config and set CONFIG_SYS_HZ to 1000 Mikhail Kshevetskiy
2010-08-26 10:48 ` [U-Boot] [PATCH 05/11] arm/pxa: fix environment location/length for vpac270 and related bugs Mikhail Kshevetskiy
2010-08-26 11:41 ` Marek Vasut [this message]
2010-08-26 10:48 ` [U-Boot] [PATCH 06/11] arm/pxa: remove CONFIG_ENV_OVERWRITE from vpac270 config Mikhail Kshevetskiy
2010-08-26 11:43 ` Marek Vasut
2010-08-26 10:48 ` [U-Boot] [PATCH 07/11] arm/pxa: decrease environment size and stack size for vpac270 Mikhail Kshevetskiy
2010-08-26 11:45 ` Marek Vasut
2010-09-18 20:11 ` Wolfgang Denk
2010-08-26 10:48 ` [U-Boot] [PATCH 08/11] arm/pxa: increase CONFIG_SYS_MALLOC_LEN to (196Kb + space for environment) Mikhail Kshevetskiy
2010-08-26 11:48 ` Marek Vasut
2010-09-18 20:14 ` Wolfgang Denk
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=201008261341.38594.marek.vasut@gmail.com \
--to=marek.vasut@gmail.com \
--cc=u-boot@lists.denx.de \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox