drop "arch/asm.h" and "arch/intel.h" and create "cpu/x86/post_code.h"
[coreboot.git] / src / arch / i386 / include / arch / cpu.h
index f49b7cb50a81acb9092430fa11604762f2cc759b..30b6cc300bb533e9396b984207f14061cfb71266 100644 (file)
@@ -28,6 +28,7 @@ struct cpuid_result {
        uint32_t ecx;
        uint32_t edx;
 };
+
 /*
  * Generic CPUID function
  */
@@ -44,7 +45,6 @@ static inline struct cpuid_result cpuid(int op)
        return result;
 }
 
-
 /*
  * CPUID functions returning a single datum
  */
@@ -58,6 +58,7 @@ static inline unsigned int cpuid_eax(unsigned int op)
                : "ebx", "ecx", "edx");
        return eax;
 }
+
 static inline unsigned int cpuid_ebx(unsigned int op)
 {
        unsigned int eax, ebx;
@@ -68,6 +69,7 @@ static inline unsigned int cpuid_ebx(unsigned int op)
                : "ecx", "edx" );
        return ebx;
 }
+
 static inline unsigned int cpuid_ecx(unsigned int op)
 {
        unsigned int eax, ecx;
@@ -78,6 +80,7 @@ static inline unsigned int cpuid_ecx(unsigned int op)
                : "ebx", "edx" );
        return ecx;
 }
+
 static inline unsigned int cpuid_edx(unsigned int op)
 {
        unsigned int eax, edx;
@@ -89,8 +92,6 @@ static inline unsigned int cpuid_edx(unsigned int op)
        return edx;
 }
 
-
-
 #define X86_VENDOR_INVALID    0
 #define X86_VENDOR_INTEL      1
 #define X86_VENDOR_CYRIX      2
@@ -104,7 +105,7 @@ static inline unsigned int cpuid_edx(unsigned int op)
 #define X86_VENDOR_SIS       10 
 #define X86_VENDOR_UNKNOWN 0xff
 
-#if !defined( __ROMCC__ ) && defined( __GNUC__)
+#if !defined(__PRE_RAM__)
 #include <device/device.h>
 
 
@@ -112,6 +113,7 @@ struct cpu_device_id {
        unsigned vendor;
        unsigned device;
 };
+
 struct cpu_driver {
        struct device_operations *ops;
        struct cpu_device_id *id_table;
@@ -141,7 +143,6 @@ static inline unsigned long cpu_index(void)
        return ci->index;
 }
 
-
 struct cpuinfo_x86 {
         uint8_t    x86;            /* CPU family */
         uint8_t    x86_vendor;     /* CPU vendor */