Commit Graph
496 Commits
Author SHA1 Message Date
kaf24@firebug.cl.cam.ac.uk 79434e94bd Get rid of anonymous unions in public header files.
Signed-off-by: Keir Fraser <keir@xensource.com>
2005-09-14 13:13:10 +00:00
kaf24@firebug.cl.cam.ac.uk 3886819443 Remove unsued domain_controller.h file.
Signed-off-by: Keir Fraser <keir@xensource.com>
2005-09-14 10:58:00 +00:00
kaf24@firebug.cl.cam.ac.uk e1517da4cd Move hypervisor.h to asm-i386/asm-x86_64.
Signed-off-by: Keir Fraser <keir@xensource.com>
2005-09-14 09:17:44 +00:00
djm@kirby.fc.hp.com af29c1116d Converge ia64 grant_table API 2005-09-13 14:20:02 -06:00
djm@kirby.fc.hp.com b7b0e47a54 Add ia64 header for synch_bitops.h 2005-09-13 13:08:00 -06:00
kaf24@firebug.cl.cam.ac.uk a6869d9d5c synch_bitops.h is an arch-specific header file.
Signed-off-by: Keir Fraser <keir@xensource.com>
2005-09-13 10:40:29 +00:00
cl349@firebug.cl.cam.ac.uk 493519fd23 Change xenbus_dev interface from ioctl to read/write.
Check boundaries so we can recover if userspace dies.
Also simplifies libxenstore.
Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
Signed-off-by: Christian Limpach <Christian.Limpach@cl.cam.ac.uk>
2005-09-12 21:12:16 +00:00
kaf24@firebug.cl.cam.ac.uk 15a40c9975 Xen_version hypercalls takes two args, not one.
Signed-off-by: Ian Pratt <ian@xensource.com>
Signed-off-by: Keir Fraser <keir@xensource.com>
2005-09-12 12:29:40 +00:00
iap10@freefall.cl.cam.ac.uk f2f33db0f4 Replace direct_remap_area_pages with direct_remap_pfn_range to help fix PAE domain building.
Signed-off-by: ian@xensource.com
2005-09-07 23:10:49 +00:00
cl349@firebug.cl.cam.ac.uk 7a36d2e972 Remove control interface in kernels and domain builder.
Signed-off-by: Christian Limpach <Christian.Limpach@cl.cam.ac.uk>
2005-09-07 17:43:56 +00:00
kaf24@firebug.cl.cam.ac.uk 65de2eefe9 The attached patch fixes two problems I ran into with the swiotlb code
in unstable (changeset aeaa3c83f6e5). Tested on a dual Opteron x86-64
machine with 4GB of memory and a tg3 modified to only DMA below 2GB.

- swiotlb_dma_supported() checked that the device DMA mask was equal
or bigger than 4GB, when in fact all that's needed is that the device
be able to DMA into the swiotlb aperture (1GB on my AMD x86-64
machine). Some device are actually only 31-bit DMA capable, so this
would've tripped them.

- On some platforms, PCI unmaps and syncs are nops, so there's no need to
keep track of the dma_addr they need after the initial mapping. The
DMA API supports this via the DECLARE_PCI_UNMAP_ADDR macros (see
Documentation/DMA-mapping.txt). Since the swiotlb code does make us of
the dma_addr for swiotlb_unmap_xxx and (more importantly)
swiotlb_dma_sync_xxx, we need to define them to something
meaningful.

Signed-Off-By: Muli Ben-Yehuda <mulix@mulix.org>
2005-09-06 18:25:00 +00:00
kaf24@firebug.cl.cam.ac.uk d22c0aa835 phys_to_mach and mach_to_phys tables contain long entries, not
32-bit entries.

Signed-off-by: Keir Fraser <keir@xensource.com>
2005-09-06 18:01:24 +00:00
cl349@firebug.cl.cam.ac.uk 311f8312d8 Get rid of suspend record, start info holds all the info now.
Signed-off-by: Christian Limpach <Christian.Limpach@cl.cam.ac.uk>
2005-09-05 14:53:39 +00:00
cl349@firebug.cl.cam.ac.uk ce27fde65d Keep start_info in page provided by domain builder instead of making a copy.
- page is moved next to store/console pages -- these are never put in the
  free page pool by the domain
