Commit Graph
8313 Commits
Author SHA1 Message Date
vhanquez@kneesa.uk.xensource.com dc5e7fd510 Allows a 'make prep-kernels' which sets up the kernel directories, allowing
certain types of test automation to be done more easily.

Signed-off-by: Paul Larson <pl@us.ibm.com>
2005-12-10 00:11:33 +00:00
emellor@leeni.uk.xensource.com 2fdffd69ae Merged. 2005-12-09 11:05:06 +00:00
stekloff@elm3b216.beaverton.ibm.com 86867006af Add initial VMX support to xm-test:
1) Added script create_disk_image to make full virt image
2) Changed XenDomain.py to build separate XmTestDomain object
   for vmx guests (this structure will need to be cleaned up)
3) Changed ramdisk Makefile.am to create disk.img if vmx configured

Signed-off-by: Daniel Stekloff <dsteklof@us.ibm.com>
2005-12-09 11:04:55 +00:00
emellor@leeni.uk.xensource.com 53dcf75ccb Merged. 2005-12-09 10:51:35 +00:00
emellor@leeni.uk.xensource.com 3732520993 Use new do_without_error function to squelch the error when closing down the
interface.

Signed-off-by: Ewan Mellor <ewan@xensource.com>
2005-12-09 10:51:20 +00:00
emellor@leeni.uk.xensource.com c9392b836d Use new do_without_error function to squelch the errors when closing down an
interface.

Signed-off-by: Ewan Mellor <ewan@xensource.com>
2005-12-09 10:50:49 +00:00
emellor@leeni.uk.xensource.com c542b41feb Added do_without_error function, and squelch the error from mkdir when trying
to create the lock directory.

Signed-off-by: Ewan Mellor <ewan@xensource.com>
2005-12-09 10:50:26 +00:00
emellor@leeni.uk.xensource.com 9ab74b250b Add one more fork to the Xend start-up process, this time with the parent
staying alive to watch the child.  If the child crashes, then the parent
starts another one in its place.  This provides robustness in the face of
crashes like one currently tracked as bug #411.

Tidy up chunks of SrvDaemon.py on the way past.

Signed-off-by: Ewan Mellor <ewan@xensource.com>
2005-12-09 10:49:29 +00:00
emellor@leeni.uk.xensource.com 293e54c10b Two domUs, ping from one to the other
Signed-off-by: Jim Dykman <dykman@us.ibm.com>
2005-12-09 10:40:41 +00:00
emellor@leeni.uk.xensource.com 1df940267e Single domU, ping to dom0.
Signed-off-by: Jim Dykman <dykman@us.ibm.com>
2005-12-09 10:40:28 +00:00
emellor@leeni.uk.xensource.com ef4e38f80a Single domU, ping loopback and the local eth0.
Signed-off-by: Jim Dykman <dykman@us.ibm.com>
2005-12-09 10:40:00 +00:00
emellor@leeni.uk.xensource.com bb1275eca8 Some network test utilities for the library:
Signed-off-by: Jim Dykman <dykman@us.ibm.com>
2005-12-09 10:39:31 +00:00
emellor@leeni.uk.xensource.com 92f0952573 Makefile plumbing for new network tests.
Signed-off-by: Jim Dykman <dykman@us.ibm.com>
2005-12-09 10:39:16 +00:00
kaf24@firebug.cl.cam.ac.uk 92fb778f03 Fix blkback to build on ia64.
Signed-off-by: Dan Magenheimer <dan.magenheimer@hp.com>
2005-12-09 09:29:52 +01:00
emellor@leeni.uk.xensource.com 548733e866 The attached patch makes a couple of changes to the ACM security tools
and installation. Particularly it does the following:
- the Makefile installs the ACM security-related tools
into /etc/xen/acm-security
- improves and cleans up some of the tools
- updates the documentation

Signed-off-by: Tom Lendacky <toml@us.ibm.com>
Signed-off-by: Stefan Berger <stefanb@us.ibm.com>
2005-12-08 18:21:05 +00:00
emellor@leeni.uk.xensource.com ced2f6408d The attached patch uncouples the device id used inside XenD from the
instance number of the vTPM.

