From: Ian Campbell <ian.campbell@citrix.com>
To: xen-devel@lists.xensource.com
Cc: Ian Campbell <ian.campbell@citrix.com>
Subject: [PATCH 01 of 19] tools: hvmloader: move ROMBIOS configuration into tools/firmware/rombios/
Date: Tue, 12 Apr 2011 12:29:00 +0100 [thread overview]
Message-ID: <d9ee229bada7659019b8.1302607740@localhost.localdomain> (raw)
In-Reply-To: <patchbomb.1302607739@localhost.localdomain>
# HG changeset patch
# User Ian Campbell <ian.campbell@citrix.com>
# Date 1302597969 -3600
# Node ID d9ee229bada7659019b88ae6b75dd0a8a488714f
# Parent c1d2834bdc3008e0c1f326c85a21d63279932ce5
tools: hvmloader: move ROMBIOS configuration into tools/firmware/rombios/
Currently rombios and hvmloader are rather intertwined. Separate the
ROMBIOS configuration options out into a ROMBIOS provided file so that
the dependency can become strictly from hvmloader to rombios.
Signed-off-by: Ian Campbell <ian.campbell@citrix.com>
diff -r c1d2834bdc30 -r d9ee229bada7 tools/firmware/hvmloader/config.h
--- a/tools/firmware/hvmloader/config.h Tue Apr 12 09:46:09 2011 +0100
+++ b/tools/firmware/hvmloader/config.h Tue Apr 12 09:46:09 2011 +0100
@@ -23,44 +23,13 @@ extern unsigned long pci_mem_start, pci_
#define RESERVED_MEMBASE 0xfc000000
#define RESERVED_MEMSIZE 0x01000000
-#define ROMBIOS_SEG 0xF000
#define ROMBIOS_BEGIN 0x000F0000
#define ROMBIOS_SIZE 0x00010000
#define ROMBIOS_MAXOFFSET 0x0000FFFF
#define ROMBIOS_END (ROMBIOS_BEGIN + ROMBIOS_SIZE)
-/* Memory map. */
-#define SCRATCH_PHYSICAL_ADDRESS 0x00010000
-#define HYPERCALL_PHYSICAL_ADDRESS 0x00080000
+#include "../rombios/config.h"
+
#define VGABIOS_PHYSICAL_ADDRESS 0x000C0000
-#define OPTIONROM_PHYSICAL_ADDRESS 0x000C8000
-#define OPTIONROM_PHYSICAL_END 0x000EA000
-#define BIOS_INFO_PHYSICAL_ADDRESS 0x000EA000
-#define ACPI_PHYSICAL_ADDRESS 0x000EA020
-#define E820_PHYSICAL_ADDRESS 0x000EA100
-#define SMBIOS_PHYSICAL_ADDRESS 0x000EB000
-#define SMBIOS_MAXIMUM_SIZE 0x00005000
-#define ROMBIOS_PHYSICAL_ADDRESS 0x000F0000
-
-/* Offsets from E820_PHYSICAL_ADDRESS. */
-#define E820_NR_OFFSET 0x0
-#define E820_OFFSET 0x8
-
-/* Xen Platform Device */
-#define XEN_PF_IOBASE 0x10
-#define PFFLAG_ROM_LOCK 1 /* Sets whether ROM memory area is RW or RO */
-
-/* Located at BIOS_INFO_PHYSICAL_ADDRESS. */
-struct bios_info {
- uint8_t com1_present:1; /* 0[0] - System has COM1? */
- uint8_t com2_present:1; /* 0[1] - System has COM2? */
- uint8_t lpt1_present:1; /* 0[2] - System has LPT1? */
- uint8_t hpet_present:1; /* 0[3] - System has HPET? */
- uint32_t pci_min, pci_len; /* 4, 8 - PCI I/O hole boundaries */
- uint32_t madt_csum_addr; /* 12 - Address of MADT checksum */
- uint32_t madt_lapic0_addr; /* 16 - Address of first MADT LAPIC struct */
- uint32_t bios32_entry; /* 20 - Entry point for 32-bit BIOS */
-};
-#define BIOSINFO_OFF_bios32_entry 20
#endif /* __HVMLOADER_CONFIG_H__ */
diff -r c1d2834bdc30 -r d9ee229bada7 tools/firmware/rombios/32bit/pmm.c
--- a/tools/firmware/rombios/32bit/pmm.c Tue Apr 12 09:46:09 2011 +0100
+++ b/tools/firmware/rombios/32bit/pmm.c Tue Apr 12 09:46:09 2011 +0100
@@ -65,7 +65,7 @@
#include <stdint.h>
#include <stddef.h>
-#include <../hvmloader/config.h>
+#include "config.h"
#include <../hvmloader/e820.h>
#include "util.h"
diff -r c1d2834bdc30 -r d9ee229bada7 tools/firmware/rombios/config.h
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/tools/firmware/rombios/config.h Tue Apr 12 09:46:09 2011 +0100
@@ -0,0 +1,39 @@
+#ifndef _ROMBIOS_CONFIG_H
+#define _ROMBIOS_CONFIG_H
+
+/* Memory map. */
+#define SCRATCH_PHYSICAL_ADDRESS 0x00010000
+#define HYPERCALL_PHYSICAL_ADDRESS 0x00080000
+
+#define OPTIONROM_PHYSICAL_ADDRESS 0x000C8000
+#define OPTIONROM_PHYSICAL_END 0x000EA000
+#define BIOS_INFO_PHYSICAL_ADDRESS 0x000EA000
+#define ACPI_PHYSICAL_ADDRESS 0x000EA020
+#define E820_PHYSICAL_ADDRESS 0x000EA100
+#define SMBIOS_PHYSICAL_ADDRESS 0x000EB000
+#define SMBIOS_MAXIMUM_SIZE 0x00005000
+#define ROMBIOS_PHYSICAL_ADDRESS 0x000F0000
+
+/* Offsets from E820_PHYSICAL_ADDRESS. */
+#define E820_NR_OFFSET 0x0
+#define E820_OFFSET 0x8
+
+/* Xen Platform Device */
+#define XEN_PF_IOBASE 0x10
+#define PFFLAG_ROM_LOCK 1 /* Sets whether ROM memory area is RW or RO */
+
+/* Located at BIOS_INFO_PHYSICAL_ADDRESS. */
+struct bios_info {
+ uint8_t com1_present:1; /* 0[0] - System has COM1? */
+ uint8_t com2_present:1; /* 0[1] - System has COM2? */
+ uint8_t lpt1_present:1; /* 0[2] - System has LPT1? */
+ uint8_t hpet_present:1; /* 0[3] - System has HPET? */
+ uint32_t pci_min, pci_len; /* 4, 8 - PCI I/O hole boundaries */
+ uint32_t madt_csum_addr; /* 12 - Address of MADT checksum */
+ uint32_t madt_lapic0_addr; /* 16 - Address of first MADT LAPIC struct */
+ uint32_t bios32_entry; /* 20 - Entry point for 32-bit BIOS */
+};
+#define BIOSINFO_OFF_bios32_entry 20
+
+#endif
+
diff -r c1d2834bdc30 -r d9ee229bada7 tools/firmware/rombios/rombios.c
--- a/tools/firmware/rombios/rombios.c Tue Apr 12 09:46:09 2011 +0100
+++ b/tools/firmware/rombios/rombios.c Tue Apr 12 09:46:09 2011 +0100
@@ -29,7 +29,7 @@
#define uint8_t unsigned char
#define uint16_t unsigned short
#define uint32_t unsigned long
-#include "../hvmloader/config.h"
+#include "config.h"
#define HVMASSIST
#undef HVMTEST
next prev parent reply other threads:[~2011-04-12 11:29 UTC|newest]
Thread overview: 22+ messages / expand[flat|nested] mbox.gz Atom feed top
2011-04-12 11:28 [PATCH 00 of 19] tools: SeaBIOS integration Ian Campbell
2011-04-12 11:29 ` Ian Campbell [this message]
2011-04-12 11:29 ` [PATCH 02 of 19] tools: hvmloader: split e820 support into its own code module Ian Campbell
2011-04-12 11:29 ` [PATCH 03 of 19] tools: hvmloader: pass ACPI_PHYSICAL_ADDRESS as a runtime parameter Ian Campbell
2011-04-12 11:29 ` [PATCH 04 of 19] tools: hvmloader: pass SMBIOS location " Ian Campbell
2011-04-12 11:29 ` [PATCH 05 of 19] tools: hvmloader: pass option ROM end address around as a parameter Ian Campbell
2011-04-12 11:29 ` [PATCH 06 of 19] tools: hvmloader: split scratch and hypercall addressing from ROMBIOS low heap Ian Campbell
2011-04-12 11:29 ` [PATCH 07 of 19] tools: hvmloader: refactor Makefile to move ROM filenames into variables Ian Campbell
2011-04-12 11:29 ` [PATCH 08 of 19] tools: hvmloader: remove rombios_sz, just use sizeof(rombios) Ian Campbell
2011-04-12 11:29 ` [PATCH 09 of 19] tools: hvmloader: rename roms.h to roms.inc Ian Campbell
2011-04-12 11:29 ` [PATCH 10 of 19] tools: hvmloader: Define $(OBJS) directly instead of via $(SRCS) Ian Campbell
2011-04-12 11:29 ` [PATCH 11 of 19] tools: hvmloader: add bios_config data structure Ian Campbell
2011-04-12 11:29 ` [PATCH 12 of 19] tools: hvmloader: Refactor APIC, PCI and SMP setup into struct bios_config Ian Campbell
2011-04-12 11:29 ` [PATCH 13 of 19] tools: hvmloader: refactor highbios and bios_info " Ian Campbell
2011-04-12 11:29 ` [PATCH 14 of 19] tools: hvmloader: Refactor VM86 and E820 " Ian Campbell
2011-04-12 11:29 ` [PATCH 15 of 19] tools: hvmloader: Refactor ACPI table " Ian Campbell
2011-04-12 11:29 ` [PATCH 16 of 19] tools: hvmloader: Refactor MP " Ian Campbell
2011-04-12 11:29 ` [PATCH 17 of 19] tools: libxl: hide selection of device-model, hvmloader and BIOS by default Ian Campbell
2011-04-14 18:09 ` Ian Jackson
2011-04-15 7:53 ` Ian Campbell
2011-04-12 11:29 ` [PATCH 18 of 19] tools: hvmloader: select BIOS through xenstore Ian Campbell
2011-04-12 11:29 ` [PATCH 19 of 19] tools: support SeaBIOS. Use by default when upstream qemu is configured Ian Campbell
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=d9ee229bada7659019b8.1302607740@localhost.localdomain \
--to=ian.campbell@citrix.com \
--cc=xen-devel@lists.xensource.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).