kaf24@firebug.cl.cam.ac.uk
6b38c4a0e1
Move public hvm interfaces into xen/include/public/hvm.
...
Add new header hvm_info_table.h for defining location and
contents of acpi-style hvm_info_table. Remove duplicate
definition in vmxassist/acpi_madt.c.
Signed-off-by: Keir Fraser <keir@xensource.com >
2006-01-03 14:58:34 +01:00
kaf24@firebug.cl.cam.ac.uk
29c3bf78b9
Rename VMX option name lapic to apic, and pass it to xen by
...
hvm_info_table. Previous we pass it to xen by guest vcpu context ECX
register, now we unify to use hvm_info_table.
Signed-off-by: Xin Li <xin.b.li@intel.com >
2006-01-03 14:35:45 +01:00
kaf24@firebug.cl.cam.ac.uk
cfa0fac2c2
Provide an option to disable ACPI from the VMX config file.
...
By default ACPI is disabled.
Signed-off-by: Yu Ke <ke.yu@intel.com >
Signed-off-by: Jun Nakajima <jun.nakajima@intel.com >
Signed-off-by: Nitin A Kamble <nitin.a.kamble@intel.com >
2006-01-01 11:29:17 +01:00
kaf24@firebug.cl.cam.ac.uk
7e127cd35f
Allow non-privileged domains restricted access to
...
I/O memory and physical interrupts, under control
of domain0. Capabilities are maintained as rangesets
in Xen.
Signed-off-by: Ryan Wilson <hap9@epoch.ncsc.mil >
Signed-off-by: Keir Fraser <keir@xensource.com >
2005-12-31 14:15:22 +01:00
kaf24@firebug.cl.cam.ac.uk
0129e126c4
Avoid xen crash if there is no VMX support. If a platform
...
doesn't support VMX, creating VMX domain will crash xen
HV.
Signed-off-by: Xin Li <xin.b.li@intel.com >
2005-12-30 17:07:34 +01:00
Ian.Campbell@xensource.com
40924689a9
Add support to xenctx for printing stack traces on x86_32 and x86_64.
...
To support this add xc_translate_foreign_address to libxc. This function
walks page tables and translates virtual addresses using a given domain
and vcpu page table.
Signed-off-by: Ian Campbell <Ian.Campbell@XenSource.com >
2005-12-22 14:33:19 +00:00
djm@kirby.fc.hp.com
a220ae9a8d
Merge
2005-12-21 11:56:19 -06:00
djm@kirby.fc.hp.com
08b3de8dee
diff -r 545ba1b126ca tools/libxc/xc_linux_build.c
...
--- a/tools/libxc/xc_linux_build.c Tue Dec 20 20:11:17 2005
+++ b/tools/libxc/xc_linux_build.c Wed Dec 21 11:50:08 2005
@@ -296,9 +296,13 @@
unsigned long *page_array = NULL;
struct load_funcs load_funcs;
struct domain_setup_info dsi;
+ unsigned long vinitrd_start;
+ unsigned long vinitrd_end;
+ unsigned long v_end;
unsigned long start_page, pgnr;
start_info_t *start_info;
int rc;
+ unsigned long i;
rc = probeimageformat(image, image_size, &load_funcs);
if ( rc != 0 )
@@ -310,11 +314,13 @@
if ( rc != 0 )
goto error_out;
- dsi.v_start = round_pgdown(dsi.v_start);
- dsi.v_end = round_pgup(dsi.v_end);
+ dsi.v_start = round_pgdown(dsi.v_start);
+ vinitrd_start = round_pgup(dsi.v_end);
+ vinitrd_end = vinitrd_start + initrd_len;
+ v_end = round_pgup(vinitrd_end);
start_page = dsi.v_start >> PAGE_SHIFT;
- pgnr = (dsi.v_end - dsi.v_start) >> PAGE_SHIFT;
+ pgnr = (v_end - dsi.v_start) >> PAGE_SHIFT;
if ( (page_array = malloc(pgnr * sizeof(unsigned long))) == NULL )
{
PERROR("Could not allocate memory");
@@ -326,9 +332,38 @@
PERROR("Could not get the page frame list");
goto error_out;
}
+
+#define _p(a) ((void *) (a))
+
+ printf("VIRTUAL MEMORY ARRANGEMENT:\n"
+ " Loaded kernel: %p->%p\n"
+ " Init. ramdisk: %p->%p\n"
+ " TOTAL: %p->%p\n",
+ _p(dsi.v_kernstart), _p(dsi.v_kernend),
+ _p(vinitrd_start), _p(vinitrd_end),
+ _p(dsi.v_start), _p(v_end));
+ printf(" ENTRY ADDRESS: %p\n", _p(dsi.v_kernentry));
(load_funcs.loadimage)(image, image_size, xc_handle, dom, page_array,
&dsi);
+
+ /* Load the initial ramdisk image. */
+ if ( initrd_len != 0 )
+ {
+ for ( i = (vinitrd_start - dsi.v_start);
+ i < (vinitrd_end - dsi.v_start); i += PAGE_SIZE )
+ {
+ char page[PAGE_SIZE];
+ if ( gzread(initrd_gfd, page, PAGE_SIZE) == -1 )
+ {
+ PERROR("Error reading initrd image, could not");
+ goto error_out;
+ }
+ xc_copy_to_domain_page(xc_handle, dom,
+ page_array[i>>PAGE_SHIFT], page);
+ }
+ }
+
*pvke = dsi.v_kernentry;
@@ -358,6 +393,13 @@
start_info->store_evtchn = store_evtchn;
start_info->console_mfn = nr_pages - 1;
start_info->console_evtchn = console_evtchn;
+ if ( initrd_len != 0 )
+ {
+ ctxt->initrd.start = vinitrd_start;
+ ctxt->initrd.size = initrd_len;
+ }
+ strncpy((char *)ctxt->cmdline, cmdline, IA64_COMMAND_LINE_SIZE);
+ ctxt->cmdline[IA64_COMMAND_LINE_SIZE-1] = '\0';
munmap(start_info, PAGE_SIZE);
free(page_array);
diff -r 545ba1b126ca xen/arch/ia64/xen/dom_fw.c
--- a/xen/arch/ia64/xen/dom_fw.c Tue Dec 20 20:11:17 2005
+++ b/xen/arch/ia64/xen/dom_fw.c Wed Dec 21 11:50:08 2005
@@ -861,9 +861,14 @@
bp->console_info.orig_x = 0;
bp->console_info.orig_y = 24;
bp->fpswa = 0;
- bp->initrd_start = (dom0_start+dom0_size) -
- (PAGE_ALIGN(ia64_boot_param->initrd_size) + 4*1024*1024);
- bp->initrd_size = ia64_boot_param->initrd_size;
+ if (d == dom0){
+ bp->initrd_start = (dom0_start+dom0_size) -
+ (PAGE_ALIGN(ia64_boot_param->initrd_size) + 4*1024*1024);
+ bp->initrd_size = ia64_boot_param->initrd_size;
+ }else{
+ bp->initrd_start = d->arch.initrd_start;
+ bp->initrd_size = d->arch.initrd_len;
+ }
printf(" initrd start %0xlx", bp->initrd_start);
printf(" initrd size %0xlx", bp->initrd_size);
diff -r 545ba1b126ca xen/arch/ia64/xen/domain.c
--- a/xen/arch/ia64/xen/domain.c Tue Dec 20 20:11:17 2005
+++ b/xen/arch/ia64/xen/domain.c Wed Dec 21 11:50:08 2005
@@ -297,6 +297,9 @@
*regs = c->regs;
d->arch.sys_pgnr = c->sys_pgnr;
+ d->arch.initrd_start = c->initrd.start;
+ d->arch.initrd_len = c->initrd.size;
+ d->arch.cmdline = c->cmdline;
new_thread(v, regs->cr_iip, 0, 0);
v->vcpu_info->arch.evtchn_vector = c->vcpu.evtchn_vector;
@@ -365,7 +368,7 @@
regs->r28 = dom_fw_setup(d,saved_command_line,256L);
else {
regs->ar_rsc |= (2 << 2); /* force PL2/3 */
- regs->r28 = dom_fw_setup(d,"nomca nosmp xencons=tty0 console=tty0 root=/dev/hda1",256L); //FIXME
+ regs->r28 = dom_fw_setup(d,d->arch.cmdline,256L);
}
VCPU(v, banknum) = 1;
VCPU(v, metaphysical_mode) = 1;
diff -r 545ba1b126ca xen/include/asm-ia64/domain.h
--- a/xen/include/asm-ia64/domain.h Tue Dec 20 20:11:17 2005
+++ b/xen/include/asm-ia64/domain.h Wed Dec 21 11:50:08 2005
@@ -38,6 +38,9 @@
u64 image_len;
u64 entry;
#endif
+ unsigned long initrd_start;
+ unsigned long initrd_len;
+ char *cmdline;
};
#define xen_vastart arch.xen_vastart
#define xen_vaend arch.xen_vaend
diff -r 545ba1b126ca xen/include/public/arch-ia64.h
--- a/xen/include/public/arch-ia64.h Tue Dec 20 20:11:17 2005
+++ b/xen/include/public/arch-ia64.h Wed Dec 21 11:50:08 2005
@@ -276,6 +276,12 @@
unsigned long start_info_pfn;
} arch_shared_info_t;
+typedef struct {
+ unsigned long start;
+ unsigned long size;
+} arch_initrd_info_t;
+
+#define IA64_COMMAND_LINE_SIZE 512
typedef struct vcpu_guest_context {
#define VGCF_FPU_VALID (1<<0)
#define VGCF_VMX_GUEST (1<<1)
@@ -289,6 +295,8 @@
cpu_user_regs_t regs;
arch_vcpu_info_t vcpu;
arch_shared_info_t shared;
+ arch_initrd_info_t initrd;
+ char cmdline[IA64_COMMAND_LINE_SIZE];
} vcpu_guest_context_t;
#endif /* !__ASSEMBLY__ */
2005-12-21 09:07:09 -06:00
kaf24@firebug.cl.cam.ac.uk
b5bdea9ad6
This patch fix several issue to support >2G 64bit vmx guest in IA-32e
...
platform, it includes:
1) One fix on xc_vmx_build.c
2) Change ram_size/phys_ram_size in qemu from int to uint64_t
3) One fix on pcnet unsigned short to unsigned long conversion.
Signed-off-by: Yunhong Jiang <yunhong.jiang@intel.com >
Signed-off-by: Xin Li <xin.b.li@intel.com >
2005-12-20 12:50:09 +01:00
djm@kirby.fc.hp.com
2137b122b6
Small patch to avoid a stack overflow (VTI only).
...
Signed-off-by: Tristan Gingold <tristan.gingold@bull.net >
2005-12-15 14:51:10 -06:00
kaf24@firebug.cl.cam.ac.uk
026d31df5c
Add debugging flag for domains to make domu debugging a run-time option
...
Signed-off-by: Kip Macy kmacy@fsmware.ckm
2005-12-15 21:50:12 +01:00
kaf24@firebug.cl.cam.ac.uk
1f5fb04e43
Add MP debug support to gdbserver.
...
Signed-off-by: Kip Macy <kip.macy@gmail.com >
2005-12-15 21:02:21 +01:00
cl349@firebug.cl.cam.ac.uk
c4b7794669
Make version strings consistent across all interfaces.
...
Signed-off-by: Christian Limpach <Christian.Limpach@cl.cam.ac.uk >
2005-12-04 18:16:33 +01:00
smh22@firebug.cl.cam.ac.uk
2b039aa937
Fix VBD recovery logic on SMP guests (+ a minor error reporting fix for save)
...
Signed-off-by: Steven Hand <steven@xensource.com >
2005-12-01 20:43:04 +01:00
kaf24@firebug.cl.cam.ac.uk
96428d33d9
Define explicit evtchn_port_t type (32 bits) and plumb up
...
to user space thru /dev/xen/evtchn.
Signed-off-by: Keir Fraser <keir@xensource.com >
2005-12-01 15:22:22 +01:00
emellor@leeni.uk.xensource.com
f814d1f288
Merged.
2005-11-30 19:55:08 +00:00
emellor@leeni.uk.xensource.com
df2ba9e15b
Added the errno to the messages printed with the ERR macro. Tidy the use of
...
this macro where newlines have been appended -- the macro does this itself so
there is no need to add another one.
Signed-off-by: Ewan Mellor <ewan@xensource.com >
2005-11-30 18:38:14 +00:00
kaf24@firebug.cl.cam.ac.uk
ba3f55e57a
GNTTABOP_map_grant_ref returns error status and handle as
...
separate fields. Update callers for new interface. Also
use int16_t as standard error code type on all public
interfaces.
Signed-off-by: Keir Fraser <keir@xensource.com >
2005-11-30 17:24:27 +01:00
kaf24@firebug.cl.cam.ac.uk
9bd97f28fa
Bundle vcpu_time and vcpu_info structures together into a single
...
structure that is 64 bytes on x86. This ensures that indexing into
the array is fast (power-of-two size) and that accesses are cache
friendly (cache line size is usually 32 or 64 bytes).
Rename vcpu_data to vcpu_info, vcpu_time to vcpu_info.time.
Signed-off-by: Keir Fraser <keir@xensource.com >
2005-11-28 19:48:54 +01:00
cl349@firebug.cl.cam.ac.uk
016ef02e87
Move mk-symlinks target into tools/Rules.mk.
...
Signed-off-by: Christian Limpach <Christian.Limpach@cl.cam.ac.uk >
2005-11-28 18:07:22 +01:00
smh22@firebug.cl.cam.ac.uk
c7458fa52e
Fix formatting.
...
Signed-off-by: Steven Hand <steven@xensource.com >
2005-11-26 12:17:35 +01:00
smh22@firebug.cl.cam.ac.uk
d8fa063ad2
Fix save/restore and migrate on x86_64.
...
Signed-off-by: Steven Hand <steven@xensource.com >
2005-11-26 12:13:39 +01:00
kaf24@firebug.cl.cam.ac.uk
83120737f5
Implement new memory_op() XENMEM_machphys_mfn_list. Replaces old
...
privcmd Linux ioctl and includes an implementation for x86/64.
Signed-off-by: Keir Fraser <keir@xensource.com >
2005-11-25 18:43:35 +01:00
smh22@firebug.cl.cam.ac.uk
4d58b5d8ba
Tolerate temporary inconsistency between type info and page contents on
...
(live) restore. This should now enable live migrate of fork-intensive (or
other page-table-intensive) workloads.
Signed-off-by: Steven Hand <steven@xensource.com >
2005-11-25 17:53:41 +01:00
smh22@firebug.cl.cam.ac.uk
9661835101
Re-enable tools support for live migration on PAE.
...
Signed-off-by: Steven Hand <steven@xensource.com >
2005-11-24 16:32:38 +01:00
emellor@leeni.uk.xensource.com
f6d80a7f57
Reverse accidental commits for changesets 8001 and 7996-7999.
...
The Mercurial Queues extensions suddenly looks a lot less useful than it first
seemed.
Signed-off-by: Ewan Mellor <ewan@xensource.com >
2005-11-23 19:37:33 +00:00
emellor@leeni.uk.xensource.com
a640b7c2dd
imported patch quiet_linux_build.patch
2005-11-23 19:19:24 +00:00
emellor@leeni.uk.xensource.com
8856d17150
imported patch my-config
2005-11-23 19:19:23 +00:00
sos22@douglas.cl.cam.ac.uk
05607bfc8f
Make sure that accesses to the machine_to_phys table all go through
...
suitable macros.
Signed-off-by: Steven Smith, sos22@cam.ac.uk
2005-11-23 13:34:25 +01:00
kaf24@firebug.cl.cam.ac.uk
869e86d8e6
Add -Wdeclaration-after-statement to Xen and tools build.
...
Fix the compile errors that result from this.
Signed-off-by: Keir Fraser <keir@xensource.com >
2005-11-22 18:44:08 +01:00
smh22@firebug.cl.cam.ac.uk
49e566a9aa
Tidy up debugging output.
...
Signed-off-by: Steven Hand <steven@xensource.com >
2005-11-22 18:21:22 +01:00
smh22@firebug.cl.cam.ac.uk
1b5fd028bf
Better handle page type info becoming incoherent during live migrate.
...
Signed-off-by: Steven Hand <steven@xensource.com >
2005-11-22 17:50:41 +01:00
emellor@leeni.uk.xensource.com
ee19599218
Merged.
2005-11-22 17:00:56 +01:00
emellor@leeni.uk.xensource.com
a22292f2bb
Make it possible to run valgrind on code linked with the libxc libraries.
...
Valgrind cannot see when a hypercall has initialised entries in a data
structure, so appropriate memsets have been placed before using dom0_op_t,
privcmd_hypercall_t, and a couple of miscellaneous blocks passed into this
layer. This initialises the block so that valgrind considers it to be valid,
but the data therein will be immediately overwritten by the hypercall, all
being well.
These changes are semantically neutral if -DVALGRIND is not set.
Signed-off-by: Ewan Mellor <ewan@xensource.com >
2005-11-22 16:31:16 +01:00
kaf24@firebug.cl.cam.ac.uk
d35dd33f4c
Ignore live flag on PAE/64-bit migrations, rather than
...
failing the migration entirely.
Signed-off-by: Keir Fraser <keir@xensource.com >
2005-11-22 12:04:03 +01:00
kaf24@firebug.cl.cam.ac.uk
9ba9cbdb3f
Update the memory_op() hypercall. Add two new subcommands, to
...
query a domain's current and maximum memory reservation. Also,
XENMEM_maximum_ram_page now returns the max_page directly,
rather than writing through a passed-in pointer.
Also, disable PAE in the default config (accidentally checked
in two changesets ago).
Signed-off-by: Keir Fraser <keir@xensource.com >
2005-11-21 16:56:39 +01:00
smh22@firebug.cl.cam.ac.uk
7cdf0f6407
Fix 'belt + braces' check in xc_linux_save and improve error handling
...
for live migrate (this includes making shadow enable idempotent).
Signed-off-by: Steven Hand <steven@xensource.com >
2005-11-21 16:40:16 +01:00
djm@kirby.fc.hp.com
6b7047253a
Recode usage of FPSR_DEFAULT due to strange double declaration
2005-11-19 15:41:08 -06:00
kaf24@firebug.cl.cam.ac.uk
e39174283d
Disable live relocation for PAE and x86/64. Currently it can
...
seriously harm Xen's health. Better to just disable it in the
tools until the outstanding issues are resolved.
Signed-off-by: Keir Fraser <keir@xensource.com >
2005-11-18 13:51:20 +01:00
smh22@firebug.cl.cam.ac.uk
a041c675c7
Fix pinning logic on restore.
...
Signed-off-by: Steven Hand <steven@xensource.com >
2005-11-17 10:10:52 +01:00
smh22@firebug.cl.cam.ac.uk
0f2781b12e
One more try...
...
Signed-off-by: Steven Hand <steven@xensource.com >
2005-11-16 18:41:43 +01:00
smh22@firebug.cl.cam.ac.uk
5aebcfee2a
Fix annoying error introduced during cleanup. Oops.
...
Signed-off-by: Steven Hand <steven@xensource.com >
2005-11-16 18:28:09 +01:00
smh22@tempest.cl.cam.ac.uk
99e88d6dd7
Trivial fixes for 64bit and xend.
...
Signed-off-by: Steven Hand <steven@xensource.com >
2005-11-16 18:03:48 +01:00
smh22@firebug.cl.cam.ac.uk
4c908cf0e3
Many fixes for save/restore and related areas for PAE in particular. Now
...
should be able to save/restore successfully on machines with up to 16GB
and any size of guest.
Signed-off-by: Steven Hand <steven@xensource.com >
2005-11-16 17:45:03 +01:00
kaf24@firebug.cl.cam.ac.uk
568a59e7fc
Rename XENVER_parameters to slightly more informative
...
XENVER_platform_parameters.
Signed-off-by: Keir Fraser <keir@xensource.com >
2005-11-16 12:44:12 +01:00
kaf24@firebug.cl.cam.ac.uk
3d95cc36a0
Fix up start_info_t magic string to match the format of
...
XENVER_capabilities strings.
Signed-off-by: Keir Fraser <keir@xensource.com >
2005-11-16 12:23:17 +01:00
kaf24@firebug.cl.cam.ac.uk
26ed038491
Clean up xenstore/console shared page initialisation, which is
...
now handled solely by the domain builder.
Signed-off-by: Keir Fraser <keir@xensource.com >
2005-11-14 11:36:42 +01:00
kaf24@firebug.cl.cam.ac.uk
3947efa1c2
Revert accidentally applied changes from changeset
...
7783:5aad7e145e501fbfb346954950a33b042a963633.
Signed-off-by: Keir Fraser <keir@xensource.com >
2005-11-14 11:35:50 +01:00
kaf24@firebug.cl.cam.ac.uk
e7b975b0b6
If /sbin/ isn't in the path, udev rules will erroneously not get
...
installed.
Signed-off-by: Nivedita Singhvi <niv@us.ibm.com >
2005-11-14 11:05:34 +01:00
kaf24@firebug.cl.cam.ac.uk
f8e8438eef
Remove unnecessary NULL checks before freeing memory blocks.
...
The following functions check for NULL internally:
free, kfree, xfree, free_xenheap_page[s]
Signed-off-by: Keir Fraser <keir@xensource.com >
2005-11-11 12:55:47 +01:00