Simplify a few code chunks, fix whitespace and indentation.
[coreboot.git] / src / mainboard / digitallogic / msm586seg / romstage.c
index ae964fea93eec7b811644e5770ea7bb46ba8225b..4e6462d1e4b0efca2d7052082f314cdb252ed2d8 100644 (file)
@@ -4,12 +4,10 @@
 #include <device/pnp_def.h>
 #include <arch/romcc_io.h>
 #include <arch/hlt.h>
-#include "pc80/mc146818rtc_early.c"
-#include "pc80/serial.c"
-#include "console/console.c"
+#include <pc80/mc146818rtc.h>
+#include <console/console.h>
 #include "lib/ramtest.c"
 #include "cpu/x86/bist.h"
-//#include "lib/delay.c"
 
 void setup_pars(void)
 {
@@ -44,12 +42,7 @@ struct mem_controller {
        int i;
 };
 
-static inline int spd_read_byte(unsigned device, unsigned address)
-{
-//     return smbus_read_byte(device, address);
-}
-
-//#include "lib/generic_sdram.c"
+static int spd_read_byte(unsigned device, unsigned address) { }
 
 static inline void dumpmem(void){
   int i, j;
@@ -184,7 +177,7 @@ static void main(unsigned long bist)
 
        //                      while(1)
        print_err("STATIC MEM DONE\n");
-       outb(0xee, 0x80);
+       post_code(0xee);
        print_err("loop forever ...\n");
 
 #if 0
@@ -232,13 +225,14 @@ static void main(unsigned long bist)
            *dst = *src;
            //print_err(" dst is now "); print_err_hex32(*dst); print_err("\n");
            dst++, src++;
-           outb((unsigned char)i, 0x80);
+           post_code(i & 0xff);
          }
        }
        dumpmem();
-       outb(0, 0x80);
+       post_code(0x00);
+
        print_err("loop forever\n");
-       outb(0xdd, 0x80);
+       post_code(0xdd);
         __asm__ volatile(
                         "movl %0, %%edi\n\t"
                         "jmp *%%edi\n\t"
@@ -251,4 +245,3 @@ static void main(unsigned long bist)
        while(1);
 #endif
 }
-