diff options
Diffstat (limited to 'src/fw')
-rw-r--r-- | src/fw/acpi.c | 9 | ||||
-rw-r--r-- | src/fw/biostables.c | 5 | ||||
-rw-r--r-- | src/fw/coreboot.c | 15 | ||||
-rw-r--r-- | src/fw/csm.c | 17 | ||||
-rw-r--r-- | src/fw/mptable.c | 5 | ||||
-rw-r--r-- | src/fw/mtrr.c | 3 | ||||
-rw-r--r-- | src/fw/paravirt.c | 19 | ||||
-rw-r--r-- | src/fw/pciinit.c | 13 | ||||
-rw-r--r-- | src/fw/pirtable.c | 4 | ||||
-rw-r--r-- | src/fw/shadow.c | 9 | ||||
-rw-r--r-- | src/fw/smbios.c | 7 | ||||
-rw-r--r-- | src/fw/smm.c | 9 | ||||
-rw-r--r-- | src/fw/smp.c | 3 | ||||
-rw-r--r-- | src/fw/xen.c | 12 |
14 files changed, 71 insertions, 59 deletions
diff --git a/src/fw/acpi.c b/src/fw/acpi.c index 8ad3673e..cba3f682 100644 --- a/src/fw/acpi.c +++ b/src/fw/acpi.c @@ -6,18 +6,19 @@ // This file may be distributed under the terms of the GNU LGPLv3 license. #include "acpi.h" // struct rsdp_descriptor -#include "util.h" // dprintf #include "byteorder.h" // cpu_to_le16 +#include "config.h" // CONFIG_* +#include "dev-q35.h" #include "hw/pci.h" // pci_find_init_device #include "hw/pci_ids.h" // PCI_VENDOR_ID_INTEL #include "hw/pci_regs.h" // PCI_INTERRUPT_LINE #include "ioport.h" // inl -#include "config.h" // CONFIG_* -#include "paravirt.h" // RamSize -#include "dev-q35.h" #include "malloc.h" // free +#include "output.h" // dprintf +#include "paravirt.h" // RamSize #include "romfile.h" // romfile_loadint #include "string.h" // memset +#include "util.h" // MaxCountCPUs #include "x86.h" // readl #include "src/fw/acpi-dsdt.hex" diff --git a/src/fw/biostables.c b/src/fw/biostables.c index 06cd864f..8fa9fac6 100644 --- a/src/fw/biostables.c +++ b/src/fw/biostables.c @@ -4,14 +4,15 @@ // // This file may be distributed under the terms of the GNU LGPLv3 license. +#include "acpi.h" // struct rsdp_descriptor #include "config.h" // CONFIG_* -#include "util.h" // dprintf #include "hw/pci.h" // struct pir_header -#include "acpi.h" // struct rsdp_descriptor #include "malloc.h" // malloc_fseg #include "mptable.h" // MPTABLE_SIGNATURE +#include "output.h" // dprintf #include "smbios.h" // struct smbios_entry_point #include "string.h" // memcpy +#include "util.h" // copy_table static void copy_pir(void *pos) diff --git a/src/fw/coreboot.c b/src/fw/coreboot.c index 9971f824..c82dd4e8 100644 --- a/src/fw/coreboot.c +++ b/src/fw/coreboot.c @@ -4,21 +4,22 @@ // // This file may be distributed under the terms of the GNU LGPLv3 license. -#include "memmap.h" // add_e820 -#include "util.h" // dprintf -#include "byteorder.h" // be32_to_cpu -#include "lzmadecode.h" // LzmaDecode -#include "smbios.h" // smbios_init +#include "acpi.h" // find_acpi_features #include "boot.h" // boot_add_cbfs -#include "disk.h" // MAXDESCSIZE +#include "byteorder.h" // be32_to_cpu #include "config.h" // CONFIG_* -#include "acpi.h" // find_acpi_features +#include "disk.h" // MAXDESCSIZE #include "hw/pci.h" // pci_probe_devices +#include "lzmadecode.h" // LzmaDecode #include "malloc.h" // free +#include "memmap.h" // add_e820 +#include "output.h" // dprintf #include "paravirt.h" // PlatformRunningOn #include "romfile.h" // romfile_findprefix +#include "smbios.h" // smbios_init #include "stacks.h" // yield #include "string.h" // memset +#include "util.h" // coreboot_preinit /**************************************************************** diff --git a/src/fw/csm.c b/src/fw/csm.c index 9e73a40e..7a926b1c 100644 --- a/src/fw/csm.c +++ b/src/fw/csm.c @@ -4,21 +4,22 @@ // // This file may be distributed under the terms of the GNU LGPLv3 license. +#include "acpi.h" +#include "biosvar.h" +#include "boot.h" +#include "bregs.h" #include "config.h" // CONFIG_* #include "csm.h" -#include "util.h" // dprintf -#include "bregs.h" -#include "optionroms.h" #include "hw/pci.h" +#include "hw/pic.h" +#include "malloc.h" // csm_malloc_preinit #include "memmap.h" -#include "biosvar.h" +#include "optionroms.h" +#include "output.h" // dprintf #include "post.h" -#include "acpi.h" -#include "boot.h" #include "smbios.h" -#include "hw/pic.h" -#include "malloc.h" // csm_malloc_preinit #include "stacks.h" // wait_threads +#include "util.h" // copy_smbios struct rsdp_descriptor csm_rsdp VARFSEG __aligned(16); diff --git a/src/fw/mptable.c b/src/fw/mptable.c index 4562a463..9877bae4 100644 --- a/src/fw/mptable.c +++ b/src/fw/mptable.c @@ -5,14 +5,15 @@ // // This file may be distributed under the terms of the GNU LGPLv3 license. -#include "util.h" // dprintf #include "config.h" // CONFIG_* -#include "mptable.h" // MPTABLE_SIGNATURE #include "hw/pci.h" #include "hw/pci_regs.h" #include "malloc.h" // free +#include "mptable.h" // MPTABLE_SIGNATURE +#include "output.h" // dprintf #include "romfile.h" // romfile_loadint #include "string.h" // memset +#include "util.h" // MaxCountCPUs #include "x86.h" // cpuid void diff --git a/src/fw/mtrr.c b/src/fw/mtrr.c index 855457a4..913580e7 100644 --- a/src/fw/mtrr.c +++ b/src/fw/mtrr.c @@ -4,10 +4,11 @@ // // This file may be distributed under the terms of the GNU LGPLv3 license. -#include "util.h" // dprintf #include "config.h" // CONFIG_* #include "hw/pci.h" // pcimem_start +#include "output.h" // dprintf #include "paravirt.h" // RamSize +#include "util.h" // mtrr_setup #include "x86.h" // cpuid #define MSR_MTRRcap 0x000000fe diff --git a/src/fw/paravirt.c b/src/fw/paravirt.c index ea2bbfb8..b76c1dbf 100644 --- a/src/fw/paravirt.c +++ b/src/fw/paravirt.c @@ -8,22 +8,23 @@ // // This file may be distributed under the terms of the GNU LGPLv3 license. -#include "config.h" // CONFIG_QEMU -#include "util.h" // dprintf +#include "acpi.h" // acpi_setup #include "byteorder.h" // be32_to_cpu -#include "ioport.h" // outw -#include "paravirt.h" // qemu_cfg_preinit -#include "smbios.h" // smbios_setup -#include "memmap.h" // add_e820 +#include "config.h" // CONFIG_QEMU #include "hw/cmos.h" // CMOS_* -#include "acpi.h" // acpi_setup -#include "mptable.h" // mptable_setup #include "hw/pci.h" // create_pirtable -#include "xen.h" // xen_biostable_setup +#include "ioport.h" // outw #include "malloc.h" // malloc_tmp +#include "memmap.h" // add_e820 +#include "mptable.h" // mptable_setup +#include "output.h" // dprintf +#include "paravirt.h" // qemu_cfg_preinit #include "romfile.h" // romfile_loadint +#include "smbios.h" // smbios_setup #include "string.h" // memset +#include "util.h" // pci_setup #include "x86.h" // cpuid +#include "xen.h" // xen_biostable_setup // Amount of continuous ram under 4Gig u32 RamSize; diff --git a/src/fw/pciinit.c b/src/fw/pciinit.c index 549c9404..834847b7 100644 --- a/src/fw/pciinit.c +++ b/src/fw/pciinit.c @@ -5,19 +5,20 @@ // // This file may be distributed under the terms of the GNU LGPLv3 license. -#include "util.h" // dprintf +#include "acpi.h" // acpi_pm1a_cnt +#include "config.h" // CONFIG_* +#include "dev-q35.h" // Q35_HOST_BRIDGE_PCIEXBAR_ADDR #include "hw/pci.h" // pci_config_readl #include "hw/pci_ids.h" // PCI_VENDOR_ID_INTEL #include "hw/pci_regs.h" // PCI_COMMAND #include "ioport.h" // PORT_ATA1_CMD_BASE -#include "config.h" // CONFIG_* -#include "memmap.h" // add_e820 -#include "paravirt.h" // RamSize -#include "dev-q35.h" // Q35_HOST_BRIDGE_PCIEXBAR_ADDR #include "list.h" // struct hlist_node -#include "acpi.h" // acpi_pm1a_cnt #include "malloc.h" // free +#include "memmap.h" // add_e820 +#include "output.h" // dprintf +#include "paravirt.h" // RamSize #include "string.h" // memset +#include "util.h" // pci_setup #define PCI_DEVICE_MEM_MIN 0x1000 #define PCI_BRIDGE_IO_MIN 0x1000 diff --git a/src/fw/pirtable.c b/src/fw/pirtable.c index d66d21ba..bd4a6aa4 100644 --- a/src/fw/pirtable.c +++ b/src/fw/pirtable.c @@ -5,9 +5,9 @@ // // This file may be distributed under the terms of the GNU LGPLv3 license. -#include "hw/pci.h" // struct pir_header #include "config.h" // CONFIG_* -#include "util.h" // dprintf +#include "hw/pci.h" // struct pir_header +#include "output.h" // dprintf #include "string.h" // checksum struct pir_header *PirAddr VARFSEG; diff --git a/src/fw/shadow.c b/src/fw/shadow.c index c470592a..82d6753d 100644 --- a/src/fw/shadow.c +++ b/src/fw/shadow.c @@ -5,15 +5,16 @@ // // This file may be distributed under the terms of the GNU LGPLv3 license. -#include "util.h" // dprintf -#include "hw/pci.h" // pci_config_writeb #include "config.h" // CONFIG_* +#include "dev-q35.h" // PCI_VENDOR_ID_INTEL +#include "hw/pci.h" // pci_config_writeb #include "hw/pci_ids.h" // PCI_VENDOR_ID_INTEL #include "hw/pci_regs.h" // PCI_VENDOR_ID -#include "paravirt.h" // runningOnXen -#include "dev-q35.h" // PCI_VENDOR_ID_INTEL #include "malloc.h" // rom_get_last +#include "output.h" // dprintf +#include "paravirt.h" // runningOnXen #include "string.h" // memset +#include "util.h" // make_bios_writable #include "x86.h" // wbinvd // On the emulators, the bios at 0xf0000 is also at 0xffff0000 diff --git a/src/fw/smbios.c b/src/fw/smbios.c index beb31439..a8969dae 100644 --- a/src/fw/smbios.c +++ b/src/fw/smbios.c @@ -5,13 +5,14 @@ // // This file may be distributed under the terms of the GNU LGPLv3 license. -#include "util.h" // dprintf #include "config.h" // CONFIG_* -#include "paravirt.h" // RamSize -#include "smbios.h" // struct smbios_entry_point #include "malloc.h" // free +#include "output.h" // dprintf +#include "paravirt.h" // RamSize #include "romfile.h" // romfile_findprefix +#include "smbios.h" // struct smbios_entry_point #include "string.h" // memset +#include "util.h" // MaxCountCPUs #include "x86.h" // cpuid struct smbios_entry_point *SMBiosAddr; diff --git a/src/fw/smm.c b/src/fw/smm.c index 8ca1e83c..7142ac02 100644 --- a/src/fw/smm.c +++ b/src/fw/smm.c @@ -5,14 +5,15 @@ // // This file may be distributed under the terms of the GNU LGPLv3 license. +#include "config.h" // CONFIG_* +#include "dev-q35.h" #include "hw/pci.h" // pci_config_writel +#include "hw/pci_ids.h" // PCI_VENDOR_ID_INTEL #include "hw/pci_regs.h" // PCI_DEVICE_ID -#include "util.h" // dprintf -#include "config.h" // CONFIG_* #include "ioport.h" // outb -#include "hw/pci_ids.h" // PCI_VENDOR_ID_INTEL -#include "dev-q35.h" +#include "output.h" // dprintf #include "string.h" // memcpy +#include "util.h" // smm_setup #include "x86.h" // wbinvd extern u8 smm_relocation_start, smm_relocation_end; diff --git a/src/fw/smp.c b/src/fw/smp.c index cc6fb80b..b96bcfd7 100644 --- a/src/fw/smp.c +++ b/src/fw/smp.c @@ -5,11 +5,12 @@ // // This file may be distributed under the terms of the GNU LGPLv3 license. -#include "util.h" // dprintf #include "config.h" // CONFIG_* #include "hw/cmos.h" // CMOS_BIOS_SMP_COUNT +#include "output.h" // dprintf #include "romfile.h" // romfile_loadint #include "stacks.h" // yield +#include "util.h" // smp_setup #include "x86.h" // wrmsr #define APIC_ICR_LOW ((u8*)BUILD_APIC_ADDR + 0x300) diff --git a/src/fw/xen.c b/src/fw/xen.c index 84123307..92527211 100644 --- a/src/fw/xen.c +++ b/src/fw/xen.c @@ -4,16 +4,16 @@ // // This file may be distributed under the terms of the GNU LGPLv3 license. -#include "config.h" -#include "xen.h" -#include "paravirt.h" // PlatformRunningOn -#include "memmap.h" // add_e820 -#include "types.h" // ASM32FLAT -#include "util.h" // copy_acpi_rsdp #include "acpi.h" // find_acpi_features +#include "config.h" #include "malloc.h" // memalign_high +#include "memmap.h" // add_e820 +#include "output.h" // dprintf +#include "paravirt.h" // PlatformRunningOn #include "string.h" // memcpy +#include "util.h" // copy_acpi_rsdp #include "x86.h" // cpuid +#include "xen.h" #define INFO_PHYSICAL_ADDRESS 0x00001000 |