Signed-off-by: Stefan Berger <stefanb@us.ibm.com>
2005-12-08 18:19:24 +00:00
emellor@leeni.uk.xensource.com 028268e9bc Looks like someone merged and moved the pincpu operation to after the
memory reservation and didn't read the comments I left in the code:

# repin domain vcpus if a restricted cpus list is provided
# this is done prior to memory allocation to aide in memory
# distribution for NUMA systems.

This patch moves the pincpu op back to where it was.

Signed-off-by: Ryan Harper <ryanh@us.ibm.com>
2005-12-08 18:17:59 +00:00
emellor@leeni.uk.xensource.com d2b3b7424b Detach Xend from terminal, courtesy of Horms <horms@verge.net.au>.
* For setsid to effectively detach a process from the terminal,
  the following needs to occur:

    fork ()   Return control to the shell
    setsid () New session with no controlling terminal
    fork ()   The session leader (parent) exits and thus
              the resulting child process can never regain the terminal

  This patch adds the second fork

* The call to self.daemonize(), which now forks, is moved to
  run before self.tracing(), as now that it actually disconnects
  from the terminal, and thus the prevailing process, the trace
  loses the processes created in self.run().

Signed-off-by: Ewan Mellor <ewan@xensource.com>
2005-12-08 16:17:53 +00:00
emellor@leeni.uk.xensource.com 72bb6de0e0 Flush the addresses from the new eth0 before trying to add the new address to
it, when using ip on the kernel command line and not using the installed ifup /
ifdown.  This stops the script bailing out if there is already an address
attached to that device, which was leaving the device without routing (since
this has already been removed).

Fix the stop action under the same circumstances.  No attempt was made to
restore the kernel command line details to the interfaces if the ifdown failed
in that case.

Signed-off-by: Ewan Mellor <ewan@xensource.com>
2005-12-08 16:11:48 +00:00
kaf24@firebug.cl.cam.ac.uk 98bea19681 Allocate separate vm areas for rx and tx rings in netback
driver as part of preparation for ia64 support.

Signed-off-by: Dan Magenheimer <dan.magenheimer@hp.com>
2005-12-08 16:58:41 +01:00
emellor@leeni.uk.xensource.com 458dbeddf3 Fix ip_of to cope with interfaces with multiple addresses, courtesy of
Adam Heath <doogie@brainfood.com>.
 
Signed-off-by: Ewan Mellor <ewan@xensource.com>
2005-12-08 15:54:35 +00:00
kaf24@firebug.cl.cam.ac.uk 3361d4d041 Support CFQ scheduling of guest block requests by creating
a kernel thread per blkif connection. General cleanup work
in blkback driver.

Signed-off-by: Gerd Knorr <kraxel@suse.de>
2005-12-08 16:53:53 +01:00
emellor@leeni.uk.xensource.com d0caf30ebb Merged. 2005-12-08 15:04:41 +00:00
emellor@leeni.uk.xensource.com ae0212521e Strip huge piles of cruft from the connection infrastructure. We now actually
block inside accept rather than using select to poll and then calling accept
regardless of the outcome of the select call, and then failing because the
socket is non-blocking.

SocketClientConnection, SocketConnector, TCPClientConnection, TCPConnector,
connectTCP, UnixClientConnection, UnixConnector, connectUnix have gone.

loseConnection and stopListening and closeSocket (where they are needed) are
now called close.  startListening is now called listen.

Closes bug #379.

Relieves a weight from the shoulders of the universe.

Signed-off-by: Ewan Mellor <ewan@xensource.com>
2005-12-08 15:04:31 +00:00
kaf24@firebug.cl.cam.ac.uk e50c7df410 Make balloon driver arch-neutral.
Signed-off-by: Dan Magenheimer <dan.magenheimer@hp.com>
2005-12-08 15:33:10 +01:00
emellor@leeni.uk.xensource.com 5ea39e7063 Move xm destroy handling out of crufty destroy.py and into main.py, where it
can share the better argument parsing.

Closes bug #443.

