summaryrefslogtreecommitdiff
path: root/post/lib_ppc/multi.c
diff options
context:
space:
mode:
authorStefan Roese <sr@denx.de>2008-07-18 11:03:35 +0200
committerWolfgang Denk <wd@denx.de>2008-07-20 23:00:22 +0200
commit86446d3a5d9d3ca81e85d1ccd3accaaae6f8e3c9 (patch)
tree8bfd93d7e9c37dee1d24637ea93c72182f164aae /post/lib_ppc/multi.c
parent97a3bf268d096e0e97e54048448c35114edcf557 (diff)
downloadu-boot-imx-86446d3a5d9d3ca81e85d1ccd3accaaae6f8e3c9.zip
u-boot-imx-86446d3a5d9d3ca81e85d1ccd3accaaae6f8e3c9.tar.gz
u-boot-imx-86446d3a5d9d3ca81e85d1ccd3accaaae6f8e3c9.tar.bz2
POST: Add disable interrupts in some of the missing CPU POST tests
Some CPU POST tests did not disable the interrupts while running. This seems to be necessary to protect this self modifying code. Signed-off-by: Stefan Roese <sr@denx.de>
Diffstat (limited to 'post/lib_ppc/multi.c')
-rw-r--r--post/lib_ppc/multi.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/post/lib_ppc/multi.c b/post/lib_ppc/multi.c
index 5d3f584..47135ab 100644
--- a/post/lib_ppc/multi.c
+++ b/post/lib_ppc/multi.c
@@ -44,6 +44,7 @@ int cpu_post_test_multi (void)
{
int ret = 0;
unsigned int i;
+ int flag = disable_interrupts();
if (ret == 0)
{
@@ -72,6 +73,9 @@ int cpu_post_test_multi (void)
post_log ("Error at multi test !\n");
}
+ if (flag)
+ enable_interrupts();
+
return ret;
}