Merge 'next' branch
[platform/kernel/u-boot.git] / post / lib_ppc / b.c
index 6e276c4..492fba4 100644 (file)
  * linked in U-Boot at build time.
  */
 
-#ifdef CONFIG_POST
-
 #include <post.h>
 #include "cpu_asm.h"
 
-#if CONFIG_POST & CFG_POST_CPU
+#if CONFIG_POST & CONFIG_SYS_POST_CPU
 
 extern void cpu_post_exec_11 (ulong *code, ulong *res, ulong op1);
 extern void cpu_post_exec_31 (ulong *code, ulong *ctr, ulong *lr, ulong *jump,
@@ -97,6 +95,7 @@ int cpu_post_test_b (void)
 {
     int ret = 0;
     unsigned int i;
+    int flag = disable_interrupts();
 
     if (ret == 0)
     {
@@ -190,8 +189,10 @@ int cpu_post_test_b (void)
        }
     }
 
+    if (flag)
+       enable_interrupts();
+
     return ret;
 }
 
 #endif
-#endif