Signed-off-by: Ewan Mellor <ewan@xensource.com>
2005-12-08 14:30:15 +00:00
emellor@leeni.uk.xensource.com 6a6999e3fb Fix start_time parsing on restart -- it's a float, not an int.
Signed-off-by: Ewan Mellor <ewan@xensource.com>
2005-12-08 14:28:53 +00:00
kaf24@firebug.cl.cam.ac.uk df17685613 A small VMX code cleanup.
Signed-off-by: Eddie Dong <eddie.dong@intel.com>
2005-12-08 15:25:44 +01:00
kaf24@firebug.cl.cam.ac.uk 7fc4533b32 Merge in the newer Xenbus implementation from Linux to the Mini-OS. The new
version compiles and starts up, but I'm not really sure how to test the new
xenbus implementation.

* Added unbind_evtchn
* Copied parts of the Linux spinlock implementation to make the changes to
  xenbus compared to Linux smaller. Also added a dummy rwsem implementation.
* Updated the xenbus-files

Signed-off-by: Simon Kagstrom <simon.kagstrom@bth.se>
2005-12-08 15:24:02 +01:00
kaf24@firebug.cl.cam.ac.uk bc70813814 Don't unshadow when the shadow l2 is the current used shadow table.
Otherwise, when destroying the domain, if the current sl2 is unpinned
then the shadow page will be freed without accquire the shadow_lock.
This may also improve the performance due to avoiding uncessary
unshadow.

Signed-off-by: Xiaofeng Ling <xiaofeng.ling@intel.com>
2005-12-08 15:21:36 +01:00
kaf24@firebug.cl.cam.ac.uk 064a4d414b Fixed a get/put_page mismatch for guest L2 pages. Sometimes, when you
destroy an OS when it is in real mode, there is an extra put_page in
domain_relinquish_resource.  This causes the page be freed with
non-zero type count.  With ASSERT enabled, hypervisor will crash; with
debug=n, on some machines, the system will hang in
alloc_domheap_pages, due to type_info being a union with cpumask and
not equal to 0.

Signed-off-by: Xiaofeng Ling <xiaofeng.ling@intel.com>
2005-12-08 15:18:13 +01:00
kaf24@firebug.cl.cam.ac.uk f3fc4cd304 Improve VMX guest TSC accuracy when guests are
competing for the same physical CPU.

Signed-off-by: Eddie Dong <eddie.dong@intel.com>
2005-12-08 15:13:38 +01:00
emellor@leeni.uk.xensource.com 1c68755227 Merged. 2005-12-08 12:14:33 +00:00
emellor@leeni.uk.xensource.com 5c896ea1a5 Loop retrying when ballooning out, even when the dom0-min-mem setting means
that there is not sufficient memory available at the moment.  Memory may be
about to be freed up by the system after a domain destruction (i.e. the memory
is being scrubbed asynchronously, and will be released soon).

Closes bug #407, bug #429.

Signed-off-by: Ewan Mellor <ewan@xensource.com>
2005-12-08 12:13:06 +00:00
emellor@leeni.uk.xensource.com 83c3ceb178 Read start_time and image from the store on restart. Closes bugs #441 and
#442.

Signed-off-by: Ewan Mellor <ewan@xensource.com>
2005-12-08 12:10:22 +00:00
emellor@leeni.uk.xensource.com 7b4fe715a5 Refuse to save dom0, and move the check that refuses to migrate dom0 from
migrate.py into XendDomain.

Signed-off-by: Ewan Mellor <ewan@xensource.com>
2005-12-08 12:08:59 +00:00
vhanquez@kneesa.uk.xensource.com df5dc503db really fix mkpatches to work correctly.
unfortunately, add some code duplication in mkpatches area.

