mpc5200: a3m071/a4m2k: Fix problem with increased global_data struct
PATCH 1/2 mpc5200: a3m071/a4m2k: Fix problem with increased global_data struct
The v2013.04 release has this patch set included:
5cb48582 "Add architecture-specific global data"
With this, the global_data struct is now common and new variables have been added. Resulting in a bigger struct. Unfortunately the currently allocated 128 bytes are just a bit too small for this new struct. So lets increase the reserved space to solve this issue.
Please note that this problem might hit some other platforms which currently reserve a tight space of 128 bytes for the global_data struct!
--- include/configs/a3m071.h | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-)
include/configs/a3m071.h +1 -2
@@ -121,8 +121,7 @@#define CONFIG_SYS_INIT_RAM_ADDR MPC5XXX_SRAM#define CONFIG_SYS_INIT_RAM_END MPC5XXX_SRAM_SIZE - -#define CONFIG_SYS_GBL_DATA_SIZE 128 +#define CONFIG_SYS_GBL_DATA_SIZE 256#define CONFIG_SYS_GBL_DATA_OFFSET (CONFIG_SYS_INIT_RAM_END - \ CONFIG_SYS_GBL_DATA_SIZE)#define CONFIG_SYS_INIT_SP_OFFSET CONFIG_SYS_GBL_DATA_OFFSET
Signature · 1 line
1.8.2.1
PATCH 2/2 mpc5200: a3m071/a4m2k: Add redundant environment support
Also move the environment offset a bit to allow bigger u-boot images.
--- include/configs/a3m071.h | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-)
include/configs/a3m071.h +4 -1
@@ -88,7 +88,10 @@*/ #define CONFIG_SYS_FLASH_BASE 0xfc000000#define CONFIG_SYS_FLASH_SIZE 0x02000000 -#define CONFIG_ENV_ADDR (CONFIG_SYS_FLASH_BASE + 0x40000) +#define CONFIG_ENV_ADDR (CONFIG_SYS_FLASH_BASE + 0x80000) +/* Address and size of Redundant Environment Sector */ +#define CONFIG_ENV_ADDR_REDUND (CONFIG_ENV_ADDR + CONFIG_ENV_SECT_SIZE) +#define CONFIG_ENV_SIZE_REDUND (CONFIG_ENV_SIZE)#define CONFIG_SYS_MAX_FLASH_BANKS 1#define CONFIG_SYS_MAX_FLASH_SECT 256
Signature · 1 line
1.8.2.1
PATCH v2 2/2 mpc5200: a3m071/a4m2k: Miscellaneous updates and fixes
The changes to a3m071/a4m2k in summary are:
- Enable CAN1 on I2C in GPS Port Configuration
- Enable SPI on PSC2
- Activate network console
- New flash partitioning
- Fix some typos
- Pass host name to Linux
- Change rootfs to squashfs,jffs2
- Enable UBI/UBIFS support
- Enable FIT support
---
v2:
- Not only redundant env but also some other fixes and updates included
- Therefore the patch subject has been changed
board/a3m071/a3m071.c | 26 +++++++++++---- include/configs/a3m071.h | 87 ++++++++++++++++++++++++++++++++++-------------- 2 files changed, 82 insertions(+), 31 deletions(-)
board/a3m071/a3m071.c +20 -6
@@ -8,7 +8,7 @@* (C) Copyright 2006 * MicroSys GmbH * -* Copyright 2012 Stefan Roese <[email protected]> +* Copyright 2012-2013 Stefan Roese <[email protected]> * * See file CREDITS for list of people who contributed to this * project.
@@ -241,12 +241,26 @@ void spl_board_init(void)/* And write new value back to register */ out_be32 (&mm->ipbi_ws_ctrl, val); -#endif -/* -* No need to change the pin multiplexing (MPC5XXX_GPS_PORT_CONFIG) -* as all 3 config versions (failsave level) have the same setup. -*/ + +/* Setup pin multiplexing */ +if (failsavelevel ==2 ) { +/* fpga-version ok */ +#if defined(CONFIG_SYS_GPS_PORT_CONFIG_2 ) +out_be32 (&gpio->port_config,CONFIG_SYS_GPS_PORT_CONFIG_2 ); +#endif + }else if (failsavelevel ==1 ) { +/* digiboard-version ok - fpga not */ +#if defined(CONFIG_SYS_GPS_PORT_CONFIG_1 ) +out_be32 (&gpio->port_config,CONFIG_SYS_GPS_PORT_CONFIG_1 ); +#endif + }else { +/* full failsave-mode */ +#if defined(CONFIG_SYS_GPS_PORT_CONFIG ) +out_be32 (&gpio->port_config,CONFIG_SYS_GPS_PORT_CONFIG ); +#endif + } +#endif /* * Setup gpio_wkup_7 as watchdog AS INPUT to disable it - see
include/configs/a3m071.h +62 -25
168 lines not on this page · raw message
Signature · 1 line
1.8.2.1
Wolfgang Denk
AppliedPATCH v2 2/2 mpc5200: a3m071/a4m2k: Miscellaneous updates and fixes
Dear Stefan Roese,
Quoted 18 lines · In message <[email protected]> you wrote:
The changes to a3m071/a4m2k in summary are:
- Enable CAN1 on I2C in GPS Port Configuration
- Enable SPI on PSC2
- Activate network console
- New flash partitioning
- Fix some typos
- Pass host name to Linux
- Change rootfs to squashfs,jffs2
- Enable UBI/UBIFS support
- Enable FIT supportSigned-off-by Stefan Roese <[email protected]>---
v2:
- Not only redundant env but also some other fixes and updates included
- Therefore the patch subject has been changed
Quoted 3 lines
board/a3m071/a3m071.c | 26 +++++++++++---- include/configs/a3m071.h | 87 ++++++++++++++++++++++++++++++++++-------------- 2 files changed, 82 insertions(+), 31 deletions(-)
Applied, thanks.
Best regards,
Wolfgang Denk
Signature · 4 lines
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: wd at denx.de The software required `Windows 95 or better', so I installed Linux.
PATCH v2 1/2 mpc5200: a3m071/a4m2k: Fix problem with increased global_data struct
In reply to Stefan RoeseThe v2013.04 release has this patch set included:
5cb48582 "Add architecture-specific global data"
With this, the global_data struct is now common and new variables have been added. Resulting in a bigger struct. Unfortunately the currently allocated 128 bytes are just a bit too small for this new struct.
This patch now uses the automatically generated struct size instead to not run into this problem again.
Please note that this problem might hit some other platforms which currently reserve a tight space of 128 bytes for the global_data struct!
---
v2:
- Use automatically generated struct size instead instead of a fixed value
include/configs/a3m071.h | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-)
include/configs/a3m071.h +1 -3
@@ -121,10 +121,8 @@#define CONFIG_SYS_INIT_RAM_ADDR MPC5XXX_SRAM#define CONFIG_SYS_INIT_RAM_END MPC5XXX_SRAM_SIZE - -#define CONFIG_SYS_GBL_DATA_SIZE 128#define CONFIG_SYS_GBL_DATA_OFFSET (CONFIG_SYS_INIT_RAM_END - \ - CONFIG_SYS_GBL_DATA_SIZE) + GENERATED_GBL_DATA_SIZE)#define CONFIG_SYS_INIT_SP_OFFSET CONFIG_SYS_GBL_DATA_OFFSET#define CONFIG_SYS_MONITOR_BASE CONFIG_SYS_TEXT_BASE
Signature · 1 line
1.8.2.1
Wolfgang Denk
AppliedPATCH v2 1/2 mpc5200: a3m071/a4m2k: Fix problem with increased global_data struct
Dear Stefan Roese,
Quoted 16 lines · In message <[email protected]> you wrote:
The v2013.04 release has this patch set included:
5cb48582"Add architecture-specific global data"With this, the
global_datastruct is now common and new variables have been added. Resulting in a bigger struct. Unfortunately the currently allocated 128 bytes are just a bit too small for this new struct.This patch now uses the automatically generated struct size instead to not run into this problem again.
Please note that this problem might hit some other platforms which currently reserve a tight space of 128 bytes for the
global_datastruct!
Quoted 8 lines
Signed-off-by Stefan Roese <[email protected]>---
v2:
- Use automatically generated struct size instead instead of a fixed valueinclude/configs/a3m071.h | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-)
Applied, thanks.
Best regards,
Wolfgang Denk
Signature · 5 lines
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: wd at denx.de
Wenn das dann in die Hose geht, nehme ich es auf meine Kappe.
-- Rudi V?ller, 15. Nov 2003