- xen_start_info is now a pointer to the original page instead of the copy
Signed-off-by: Christian Limpach <Christian.Limpach@cl.cam.ac.uk>
2005-09-05 14:04:36 +00:00
cl349@firebug.cl.cam.ac.uk b8ea605500 Add driver to use the kernel's xenbus connection from user-space.
The driver exports xs_talkv to user-space, allowing programs running in
the domain to use the kernel's xenbus connection.  Intended use is driver
domain device configuration where the driver domain is not the domain
running xenstored.
Signed-off-by: Christian Limpach <Christian.Limpach@cl.cam.ac.uk>
2005-09-03 16:52:12 +00:00
cl349@firebug.cl.cam.ac.uk 074210e720 Restore configurability of vif bring up script and passing arguments to the script.
Signed-off-by: Christian Limpach <Christian.Limpach@cl.cam.ac.uk>
2005-09-02 14:15:49 +00:00
cl349@firebug.cl.cam.ac.uk f3b2046b07 merge? 2005-09-01 10:16:14 +00:00
cl349@firebug.cl.cam.ac.uk 3f17c675d9 Linux 2.6 cleanups.
Signed-off-by: Christian Limpach <Christian.Limpach@cl.cam.ac.uk>
2005-09-01 08:25:22 +00:00
shand@ubuntu.eng.hq.xensource.com 19d427f223 merge? 2005-08-31 15:22:45 -08:00
kaf24@firebug.cl.cam.ac.uk 8eb4861753 Fix non-SMP build, broken by the previous changeset.
Signed-off-by: Keir Fraser <keir@xensource.com>
2005-08-31 14:53:43 +00:00
kaf24@firebug.cl.cam.ac.uk 9aed763981 Fix DEBUG_PREEMPT builds. irq_disabled() macro must not use
smp_processor_id(). Use the underlying function instead.

Signed-off-by: Keir Fraser <keir@xensource.com>
2005-08-31 14:20:56 +00:00
shand@ubuntu.eng.hq.xensource.com 54ad03b947 TPM front-end and back-end implementation, and configuration updates.
Signed-off-by: Stefan Berger <stefanb@us.ibm.com>
Signed-off-by: Kylene Hall <kjhall@us.ibm.com>
Signed-off-by: Mahadevan Gomathisankaran <gmdev@iastate.edu>
Signed-off-by: Steven Hand <steven@xensource.com>
2005-08-30 11:48:08 -08:00
kaf24@firebug.cl.cam.ac.uk e4dfe0cdba Replace dom_mem_op hypercall with memory_op hypercall with
better interface. Fix "mem=" parameter on x86/64 boot.

Signed-off-by: Keir Fraser <keir@xensource.com>
2005-08-30 11:53:47 +00:00
kaf24@firebug.cl.cam.ac.uk edf2226577 Clean up and fix hypercall macros in XenLinux: we must assume that
all register parameters are clobbered on return. Furthermore,
multicall arrays are clobbered on return from a multicall (only the
result field can be trusted!).

These restrictions are enforced by debug builds of Xen in the
following ways:
 1. On completion of a multicall, the call array is overwritten
    with garbage before writing in the result fields.
 2. On completion of a hypercall, all parameter registers are
    overwritten with garbage.

Signed-off-by: Keir Fraser <keir@xensource.com>
2005-08-26 17:42:34 +00:00
kaf24@firebug.cl.cam.ac.uk 8a181133e2 The patched attached enables x86_64 xenlinux with "late pin, early
unpin", which is already implemented for x86_32. Since we now only pin
the root rather than any of the other levels, the overall performance
became better especially with workloads that require heavy memory
management operations.

On 8-way x86_64 xenlinux (dom0) the kernel build was improved by about
10% (using make -j32). Even a small setup like a UP HT system, I see
about 3% performance gain with kernel build (make -j4).

