ChangeSet 1.1441, 2005/05/11 17:18:30+01:00, kaf24@xxxxxxxxxxxxxxxxxxxx
Change the Xen command-line parameter syntax. 'noacpi' and
'ignorebiostables' are gone. 'dom0_mem' can optionally take a k/m/g
suffix to specify units (default units are still kilobytes).
Also added:
1. 'mem=xxx' to specify maximum physical RAM address (supports
k/m/g suffix)
2. acpi=xxx/acpi_skip_timer_override/noapic: These all have same
semantics as in Linux. They are *automatically* propagated to
the domain0 command line, as dom0 shares resposibility for
platform initialisation.
Signed-off-by: Keir Fraser <keir@xxxxxxxxxxxxx>
docs/src/user.tex | 55 +++++++++------
xen/arch/ia64/xensetup.c | 5 -
xen/arch/x86/domain_build.c | 16 +++-
xen/arch/x86/e820.c | 31 ++++++++
xen/arch/x86/setup.c | 152 +++++++++++++++++++++++++++-----------------
xen/arch/x86/smpboot.c | 10 +-
xen/common/kernel.c | 22 +-----
xen/common/lib.c | 16 ++++
xen/include/asm-x86/acpi.h | 77 ++++++++++++----------
xen/include/xen/init.h | 10 +-
xen/include/xen/lib.h | 13 ++-
11 files changed, 256 insertions(+), 151 deletions(-)
diff -Nru a/docs/src/user.tex b/docs/src/user.tex
--- a/docs/src/user.tex 2005-05-11 13:05:28 -04:00
+++ b/docs/src/user.tex 2005-05-11 13:05:28 -04:00
@@ -484,7 +484,7 @@
{\small
\begin{verbatim}
title Xen 2.0 / XenLinux 2.6.9
- kernel /boot/xen.gz dom0_mem=131072
+ kernel /boot/xen.gz dom0_mem=128M
module /boot/vmlinuz-2.6.9-xen0 root=/dev/sda4 ro console=tty0
\end{verbatim}
}
@@ -524,7 +524,7 @@
\subsection{Serial Console (optional)}
-%% kernel /boot/xen.gz dom0_mem=131072 com1=115200,8n1
+%% kernel /boot/xen.gz dom0_mem=128M com1=115200,8n1
%% module /boot/vmlinuz-2.6.9-xen0 root=/dev/sda4 ro
@@ -534,9 +534,9 @@
\begin{quote}
{\small
\begin{verbatim}
- kernel /boot/xen.gz dom0_mem=131072 com1=115200,8n1
+ kernel /boot/xen.gz dom0_mem=128M com1=115200,8n1
\end{verbatim}}
-\end{quote}
+\end{quote}
This configures Xen to output on COM1 at 115,200 baud, 8 data bits,
1 stop bit and no parity. Modify these parameters for your set up.
@@ -1680,12 +1680,6 @@
editing \path{grub.conf}.
\begin{description}
-\item [ignorebiostables ]
- Disable parsing of BIOS-supplied tables. This may help with some
- chipsets that aren't fully supported by Xen. If you specify this
- option then ACPI tables are also ignored, and SMP support is
- disabled.
-
\item [noreboot ]
Don't reboot the machine automatically on errors. This is
useful to catch debug output if you aren't catching console messages
@@ -1695,10 +1689,6 @@
Disable SMP support.
This option is implied by `ignorebiostables'.
-\item [noacpi ]
- Disable ACPI tables, which confuse Xen on some chipsets.
- This option is implied by `ignorebiostables'.
-
\item [watchdog ]
Enable NMI watchdog which can report certain failures.
@@ -1756,8 +1746,16 @@
`nmi=dom0': Inform DOM0 of the NMI. \\
`nmi=ignore': Ignore the NMI.
+\item [mem=xxx ]
+ Set the physical RAM address limit. Any RAM appearing beyond this
+ physical address in the memory map will be ignored. This parameter
+ may be specified with a {\bf k}, {\bf m} or {\bf g} suffix. The
+ default unit, if no suffix is specified, is bytes.
+
\item [dom0\_mem=xxx ]
- Set the amount of memory (in kB) to be allocated to domain0.
+ Set the amount of memory to be allocated to domain0. This parameter
+ may be specified with a {\bf k}, {\bf m} or {\bf g} suffix. The
+ default unit, if no suffix is specified, is kilobytes.
\item [tbuf\_size=xxx ]
Set the size of the per-cpu trace buffers, in pages
@@ -1769,16 +1767,29 @@
Select the CPU scheduler Xen should use. The current
possibilities are `bvt' (default), `atropos' and `rrobin'.
For more information see Section~\ref{s:sched}.
-
-\item [physdev\_dom0\_hide=(xx:xx.x)(yy:yy.y)\ldots ]
-Hide selected PCI devices from domain 0 (for instance, to stop it
-taking ownership of them so that they can be driven by another
-domain). Device IDs should be given in hex format. Bridge devices do
-not need to be hidden --- they are hidden implicitly, since guest OSes
-do not need to configure them.
\end{description}
+In addition, the following platform-specific options may be specified
+on the Xen command line. Since domain 0 shares responsibility for
+booting the platform, Xen will automatically propagate these options
+to its command line.
+
+These options are taken from Linux's command-line syntax with
+unchanged semantics.
+
+\begin{description}
+\item [acpi=off,force,strict,ht,noirq,\ldots ]
+ Modify how Xen (and domain 0) parses the BIOS ACPI tables.
+
+\item [acpi\_skip\_timer\_override ]
+ Instruct Xen (and domain 0) to ignore timer-interrupt override
+ instructions specified by the BIOS ACPI tables.
+
+\item [noapic ]
+ Instruct Xen (and domain 0) to ignore any IOAPICs that are present in
+ the system, and instead continue to use the legacy PIC.
+\end{description}
\section{XenLinux Boot Options}
diff -Nru a/xen/arch/ia64/xensetup.c b/xen/arch/ia64/xensetup.c
--- a/xen/arch/ia64/xensetup.c 2005-05-11 13:05:28 -04:00
+++ b/xen/arch/ia64/xensetup.c 2005-05-11 13:05:28 -04:00
@@ -52,15 +52,10 @@
unsigned int opt_dom0_mem = 16000;
/* opt_noht: If true, Hyperthreading is ignored. */
int opt_noht=0;
-/* opt_noacpi: If true, ACPI tables are not parsed. */
-int opt_noacpi=0;
/* opt_nosmp: If true, secondary processors are ignored. */
int opt_nosmp=0;
/* opt_noreboot: If true, machine will need manual reset on error. */
int opt_noreboot=0;
-/* opt_ignorebiostables: If true, ACPI and MP tables are ignored. */
-/* NB. This flag implies 'nosmp' and 'noacpi'. */
-int opt_ignorebiostables=0;
/* opt_watchdog: If true, run a watchdog NMI on each processor. */
int opt_watchdog=0;
/* opt_pdb: Name of serial port for Xen pervasive debugger (and enable pdb) */
diff -Nru a/xen/arch/x86/domain_build.c b/xen/arch/x86/domain_build.c
--- a/xen/arch/x86/domain_build.c 2005-05-11 13:05:28 -04:00
+++ b/xen/arch/x86/domain_build.c 2005-05-11 13:05:28 -04:00
@@ -7,6 +7,7 @@
#include <xen/config.h>
#include <xen/init.h>
#include <xen/lib.h>
+#include <xen/ctype.h>
#include <xen/sched.h>
#include <xen/smp.h>
#include <xen/delay.h>
@@ -21,9 +22,18 @@
#include <asm/i387.h>
#include <asm/shadow.h>
-/* opt_dom0_mem: Kilobytes of memory allocated to domain 0. */
-static unsigned int opt_dom0_mem = 0;
-integer_unit_param("dom0_mem", opt_dom0_mem);
+/* opt_dom0_mem: memory allocated to domain 0. */
+static unsigned int opt_dom0_mem;
+static void parse_dom0_mem(char *s)
+{
+ unsigned long long bytes = memparse(s);
+ /* If no unit is specified we default to kB units, not bytes. */
+ if ( isdigit(s[strlen(s)-1]) )
+ opt_dom0_mem = (unsigned int)bytes;
+ else
+ opt_dom0_mem = (unsigned int)(bytes >> 10);
+}
+custom_param("dom0_mem", parse_dom0_mem);
static unsigned int opt_dom0_shadow = 0;
boolean_param("dom0_shadow", opt_dom0_shadow);
diff -Nru a/xen/arch/x86/e820.c b/xen/arch/x86/e820.c
--- a/xen/arch/x86/e820.c 2005-05-11 13:05:28 -04:00
+++ b/xen/arch/x86/e820.c 2005-05-11 13:05:28 -04:00
@@ -3,6 +3,11 @@
#include <xen/lib.h>
#include <asm/e820.h>
+/* opt_mem: Limit of physical RAM. Any RAM beyond this point is ignored. */
+unsigned long long opt_mem;
+static void parse_mem(char *s) { opt_mem = memparse(s); }
+custom_param("mem", parse_mem);
+
struct e820map e820;
static void __init add_memory_region(unsigned long long start,
@@ -341,6 +346,31 @@
#define clip_4gb() ((void)0)
#endif
+static void __init clip_mem(void)
+{
+ int i;
+
+ if ( !opt_mem )
+ return;
+
+ for ( i = 0; i < e820.nr_map; i++ )
+ {
+ if ( (e820.map[i].addr + e820.map[i].size) <= opt_mem )
+ continue;
+ printk("Truncating memory map to %lukB\n",
+ (unsigned long)(opt_mem >> 10));
+ if ( e820.map[i].addr >= opt_mem )
+ {
+ e820.nr_map = i;
+ }
+ else
+ {
+ e820.map[i].size = opt_mem - e820.map[i].addr;
+ e820.nr_map = i + 1;
+ }
+ }
+}
+
static void __init machine_specific_memory_setup(
struct e820entry *raw, int raw_nr)
{
@@ -348,6 +378,7 @@
sanitize_e820_map(raw, &nr);
(void)copy_e820_map(raw, nr);
clip_4gb();
+ clip_mem();
}
unsigned long __init init_e820(struct e820entry *raw, int raw_nr)
diff -Nru a/xen/arch/x86/setup.c b/xen/arch/x86/setup.c
--- a/xen/arch/x86/setup.c 2005-05-11 13:05:28 -04:00
+++ b/xen/arch/x86/setup.c 2005-05-11 13:05:28 -04:00
@@ -33,23 +33,29 @@
int opt_noht = 0;
boolean_param("noht", opt_noht);
-/* opt_noacpi: If true, ACPI tables are not parsed. */
-static int opt_noacpi = 0;
-boolean_param("noacpi", opt_noacpi);
-
-/* opt_nosmp: If true, secondary processors are ignored. */
-static int opt_nosmp = 0;
-boolean_param("nosmp", opt_nosmp);
-
-/* opt_ignorebiostables: If true, ACPI and MP tables are ignored. */
-/* NB. This flag implies 'nosmp' and 'noacpi'. */
-static int opt_ignorebiostables = 0;
-boolean_param("ignorebiostables", opt_ignorebiostables);
-
/* opt_watchdog: If true, run a watchdog NMI on each processor. */
static int opt_watchdog = 0;
boolean_param("watchdog", opt_watchdog);
+/* **** Linux config option: propagated to domain0. */
+/* "acpi=off": Sisables both ACPI table parsing and interpreter. */
+/* "acpi=force": Override the disable blacklist. */
+/* "acpi=strict": Disables out-of-spec workarounds. */
+/* "acpi=ht": Limit ACPI just to boot-time to enable HT. */
+/* "acpi=noirq": Disables ACPI interrupt routing. */
+static void parse_acpi_param(char *s);
_______________________________________________
Xen-changelog mailing list
Xen-changelog@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-changelog
|