: "0" (index));
}
+static inline u32 getcr0(void) {
+ u32 cr0;
+ asm("movl %%cr0, %0" : "=r"(cr0));
+ return cr0;
+}
+static inline void setcr0(u32 cr0) {
+ asm("movl %0, %%cr0" : : "r"(cr0));
+}
+
static inline u64 rdmsr(u32 index)
{
u64 ret;
// shadow.c
void make_bios_writable(void);
void make_bios_readonly(void);
-void make_bios_writable_intel(u16 bdf, u32 pam0);
-void make_bios_readonly_intel(u16 bdf, u32 pam0);
void qemu_prep_reset(void);
-// smm.c
-void smm_save_and_copy(void);
-void smm_relocate_and_restore(void);
-
// pci_region.c
// region allocator. pci region allocates the requested region
// sequentially with overflow check.
// pciinit.c
extern const u8 pci_irqs[4];
-void pci_bios_allocate_regions(u16 bdf, void *arg);
void pci_setup(void);
// smm.c
void smp_probe(void);
// coreboot.c
+extern const char *CBvendor, *CBpart;
struct cbfs_file;
struct cbfs_file *cbfs_finddatafile(const char *fname);
struct cbfs_file *cbfs_findprefix(const char *prefix, struct cbfs_file *last);
void cbfs_payload_setup(void);
void coreboot_setup(void);
+// biostable.c
+void copy_pir(void *pos);
+void copy_mptable(void *pos);
+void copy_acpi_rsdp(void *pos);
+void copy_smbios(void *pos);
+
// vgahooks.c
-extern int VGAbdf;
void handle_155f(struct bregs *regs);
-void vgahook_setup(const char *vendor, const char *part);
+struct pci_device;
+void vgahook_setup(struct pci_device *pci);
// optionroms.c
void call_bcv(u16 seg, u16 ip);
void vga_setup(void);
void s3_resume_vga_init(void);
extern u32 RomEnd;
+extern int ScreenAndDebug;
// bootsplash.c
void enable_vga_console(void);
void disable_bootsplash(void);
// resume.c
+extern int HaveRunPost;
void init_dma(void);
// pnpbios.c