History | View | Annotate | Download (123.8 kB)
monitor: allow to disable the default monitor
Signed-off-by: Luiz Capitulino <lcapitulino@redhat.com>
vl: new runstate transition: RUN_STATE_GUEST_PANICKED -> RUN_STATE_FINISH_MIGRATE
This fixes a problem that after guest panic happens, virsh dump without--memory-only fails:
ERROR: invalid runstate transition: 'guest-panicked' -> 'finish-migrate'
Reported-by: Christian Borntraeger <borntraeger@de.ibm.com>...
clean unnecessary code: don't check g_strdup arg for NULL
Signed-off-by: Dong Xu Wang <wdongxu@linux.vnet.ibm.com>Signed-off-by: Michael Tokarev <mjt@tls.msk.ru>
Drop redundant resume_all_vcpus() from main()
VCPUs are either resumed directly via vm_start(), after the incomingmigration is done, or when a continue command is issued. We don't needthe explicit resume before entering main_loop().
Signed-off-by: Jan Kiszka <jan.kiszka@siemens.com>...
cpu: Call cpu_synchronize_post_init() from DeviceClass::realize()
If hotplugged, synchronize CPU state to KVM.
Signed-off-by: Igor Mammedov <imammedo@redhat.com>Reviewed-by: Eduardo Habkost <ehabkost@redhat.com>Signed-off-by: Andreas Färber <afaerber@suse.de>
add a new runstate: RUN_STATE_GUEST_PANICKED
The guest will be in this state when it is panicked.
Signed-off-by: Wen Congyang <wency@cn.fujitsu.com>Signed-off-by: Hu Tao <hutao@cn.fujitsu.com>Reviewed-by: Markus Armbruster <armbru@redhat.com>Message-id: 0255f263ffdc2a3716f73e89098b96fd79a235b3.1366945969.git.hutao@cn.fujitsu.com...
audio: enable PCI audio cards for all PCI-enabled targets
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>Message-id: 1366303444-24620-9-git-send-email-pbonzini@redhat.comSigned-off-by: Anthony Liguori <aliguori@us.ibm.com>
audio: remove HAS_AUDIO
Several targets can have wavcapture/-soundhw support via PCI cards.HAS_AUDIO is a useless limitation, remove it.
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>Message-id: 1366303444-24620-4-git-send-email-pbonzini@redhat.com...
Common: Add quick access to first boot device
Instead of manually parsing the boot_list as character stream,we can access the nth boot device, specified by the position in theboot order.
Signed-off-by: Dominik Dingel <dingel@linux.vnet.ibm.com>Reviewed-by: Anthony Liguori <aliguori@us.ibm.com>...
Move TPM passthrough specific command line options to backend structure
Move the TPM passthrough specific command line options to the passthroughbackend implementation and attach them to the backend's interface structure.
Add code to tpm.c for validating the TPM command line options....
Add option to mlock qemu and guest memory
In certain scenario, latency induced by paging is significant andmemory locking is needed. Also, in the scenario with untrustedguests, latency improvement due to mlock is desired.
This patch introduces a following new option to mlock guest and...
console: move gui_update+gui_setup_refresh from vl.c into console.c
Pure code motion, no functional changes.
Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
console: displaystate init revamp
We have only one DisplayState, so there is no need for the "next" linking, rip it. Also consolidate all displaystate initializationinto init_displaystate(). This function is called by vl.c aftercreating the devices (and thus all QemuConsoles) and before...
Merge remote-tracking branch 'bonzini/hw-dirs' into staging
Allow qtest to be used together with a virtual CPU
Signed-off-by: Edgar E. Iglesias <edgar.iglesias@gmail.com>Message-id: 1366054097-14132-1-git-send-email-edgar.iglesias@gmail.comSigned-off-by: Anthony Liguori <aliguori@us.ibm.com>
tpm: reorganize headers and split hardware part
The TPM subsystem does not have a full front-end/back-end separation.The sole available backend, tpm_passthrough, depends on the datastructures of the sole available frontend, tpm_tis.
However, we can at least try to split the user interface (tpm.c) from the...
sysemu: avoid proliferation of include/ subdirectories
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
Revert "New QMP command query-cpu-max and HMP command cpu_max"
This reverts commit 4d700430a20b3d53b7b15bc5f6666f7e570e3f2c as asked byLuiz. The patch has been obsoleted by extending MachineInfo structureby cpu-max field.
Signed-off-by: Michal Novotny <minovotn@redhat.com>...
New cpu-max field in query-machines QMP command output
Alter the query-machines QMP command to output information aboutmaximum number of CPUs for each machine type with default valueset to 1 in case the number of max_cpus is not set.
hw: move headers to include/
Many of these should be cleaned up with proper qdev-/QOM-ification.Right now there are many catch-all headers in include/hw/ARCH dependingon cpu.h, and this makes it necessary to compile these files per-target.However, fixing this does not belong in these patches....
strip some whitespace
Signed-off-by: Laszlo Ersek <lersek@redhat.com>Reviewed-by: Anthony Liguori <aliguori@us.ibm.com>Message-id: 1363821803-3380-2-git-send-email-lersek@redhat.comSigned-off-by: Anthony Liguori <aliguori@us.ibm.com>
acpi_table_add(): accept QemuOpts and parse it with OptsVisitor
As one consequence, strtok() -- which modifies its argument -- is replacedwith g_strsplit().
Signed-off-by: Laszlo Ersek <lersek@redhat.com>Reviewed-by: Anthony Liguori <aliguori@us.ibm.com>...
qemu-char: Call fe_claim / fe_release when not using qdev chr properties
chardev-frontends need to explictly check, increase and decrement theavail_connections "property" of the chardev when they are not using aqdev-chardev-property for the chardev.
This fixes things like:...
append the terminating '\0' to bootorder string
Problem was introduced in commit c8a6ae8b. The last terminating'\0' was lost, use the right length 5 ("HALT\0").
Reported-by: Gerd Hoffmann <kraxel@redhat.com>Signed-off-by: Amos Kong <akong@redhat.com>Message-id: 1363774594-21001-1-git-send-email-akong@redhat.com...
Merge remote-tracking branch 'stefanha/block' into staging
vl: add runstate_set tracepoint
This patch enables us to know RunState transition. It will be userfulfor investigation when the trouble occured in special event such likelive migration, shutdown, suspend, and so on.
Signed-off-by: Kazuya Saito <saito.kazuya@jp.fujitsu.com>...
vl.c: call bdrv_init_with_whitelist() before cmdline parsing
commit 4d454574 "qemu-option: move standard option definitionsout of qemu-config.c" broke support for commandline optiongroups that where registered during bdrv_init(). In particularsupport for -iscsi options was broken since that commit....
New QMP command query-cpu-max and HMP command cpu_max
These commands return the maximum number of CPUs supported by thecurrently running emulator instance, as defined in its QEMUMachinestruct.
Signed-off-by: Michal Novotny <minovotn@redhat.com>Signed-off-by: Luiz Capitulino <lcapitulino@redhat.com>
add a boot option to do strict boot
Seabios already added a new device type to halt booting.Qemu can add "HALT" at the end of bootindex string, thenseabios will halt booting after trying to boot from allselected devices.
This patch added a new boot option to configure if boot...
console: fix displaychangelisteners interface
Split callbacks into separate Ops struct. Pass DisplayChangeListenerpointer as first argument to all callbacks. Uninline a bunch ofdisplay functions and move them from console.h to console.c
Add search path support for qemu data files.
This patch allows to specify multiple directories where qemu should lookfor data files. To implement that the behavior of the -L switch isslightly different now: Instead of replacing the data directory the...
Add support for cancelling of a TPM command
This patch adds support for cancelling an executing TPM command.In Linux for example a user can cancel a command through the TPM'ssysfs 'cancel' entry using
echo "1" > /sysfs/class/misc/tpm0/device/cancel
This patch propagates the cancellation of a command inside a VM...
Support for TPM command line options
This patch adds support for TPM command line options.The command line options supported here are
./qemu-... -tpmdev passthrough,path=<path to TPM device>,id=<id> -device tpm-tis,tpmdev=<id>,id=<other id>...
qemu-char: move baum registration to baum.c
Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>Signed-off-by: Amit Shah <amit.shah@redhat.com>Message-id: 1b24baa1ec3a174d5cad31e079d829904b53077b.1362505276.git.amit.shah@redhat.comSigned-off-by: Anthony Liguori <aliguori@us.ibm.com>
hw: move qdev-monitor.o to toplevel directory
qdev-monitor.c is the only "core qdev" file that is not used inuser-mode emulation, and it does not define anything that is usedby hardware models. Remove it from the hw/ directory andremove hw/qdev-monitor.h from hw/qdev.h too; this requires...
hw: move char backends to backends/
Braille and msmouse support is in hw/, but it is not hardware.Move it to the backends/ directory.
vl.c: allow for repeated -sd arguments
Allows for repeating of -sd arguments in the same way as -pflash and -mtdblock.
Acked-by: Igor Mitsyanko <i.mitsyanko@samsung.com>Reviewed-by: Peter Maydell <peter.maydell@linaro.org>Signed-off-by: Peter Crosthwaite <peter.crosthwaite@xilinx.com>...
gtk ui: unbreak spice
Merge of the gtk ui brought a initialitation order issue for spice:The using_spice variable isn't set yet when checked, leading to thedefault UI being activated (additionally to spice remote access).
Let's set display_remote when we find a -spice switch on the command...
gtk: make default UI (v5)
A user can still enable SDL with '-sdl' or '-display sdl' but start making thedefault display GTK by default.
I'd also like to deprecate the SDL display and remove it in a few releases.
Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>...
usb-host: remove usb_host_device_close
Nobody implements that anyway.
cpus.c: Drop unnecessary set_cpu_log()
The set_cpu_log() function in cpus.c is a fairly simple wrapperwhich is only called from one location. Just inline the codeinto vl.c, since there is no need to indirect it via cpus.cand the handling of the error case is more appropriate to vl.c....
qemu-log: Unify {cpu_set,set_cpu}_log_filename as qemu_set_log_filename
The qemu_log() functionality is no longer specific to TCG CPU debug logs.Rename cpu_set_log_filename() to qemu_set_log_filename() and drop thepointless wrapper set_cpu_log_filename()....
vl: Drop redundant "parse error" reports
qemu_opts_parse() reports the error already, and in a much more usefulway.
Signed-off-by: Markus Armbruster <armbru@redhat.com>Message-id: 1360354939-10994-6-git-send-email-armbru@redhat.comSigned-off-by: Anthony Liguori <aliguori@us.ibm.com>
vl: Exit unsuccessfully on option argument syntax error
We exit successfully after reporting syntax error for argument of--sandbox and --add-fd.
We continue undaunted after reporting it for argument of -boot,--option-rom and --object.
Change all five to exit unsuccessfully, like the other options....
vl.c: validate -numa "cpus" parameter properly
- Accept empty strings without aborting- Use parse_uint*() to parse numbers- Abort if anything except '-' or end-of-string is found after the first number.- Check for endvalue < value
Also change the MAX_CPUMASK_BITS warning message from "A max of %d CPUs...
vl.c: Use parse_uint_full() for NUMA nodeid
This should catch many kinds of errors that the current code wasn'tchecking for:
- Values that can't be parsed as a number - Negative values - Overflow - Empty string
Signed-off-by: Eduardo Habkost <ehabkost@redhat.com>...
vl.c: Extract -numa "cpus" parsing to separate function
This will make it easier to refactor that code later.
Signed-off-by: Eduardo Habkost <ehabkost@redhat.com>Reviewed-by: Eric Blake <eblake@redhat.com>Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
vl.c: Fix off-by-one bug when handling "-numa node" argument
The numa_add() code was unconditionally adding 1 to the get_opt_name()return value, making it point after the end of the string if no ','separator is present.
Example of weird behavior caused by the bug:...
vl.c: Abort on unknown -numa option type
Abort in case an invalid -numa option is provided, instead of silentlyignoring it.
vl.c: Check for NUMA node limit inside numa_add()
Instead of checking the limit before calling numa_add(), check the limitonly when we already know we're going to add a new node.
Signed-off-by: Eduardo Habkost <ehabkost@redhat.com>Reviewed-by: Eric Blake <eblake@redhat.com>...
vl.c: numa_add(): Validate nodeid before using it
Without this check, QEMU will corrupt memory if a too-large nodeid isprovided in the command-line. e.g.:
-numa node,mem=...,cpus=...,nodeid=65
This changes nodenr to unsigned long long, to avoid integer conversion...
qdev: drop extra references at creation time
qdev_free and qbus_free have to do unparent+unref, because nobody elsedrops the initial reference (the one included by object_initialize)before them.
For device_init_func and do_device_add, this is trivially correct,...
accel: change {xen, kvm, tcg, qtest}_allowed from int to bool
Signed-off-by: liguang <lig.fnst@cn.fujitsu.com>Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
vl: skip init accelerator if it's not available
vl: correct error message when fail to init kvm
command:qemu-system-x86_64 -hda disk.img -smp 32 --enable-kvmerror:Number of SMP cpus requested (32) exceeds max cpus supported by KVM (16)failed to initialize KVM: Invalid argumentNo accelerator found!...
sclpconsole: Don't instantiate sclpconsole with -nodefaults
libvirt specifies nodefaults and creates an sclp console with specialparameters. Let qemu follow nodefaults and don't create an sclpconsole if nodefaults is specified.
Signed-off-by: Christian Borntraeger <borntraeger@de.ibm.com>...
s390: Add default support for SCLP console
The current s390 machine uses the virtio console as default console,but this doesn't mean that we always want to keep it that way for newmachines.
This patch introduces a way for a machine type to specify that it wants...
fw_cfg: Splash image loader can overrun a stack variable, fix
read_splashfile() passes the address of an int variable as size_t *parameter to g_file_get_contents(), with a cast to gag the compiler.
No problem on machines where sizeof(size_t) == sizeof(int)....
vl: Use size_t for sizes in get_boot_devices_list()
Code mixes uint32_t, int and size_t. Very unlikely to go wrong inpractice, but clean it up anyway.
Signed-off-by: Markus Armbruster <armbru@redhat.com>Signed-off-by: Blue Swirl <blauwirbel@gmail.com>
HMP: add QDict to info callback handler
This patch change all info call back function to takeadditional QDict * parameter, which allow those commandtake parameter. Now it is set to NULL at default case.
Signed-off-by: Wenchao Xia <xiawenc@linux.vnet.ibm.com>...
chardev: add error reporting for qemu_chr_new_from_opts
Make default boot order machine specific
This patch makes default boot order machine specific instead ofset globally. The default boot order can be set per machine inQEMUMachine boot_order. This also allows a machine to receive aNULL boot order when -boot isn't used and take an appropriate action...
qemu-option: move standard option definitions out of qemu-config.c
Merge remote-tracking branch 'stefanha/trivial-patches' into staging
Replace remaining gmtime, localtime by gmtime_r, localtime_r
This allows removing of MinGW specific code and improvesreentrancy for POSIX hosts.
[Removed unused ret variable in qemu_get_timedate() to fix warning:vl.c: In function ‘qemu_get_timedate’:vl.c:451:16: error: variable ‘ret’ set but not used [-Werror=unused-but-set-variable]...
net: clean up network at qemu process termination
We don't clean up network if fails to parse "-device" parameters withoutcalling net_cleanup(). I touch a problem, the tap device which iscreated by qemu-ifup script could not be removed by qemu-ifdown script....
disallow -daemonize usage of stdio (curses display, -nographic, -serial stdio etc)
Curses display requires stdin/out to stay on the terminal,so -daemonize makes no sense in this case. Instead ofleaving display uninitialized like is done since 995ee2bf469de6bb,...
softmmu: move remaining include files to include/ subdirectories
softmmu: move include files to include/sysemu/
misc: move include files to include/qemu/
monitor: move include files to include/monitor/
migration: move include files to include/migration/
qapi: move include files to include/qobject/
exec: move include files to include/exec/
ui: move files to ui/ and include/ui/
net: reorganize headers
Move public headers to include/net, and leave private headers in net/.Put the virtio headers in include/net/tap.h, removing the multiple copiesthat existed. Leave include/net/tap.h as the interface for NICs, andnet/tap_int.h as the interface for OS-specific parts of the tap backend....
build: kill libdis, move disassemblers to disas/
use qemu_opts_create_nofail
We will use qemu_opts_create_nofail function, it can make codemore readable.
Signed-off-by: Dong Xu Wang <wdongxu@linux.vnet.ibm.com>Signed-off-by: Kevin Wolf <kwolf@redhat.com>
Support default block interfaces per QEMUMachine
There are QEMUMachines that have neither IF_IDE nor IF_SCSI as adefault/standard interface to their block devices / drives. Therefore,this patch introduces a new field default_block_type per QEMUMachinestruct. The prior use_scsi field becomes thereby obsolete and is...
block: simplify default_drive
Markus Armbruster pointed out that there is only one callerto default_drive with IF_DEFAULT as a type. Lets get ridof the block_default_type parameter and adopt the callerto do the right thing (asking the machine struct)....
vl.c: Fix broken -usb option
Commit 094b287f0b accidentally broke the "-usb" command lineoption, so it would have no effect if the user had not specifiedany machine options at that point. (the return value from'qemu_opts_find(qemu_find_opts("machine"), 0);' is NULL if there...
vl: add -object option to create QOM objects from the command line
This will create a new QOM object in the '/objects' path. Note that propertiesare set in order which allows for simple objects to be initialized entirelywith this option and then realized....
Merge branch 'trivial-patches' of git://github.com/stefanha/qemu
vl: delay thread initialization after daemonization
Commit ac4119c (chardev: Use timer instead of bottom-half to postponeopen event, 2012-10-12) moved the alarm timer initialization to an earlierpoint but failed to consider that it depends on qemu_init_main_loop....
vl: unify calls to init_timer_alarm
init_timer_alarm was being called twice. This is not needed.
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
vl.c: add missing static
Add missing 'static' qualifiers.
Signed-off-by: Blue Swirl <blauwirbel@gmail.com>Signed-off-by: Stefan Hajnoczi <stefanha@redhat.com>
Merge remote-tracking branch 'kraxel/pixman.v3' into staging
Merge remote-tracking branch 'bonzini/threadpool' into staging
Merge remote-tracking branch 'qemu-kvm/uq/master' into staging
console: untangle gfx & txt updates
Stop abusing displaysurface fields for text mode displays.(bpp = 0, width = cols, height = lines).
Add flags to displaystate indicating whenever text mode display(curses) or gfx mode displays (sdl, vnc, ...) are present....
console: init displaychangelisteners on register
console: QLIST-ify display change listeners.
console: add unregister_displaychangelistener
Also change the way the gui_timer is initialized: each time adisplaychangelistener is registered or unregistered we'll checkwhether we need a timer (due to dpy_refresh callback being present)and if so setup a timer, otherwise zap it. This way the gui timer...
chardev: Use timer instead of bottom-half to postpone open event
As the block layer may decide to flush bottom-halfs while the machine isstill initializing (e.g. to read geometry data from the disk), ourpostponed open event may be processed before the last frontend...
Merge remote-tracking branch 'origin/master' into threadpool
Emulate qemu-kvms -no-kvm option
Releases of qemu-kvm will be interrupted at qemu 1.3.0.Users should switch to plain qemu releases.To avoid breaking scenarios which are setup with command lineoptions specific to qemu-kvm, port these switches from qemu-kvm...
Issue warning when deprecated -tdf option is used
Use global properties to emulate -no-kvm-pit-reinjection
Issue warning when deprecated -no-kvm-pit is used