Lmbench also shows improvements in fork/exec/sh:
Processor, Processes - times in microseconds - smaller is better
--------------------------------------------------------------------
Host    OS  Mhz   null null      open slct sig  sig  fork exec sh =20
                  call  I/O stat clos TCP  inst hndl proc proc proc
--------- ------------- ---- ---- ---- ---- ---- ---- ---- ---- ----=20
Linux 2.6.12- 3786 1.13 1.36 3.93 6.04 10.5 1.43 4.33 536. 1446 3614
Linux 2.6.12- 3786 1.13 1.36 3.91 6.03 10.4 1.44 4.38 346. 1050 2831

Signed-off-by: Jun Nakajima <jun.nakajima@intel.com>
2005-08-26 11:02:14 +00:00
kaf24@firebug.cl.cam.ac.uk 0c01ed4935 This patch fixes Bugzilla #169. (It should fix #187 too -- Keir).
The root cause of bug 169 is, machine_to_phys_mapping, starting from
0xffff800000000000, is mapped using 2M pages.  When the system has RAM
no more than 2G, only one 2M page is allocated and only one PDE entry is
created correspondingly, so calling mfn_to_pfn with mfn > 0x80000 will
overflow this 2M page and cause a unable handled kernel paging request.
The mfn > 0x80000 comes from PCI device I/O memory, here from AGP
display card when booting X server.  Jun suggested to use something like
get_user() when accessing machine_to_phys_mapping.

Signed-off-by: Xin Li <xin.b.li@intel.com>
2005-08-25 16:21:19 +00:00
kaf24@firebug.cl.cam.ac.uk 6e08df4d05 Fix grant-ref allocation in netfront.
Signed-off-by: Keir Fraser <keir@xensource.com>
2005-08-25 14:30:06 +00:00
kaf24@firebug.cl.cam.ac.uk 8e7d2037c7 Always free the lowest 1MB of pseudo-physical memory when booting
a guest.

Signed-off-by: Keir Fraser <keir@xensource.com>
2005-08-24 15:46:33 +00:00
cl349@firebug.cl.cam.ac.uk ae28fe8a0e merge? 2005-08-23 17:33:11 +00:00
cl349@firebug.cl.cam.ac.uk 54a17fbc83 Cleanup grant table code.
- keep count of free references 
- let callbacks specify the number of references they need at least
- get rid of terminal reference
- simplify and more correct locking for callbacks
Signed-off-by: Christian Limpach <Christian.Limpach@cl.cam.ac.uk>
2005-08-23 13:11:31 +00:00
kaf24@firebug.cl.cam.ac.uk 88977254c3 phys_to_machine_mapping array is not an array of longs.
Fix start-of-day code and FOREIGN_FRAME() macro in light 
of this. Also fix pfn_to_mfn() to mask off the foreign-frame
marker bit. The few places where we rely on that bit we read
out of the array directly, rather than using the pfn_to_mfn()
accessor macro.

This fixes, among other things, booting domU on PAE with swiotlb
disabled.

Signed-off-by: Keir Fraser <keir@xensource.com>
2005-08-23 12:30:35 +00:00
cl349@firebug.cl.cam.ac.uk 6a141a1783 g/c struct work_struct declaration.
Signed-off-by: Christian Limpach <Christian.Limpach@cl.cam.ac.uk>
2005-08-23 09:33:48 +00:00
cl349@firebug.cl.cam.ac.uk 49c9090275 merge? 2005-08-23 08:40:58 +00:00
cl349@firebug.cl.cam.ac.uk b4d1caa528 Use explicit functions with args instead of work_structs for callbacks.
Signed-off-by: Christian Limpach <Christian.Limpach@cl.cam.ac.uk>
2005-08-23 08:40:50 +00:00
cl349@firebug.cl.cam.ac.uk 3c047eef3c Grant table updates for block device changes.
- add gnttab_free_grant_reference
- make gnttab_free_grant_references interface consistent with other gnttab
  functions