Signed-off-by: Vincent Hanquez <vincent@xensource.com>
2005-12-08 08:57:55 +00:00
vhanquez@kneesa.uk.xensource.com cc5c32ece6 fix mkpatches for creating correctly linux-2.6-xen.patch
Signed-off-by: Vincent Hanquez <vincent@xensource.com>
2005-12-08 08:09:09 +00:00
vhanquez@kneesa.uk.xensource.com c2c982f908 allow a port to be specified for migration.
Signed-off-by: Vincent Hanquez <vincent@xensource.com>
2005-12-08 07:11:09 +00:00
smh22@firebug.cl.cam.ac.uk 91df848ca6 Updated info on Xend.
Signed-off-by: Nivedita Singhvi <niv@us.ibm.com>
Signed-off-by: Robb Romans <FMJ@us.ibm.com>
Signed-off-by: Steven Hand <steven@xensource.com>
2005-12-07 18:59:33 +01:00
emellor@leeni.uk.xensource.com d96a859929 Don't try and print out the info returned by the server after a restore -- there
isn't any.  Don't try and unpause the restored domain either -- XendCheckpoint
does that.

Signed-off-by: Ewan Mellor <ewan@xensource.com>
2005-12-07 16:26:07 +00:00
emellor@leeni.uk.xensource.com 4213a82e5b Use xm create's --dryrun option to get the name from the configuration file,
rather than the eversoskanky approach taken previously (use grep, and replace
any occurrences of %d with [0-9]* !)

Signed-off-by: Ewan Mellor <ewan@xensource.com>
2005-12-07 16:25:13 +00:00
danms@us.ibm.com d8fdcac4df Make the xm-test ramdisk makefile correct the permissions on the rcS script
Signed-off-by: Dan Smith <danms@us.ibm.com>
2005-12-07 15:50:59 +00:00
emellor@leeni.uk.xensource.com afa150ca7c Fix the startup behaviour when the tdb file exists. We were attempting to
remove and recreate the /local directory, but the manual_node call only works
if the tdb is empty -- we must use create_node, otherwise the store is
corrupted.

It's not clear to me that the other manual_node calls are safe, but I have only
made this smaller change for the sake of stability.  These other calls should
be reviewed.

Signed-off-by: Ewan Mellor <ewan@xensource.com>
2005-12-07 15:44:38 +00:00
emellor@leeni.uk.xensource.com a16c06e77e Fix usleep definition -- we would be sleeping 1000 times too long if the usleep
command were not available elsewhere on the machine (on my Debian boxes, for
example).

Sleep for a configurable amount of time between xm create calls (by default,
5 seconds).  This spaces out the booting of the new domains, meaning that they
should not thrash the disk so much.

Signed-off-by: Ewan Mellor <ewan@xensource.com>
2005-12-07 15:41:41 +00:00
emellor@leeni.uk.xensource.com 11d655cef6 Tidy up use of environment variables in xenbus-hotplug interaction.
I've changed this to only write "backend" (xenbus_backend.root) into
XENBUS_BASE_PATH.  After appending XENBUS_TYPE (also exported) you can
construct the "base path" easily in the scripts.  I've completely
removed writing XENBUS_FRONTEND_ID in favour of reading it from the
store at "$XENBUS_PATH/frontend-id".

Avoid re-reading the store over and over for the frontend domain's vm-path.

The patch also fixes a memory leak in backend_bus_id where we
leak the memory referenced by frontend if the function succeeds.

This work is by Christian Limpach.

Signed-off-by: Ewan Mellor <ewan@xensource.com>
2005-12-07 11:57:26 +00:00
emellor@leeni.uk.xensource.com e21406c453 Merged. 2005-12-07 11:51:31 +00:00
emellor@leeni.uk.xensource.com 5e61562a32 Change configuration handling wrt to the vcpus entry, so that we only see a
vcpus entry in the image section when using VMX, only add VMX options at all
if the builder is vmx, and issue a warning when overriding the global vcpus
setting with the one from the image.

This removes the duplicated vcpus entries in the domain's sxpr.

Signed-off-by: Ewan Mellor <ewan@xensource.com>
2005-12-07 11:50:55 +00:00
emellor@leeni.uk.xensource.com 497ff155b3 Remove timeout on select -- there is no need for it, since we don't do anything
in the main loop except service I/O.

Signed-off-by: Ewan Mellor <ewan@xensource.com>
2005-12-07 11:47:46 +00:00
emellor@leeni.uk.xensource.com d688d94c83 Merged. 2005-12-07 11:44:02 +00:00