History | View | Annotate | Download (35.3 kB)
xen-all.c: fix multiply issue for int and uint types
If the two multiply operands are int and uint types separately,the int type will be transformed to uint firstly, which is not theintent in our code piece. The fix is to add (int64_t) transformfor the uint type before the multiply....
memory: pass EventNotifier, not eventfd
Under Win32, EventNotifiers will not have event_notifier_get_fd, so wecannot call it in common code such as hw/virtio-pci.c. Pass a pointer tothe notifier, and only retrieve the file descriptor in kvm-specific code....
Introduce Xen PCI Passthrough, qdevice
A more complete history can be found here:git://xenbits.xensource.com/qemu-xen-unstable.git
Signed-off-by: Allen Kay <allen.m.kay@intel.com>Signed-off-by: Guy Zana <guy@neocleus.com>Signed-off-by: Anthony PERARD <anthony.perard@citrix.com>...
Call xc_domain_shutdown with the reboot flag when the guest requests a reboot.
Signed-off-by: John V. Baboval <john.baboval@virtualcomputer.com>Signed-off-by: Tom Goetz <tom.goetz@virtualcomputer.com>Signed-off-by: Anthony PERARD <anthony.perard@citrix.com>...
xen: disable rtc_clock
rtc_clock is only used by the RTC emulator (mc146818rtc.c), however Xenhas its own RTC emulator in the hypervisor so we can disable it.
Signed-off-by: Stefano Stabellini <stefano.stabellini@eu.citrix.com>
xen: add a dummy xc_hvm_inject_msi for Xen < 4.2
xc_hvm_inject_msi is only available on Xen >= 4.2: add a dummycompatibility function for Xen < 4.2.
Also enable msi support only on Xen >= 4.2.
Signed-off-by: Stefano Stabellini <stefano.stabellini@eu.citrix.com>...
xen: introduce an event channel for buffered io event notifications
Use the newly introduced HVM_PARAM_BUFIOREQ_EVTCHN to receivenotifications for buffered io events.After the first notification is received leave the event channel maskedand setup a timer to process the rest of the batch....
Xen: basic HVM MSI injection support.
Signed-off-by: Wei Liu <wei.liu2@citrix.com>Signed-off-by: Stefano Stabellini <stefano.stabellini@eu.citrix.com>
Merge remote-tracking branch 'sstabellini/saverestore-8' into staging
xen: record physmap changes to xenstore
Write to xenstore any physmap changes so that the hypervisor can beaware of them.Read physmap changes from xenstore on boot.
xen mapcache: check if memory region has moved.
This patch changes the xen_map_cache behavior. Before trying to map a guestaddr, mapcache will look into the list of range of address that have been moved(physmap/set_memory). There is currently one memory space like this, the vram,...
xen: do not allocate RAM during INMIGRATE runstate
Signed-off-by: Anthony PERARD <anthony.perard@citrix.com>Signed-off-by: Stefano Stabellini <stefano.stabellini@eu.citrix.com>
Rename CPUState -> CPUArchState
Scripted conversion: for file in .[hc] hw/.[hc] hw/kvm/*.[hc] linux-user/*.[hc] linux-user/m68k/*.[hc] bsd-user/*.[hc] darwin-user/*.[hc] tcg/*/*.[hc] target-*/cpu.h; do sed -i "s/CPUState/CPUArchState/g" $file done...
Merge remote-tracking branch 'qemu-kvm/memory/core' into staging
memory: allow MemoryListeners to observe a specific address space
Ignore any regions not belonging to a specified address space.
Signed-off-by: Avi Kivity <avi@redhat.com>
xen: ignore I/O memory regions
memory: support stateless memory listeners
Current memory listeners are incremental; that is, they are expected tomaintain their own state, and receive callbacks for changes to that state.
This patch adds support for stateless listeners; these work by receiving...
memory: switch memory listeners to a QTAILQ
This allows reverse iteration, which in turns allows consistent orderingamong multiple listeners:
l1->add l2->add l2->del l1->del
Signed-off-by: Avi Kivity <avi@redhat.com>Reviewed-by: Richard Henderson <rth@twiddle.net>
memory: move ioeventfd ops to MemoryListener
This way the accelerator (kvm) can handle them directly.
suspend: switch acpi s3 to new infrastructure.
This patch switches pc s3 suspend over to the new infrastructure.The cmos_s3 qemu_irq is killed, the new notifier is used instead.The xen hack goes away with that too, the hypercall can simply bedone in a notifier function now....
memory: change dirty setting APIs to take a size
Instead of each target knowing or guessing the guest page size,just pass the desired size of dirtied memory area.
Signed-off-by: Blue Swirl <blauwirbel@gmail.com>
prepare for future GPLv2+ relicensing
All files under GPLv2 will get GPLv2+ changes starting tomorrow.event_notifier.c and exec-obsolete.h were only ever touched by Red Hatemployees and can be relicensed now.
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>...
xen: Fix after recent change in dirty bitmap tracking.
A recent patch set from Avi break the dirty bitmap support of Xen. Butthis is because xen_sync_dirty_bitmap will return an error for anunhandled memory range (a0000 - bffff). However this is not a fatal...
xen: convert framebuffer dirty tracking to memory API
Reviewed-by: Anthony Liguori <aliguori@us.ibm.com>Signed-off-by: Avi Kivity <avi@redhat.com>
vmstate, memory: decouple vmstate from memory API
Currently creating a memory region automatically registers it forlive migration. This differs from other state (which is enumeratedin a VMStateDescription structure) and ties the live migration codeinto the memory core....
xen: convert to MemoryListener API
xen, vga: add API for registering the framebuffer
Xen currently uses the name of a memory region to determine whether itis the framebuffer. Replace with an explicit API.
xen: convert to memory API
Undo the private implementation of qemu_ram_alloc(); use the global one(which calls right back into xen_ram_alloc()).
memory, xen: pass MemoryRegion to xen_ram_alloc()
Currently xen_ram_alloc() relies on ram_addr, which is going away.Give it something else to use as a cookie.
Replace the VMSTOP macros with a proper state type
Today, when notifying a VM state change with vm_state_notify(),we pass a VMSTOP macro as the 'reason' argument. This is not idealbecause the VMSTOP macros tell why qemu stopped and not exactlywhat the current VM state is....
Drop the vm_running global variable
Use runstate_is_running() instead, which is introduced by this commit.
Signed-off-by: Luiz Capitulino <lcapitulino@redhat.com>
xen: use uint64_t instead of target_ulong in cpu_ioreq_move
cpu_ioreq_move might move 8 bytes at a time so we must make sure thatthe temporary variable can hold 8 bytes.
Use glib memory allocation and free functions
qemu_malloc/qemu_free no longer exist after this commit.
Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
xen: Fix the memory registration to reflect of what is done by Xen.
A Xen guest memory is allocated by libxc. But this memory is notallocated continuously, instead, it leaves the VGA IO memory space notallocated, same for the MMIO space (at HVM_BELOW_4G_MMIO_START of size...
cpu-common: Have a ram_addr_t of uint64 with Xen.
In Xen case, memory can be bigger than the host memory. that mean a32bits host (and QEMU) should be able to handle a RAM address of 64bits.
Signed-off-by: Anthony PERARD <anthony.perard@citrix.com>Signed-off-by: Alexander Graf <agraf@suse.de>
xen: introduce xen_change_state_handler
Remove the call to xenstore_record_dm_state from xen_main_loop_preparethat is HVM specific.Add a new vm_change_state_handler shared between xen_pv and xen_hvmmachines to record the VM state to xenstore.
Signed-off-by: Anthony PERARD <anthony.perard@citrix.com>...
notifier: Pass data argument to callback
This allows to pass additional information to the notifier callbackwhich is useful if sender and receiver do not share any other distinctdata structure.
Will be used first for the clock reset notifier.
Signed-off-by: Jan Kiszka <jan.kiszka@siemens.com>...
xen: add vkbd support for PV on HVM guests
Register the vkbd backend even when running as device emulator for HVMguests: it is useful because it doesn't need a frequent timer like usb.
Check whether the XenInput DisplayState has been set in the initialise...
xen_console: support the new extended xenstore protocol
Since CS 21994 on xen-unstable.hg and CS466608f3a32e1f9808acdf832a5843af37e5fcec on qemu-xen-unstable.git, fewchanges have been introduced to the PV console xenstore protocol, asdescribed by the document docs/misc/console.txt under xen-unstable.hg....
xen: Clean up map cache API naming
The map cache is a Xen thing, so its API should make this clear.
Signed-off-by: Jan Kiszka <jan.kiszka@siemens.com>Signed-off-by: Alexander Graf <agraf@suse.de>
xen: enable console and disk backend in HVM mode
Initialize the Xen console backend and the Xen disk backend even whenrunning in HVM mode so that PV on HVM drivers can connect to them.
Merge remote-tracking branch 'qmp/for-anthony' into staging
xen: only track the linear framebuffer
Xen can only do dirty bit tracking for one memory region, so we shouldexplicitly avoid trying to track anything but the vga vram region.
Signed-off-by: Stefano Stabellini <stefano.stabellini@eu.citrix.com>Signed-off-by: Alexander Graf <agraf@suse.de>
xen: Introduce VGA sync dirty bitmap support
This patch introduces phys memory client for Xen.
Only sync dirty_bitmap and set_memory are actually implemented.migration_log will stay empty for the moment.
Xen can only log one range for bit change, so only the range in the...
Allow silent system resets
This allows qemu_system_reset to be issued silently for internalpurposes, ie. without sending out a monitor event. Convert the systemreset after startup to the silent mode.
Signed-off-by: Jan Kiszka <jan.kiszka@siemens.com>Signed-off-by: Luiz Capitulino <lcapitulino@redhat.com>
xen: Set running state in xenstore.
This tells to the xen management tool that the machine can begin run.
Signed-off-by: Anthony PERARD <anthony.perard@citrix.com>Acked-by: Alexander Graf <agraf@suse.de>Signed-off-by: Alexander Graf <agraf@suse.de>
xen: Add Xen hypercall for sleep state in the cmos_s3 callback.
xen: Introduce Xen Interrupt Controller
Every set_irq call makes a Xen hypercall.
Signed-off-by: Anthony PERARD <anthony.perard@citrix.com>Signed-off-by: Stefano Stabellini <stefano.stabellini@eu.citrix.com>Signed-off-by: Alexander Graf <agraf@suse.de>
xen: Introduce the Xen mapcache
On IA32 host or IA32 PAE host, at present, generally, we can't createan HVM guest with more than 2G memory, because generally it's almostimpossible for Qemu to find a large enough and consecutive virtualaddress space to map an HVM guest's whole physical address space....
xen: Initialize event channels and io rings
Open and bind event channels; map ioreq and buffered ioreq rings.
Signed-off-by: Arun Sharma <arun.sharma@intel.com>Signed-off-by: Anthony PERARD <anthony.perard@citrix.com>Signed-off-by: Stefano Stabellini <stefano.stabellini@eu.citrix.com>...
xen: Add initialisation of Xen
The xenpv machine use the common init function.
xen: Add xenfv machine
Introduce the Xen FV (Fully Virtualized) machine to Qemu, some more Xenspecific call will be added in further patches.
piix_pci: Introduces Xen specific call for irq.
This patch introduces Xen specific call in piix_pci.
The specific part for Xen is in write_config, set_irq and get_pirq.
Signed-off-by: Anthony PERARD <anthony.perard@citrix.com>Signed-off-by: Stefano Stabellini <stefano.stabellini@eu.citrix.com>...