- add support for callback when references are freed
Signed-off-by: Christian Limpach <Christian.Limpach@cl.cam.ac.uk>
2005-08-22 20:52:38 +00:00
kaf24@firebug.cl.cam.ac.uk f84addf449 Apply Ross Mcilroy's balloon_dealloc_empty_page_range patch
and generally clean up the ballon driver a bunch.
Signed-off-by: Keir Fraser <keir@xensource.com>
2005-08-22 16:38:13 +00:00
kaf24@firebug.cl.cam.ac.uk defa5b4d1e merge. 2005-08-19 17:57:00 +00:00
kaf24@firebug.cl.cam.ac.uk 4fa9c861ef Fix x86/64 build by defining correct vcpu_pickle(). 2005-08-19 17:56:20 +00:00
cl349@firebug.cl.cam.ac.uk 2c26ae3399 merge? 2005-08-19 17:38:31 +00:00
cl349@firebug.cl.cam.ac.uk 1511aa3b38 Improve error paths and cleanup code.
Signed-off-by: Christian Limpach <Christian.Limpach@cl.cam.ac.uk>
2005-08-19 17:38:07 +00:00
kaf24@firebug.cl.cam.ac.uk 40326f9fc3 Simplify pagetable initialisation. Since swapper_pg_dir now
is the one allocated by the domain builder, we can be sure
it is below 4GB (essential for PAE).

Signed-off-by: Keir Fraser <keir@xensource.com>
2005-08-19 16:46:51 +00:00
kaf24@firebug.cl.cam.ac.uk 4e4ffc8edf Fix many uses of machine addresses in XenLinux. Primarily
this fixes users of virt_to_machine/machine_to_virt to
use virt_to_mfn/mfn_to_virt where that is more appropriate.

This should be a big step to improved PAE stability.

Signed-off-by: Keir Fraser <keir@xensource.com>
2005-08-19 16:06:43 +00:00
sos22@douglas.cl.cam.ac.uk df3303d149 Merge.
Signed-off-by: Steven Smith, sos22@cam.ac.uk
2005-08-19 15:47:19 +00:00
sos22@douglas.cl.cam.ac.uk b3c5293807 This time, it's fixed.
Signed-off-by: Steven Smith, sos22@cam.ac.uk
2005-08-19 15:37:37 +00:00
sos22@douglas.cl.cam.ac.uk 4ba5dde553 Merge.
Signed-off-by: Steven Smith, sos22@cam.ac.uk
2005-08-19 10:50:15 +00:00
cl349@firebug.cl.cam.ac.uk e9eaa6bafb Remove support for xenbus driver subtypes since with the subtype field there's no fallback.
Signed-off-by: Christian Limpach <Christian.Limpach@cl.cam.ac.uk>
2005-08-18 19:51:46 +00:00
cl349@firebug.cl.cam.ac.uk 90562ffd56 Get rid of xenbus_uuid_to_domid - get the frontend id from the node.
We don't want to parse paths we read out of the store to _construct_
other paths and tie down the store layout for no good reason.
Also require the frontend path to exist and be valid before creating
the device.
Signed-off-by: Christian Limpach <Christian.Limpach@cl.cam.ac.uk>
2005-08-18 19:21:09 +00:00
cl349@firebug.cl.cam.ac.uk 096a4beccf merge? 2005-08-18 18:55:13 +00:00
cl349@firebug.cl.cam.ac.uk 7f434cccbf Update probe code for backend layout.
Backend directories are of form backend/<type>/<frontend-uuid>/<id>.
This extra level makes an asymmetry with front ends (device/type/id) and
are too long to make nice bus-ids under Linux, but the code isn't too
horrible, and an OS which only wants to be a guest doesn't need to implement
it. It allows backends to calculate the front-end path directly, which
is a nice benefit.
Also: subtype matching is tightened: they must match exactly. That way a future
variant which requires a specific driver will not match current drivers.
Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
Signed-off-by: Christian Limpach <Christian.Limpach@cl.cam.ac.uk>
2005-08-18 18:54:38 +00:00
sos22@douglas.cl.cam.ac.uk 1be1e1ccd3 A really nasty workaround for a race.
Signed-off-by: Steven Smith, sos22@cam.ac.uk
2005-08-18 16:28:41 +00:00