Skip to content
Snippets Groups Projects
Commit 1754f50b authored by Stefan Roese's avatar Stefan Roese
Browse files

ppc4xx: Add CFG_POST_ALT_WORD_ADDR to support non OCM POST WORD storage


The privious 4xx POST implementation only supported storing the POST
WORD in OCM. Since we need to reserve the OCM on LWMON5 for the logbuffer
we need to store the POST WORD in some other non volatile location.
This patch adds CFG_POST_ALT_WORD_ADDR to specify an address for such
a location.

Signed-off-by: default avatarStefan Roese <sr@denx.de>
parent e02c521d
No related branches found
Tags LABEL_2003_10_01_1830
No related merge requests found
......@@ -26,10 +26,21 @@
#include <common.h>
#include <commproc.h>
#include <asm/io.h>
#if defined(CONFIG_POST) || defined(CONFIG_LOGBUFFER)
#if defined(CFG_POST_ALT_WORD_ADDR)
void post_word_store (ulong a)
{
out_be32((void *)CFG_POST_ALT_WORD_ADDR, a);
}
ulong post_word_load (void)
{
return in_be32((void *)CFG_POST_ALT_WORD_ADDR);
}
#else /* CFG_POST_ALT_WORD_ADDR */
void post_word_store (ulong a)
{
volatile void *save_addr = (volatile void *)(CFG_OCM_DATA_ADDR + CFG_POST_WORD_ADDR);
......@@ -41,6 +52,7 @@ ulong post_word_load (void)
volatile void *save_addr = (volatile void *)(CFG_OCM_DATA_ADDR + CFG_POST_WORD_ADDR);
return *(volatile ulong *) save_addr;
}
#endif /* CFG_POST_ALT_WORD_ADDR */
#endif /* CONFIG_POST || CONFIG_LOGBUFFER*/
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment