Age | Commit message (Collapse) | Author | Files | Lines |
|
* upstream: (43 commits)
Initialize a variable in all cases
Fix uint8_t comparison with negative value
Fix a warning on OpenSolaris
Correctly identify multiple cpus in SMP systems
Remove unused constant
jazz led: Fix debug prints
xilinx-s3adsp: Add support for loading u-boot images.
xilinx-s3adsp: Fix loading of raw binaries.
Remove unused eventfd.h
migration: Accept 'cont' only after successful incoming migration
mips64el: fulong: PCI_DEVFN() clean up.
remove pointless if from vl.c
fix variable type in qemu-io.c
remove dead code from hw/loader.c
savevm: Fix memory leak of compat struct
virtio-serial: Check if more max_ports specified than we can handle
linux-user: fix build on hosts not using guest base
linux-user: Protect against allocation failure in load_symbols.
cris: Correct settls1 testcase.
cris: Correct ADDO and ADDOQ testcases.
...
Signed-off-by: Avi Kivity <avi@redhat.com>
|
|
* commit 'fd2f659ee3f6f991f4f194f3fde5c9f957fd663d': (58 commits)
Update version for 0.13.0-rc0
vnc: better default values for VNC options
vnc: tight: split send_sub_rect
vnc: tight: fix rgb_prepare_row
vnc: add missing lock for vnc_cursor_define()
vnc: threaded VNC server
qemu-thread: add qemu_mutex/cond_destroy and qemu_mutex_exit
vnc: fix tight png memory leak
vnc: encapsulate encoding members
vnc: tight: stop using qdict for palette stuff
vnc: tight: specific zlib level and filters for each compression level
vnc: tight add PNG encoding
vnc: tight: remove a memleak in send_jpeg_rect()
vnc: tight: don't forget do at the last color
vnc: rename vnc-encoding-* vnc-enc-*
ui: move all ui components in ui/
vnc: add lossy option
vnc: JPEG should be disabled if the client don't set tight quality
vnc: tight: add JPEG and gradient subencoding with smooth image detection
Initial documentation for migration
...
Merge 0.13 branch point.
Signed-off-by: Avi Kivity <avi@redhat.com>
|
|
Add a macro to easily enable/disable debug prints
Also fix wrong printf formatters
Signed-off-by: Hervé Poussineau <hpoussin@reactos.org>
Signed-off-by: Aurelien Jarno <aurelien@aurel32.net>
|
|
Signed-off-by: Edgar E. Iglesias <edgar.iglesias@gmail.com>
|
|
Set high to a word aligned address beyond loaded image.
Signed-off-by: Edgar E. Iglesias <edgar.iglesias@gmail.com>
|
|
This header is not present on my system and causes a build
failure, but is also not used in these files, so remove it.
Signed-off-by: Mike McCormack <mikem@ring3k.org>
Signed-off-by: Aurelien Jarno <aurelien@aurel32.net>
|
|
Use PCI_DEVFN() where appropriate.
The resulted stripped binary remains same
with/without thie patch.
Cc: Huacai Chen <zltjiangshi@gmail.com>
Cc: Aurelien Jarno <aurelien@aurel32.net>
Signed-off-by: Isaku Yamahata <yamahata@valinux.co.jp>
Signed-off-by: Aurelien Jarno <aurelien@aurel32.net>
|
|
Removing dead code. Above we already continued when
rom->addr + valuegreaterthan0 < addr so this condition is always false.
Signed-off-by: Joel Schopp <jschopp@austin.ibm.com>
Signed-off-by: Aurelien Jarno <aurelien@aurel32.net>
|
|
Currently virtio-serial supports a maximum of 31 ports. Specifying the
'max_ports' parameter to be > 31 on the cmd line causes badness.
Ensure we initialise virtio-serial only if max_ports is within the
supported range.
Signed-off-by: Amit Shah <amit.shah@redhat.com>
Signed-off-by: Aurelien Jarno <aurelien@aurel32.net>
|
|
* 'for-anthony' of git://repo.or.cz/qemu/kevin:
Fix -snapshot deleting images on disk change
block: Use error codes from lower levels for error message
block: default to 0 minimal / optiomal I/O size
move 'unsafe' to end of caching modes in help
virtio-blk: Create exit function to unregister savevm
block migration: propagate return value when bdrv_write() returns < 0
ide/atapi: add support for GET EVENT STATUS NOTIFICATION
|
|
When supported by the host kernel, we can use read/write on the
PCI sysfs resource file for I/O port regions. This allows us to
avoid raw in/out commands and works with deprivileged guests via
libvirt.
Signed-off-by: Alex Williamson <alex.williamson@redhat.com>
Acked-by: Chris Wright <chrisw@redhat.com>
Signed-off-by: Marcelo Tosatti <mtosatti@redhat.com>
|
|
Fix the following warnings:
/src/qemu/hw/ide/core.c: In function `ide_drive_pio_post_load':
/src/qemu/hw/ide/core.c:2767: warning: comparison is always false due to limited range of data type
/src/qemu/ui/vnc-enc-tight.c: In function `tight_detect_smooth_image':
/src/qemu/ui/vnc-enc-tight.c:284: warning: comparison is always true due to limited range of data type
/src/qemu/ui/vnc-enc-tight.c:297: warning: comparison is always true due to limited range of data type
/src/qemu/ui/vnc-enc-tight.c: In function `tight_encode_indexed_rect16':
/src/qemu/ui/vnc-enc-tight.c:456: warning: comparison is always false due to limited range of data type
/src/qemu/ui/vnc-enc-tight.c: In function `tight_encode_indexed_rect32':
/src/qemu/ui/vnc-enc-tight.c:457: warning: comparison is always false due to limited range of data type
Signed-off-by: Blue Swirl <blauwirbel@gmail.com>
|
|
It reintroduces
Revert "ide save/restore pio/atapi cmd transfer fields and io buffer"
but using subsections. Added bonus is the addition of ide_dummy_transfer_stop
to transfer_end_table, that was missing.
Signed-off-by: Juan Quintela <quintela@redhat.com>
Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
|
|
Signed-off-by: Juan Quintela <quintela@redhat.com>
Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
|
|
This commit adds subsections for each device section.
Subsections is the way to handle information that don't need to be sent
to de destination of a migration because its values are not needed. It is
the way to handle optional information. Notice that only the source can
decide if the information is optional or not. The destination needs to
understand all subsections that it receives to have a sucessful load.
Signed-off-by: Juan Quintela <quintela@redhat.com>
Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
|
|
This reverts commit 42ee76fe82093ba914f0dc83d2decbcf68866144.
Signed-off-by: Juan Quintela <quintela@redhat.com>
Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
|
|
This reverts commit ed487bb1d69040b9dac64a4fc076d8dd82b131d6.
The conflicts are due to commit 4fc8d6711aff7a9c11e402c3d77b481609f9f486
that is a fix to the ide_drive_pre_save() function. It reverts both
(and both are reinstantiated later in the series)
Conflicts:
hw/ide/core.c
Signed-off-by: Juan Quintela <quintela@redhat.com>
Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
|
|
|
|
Otherwise we can't migrate after we've removed a virtio block device.
Signed-off-by: Alex Williamson <alex.williamson@redhat.com>
Signed-off-by: Kevin Wolf <kwolf@redhat.com>
|
|
The GET EVENT STATUS NOTIFICATION is a mandatory command according
to MMC-3, even if event status notification is not supported.
This patch adds support for this command. It returns NEA ("No Event
Available") with an empty "Supported Event Classes" to show that it
doesn't event support status notification. If asychronous operation is
requested, which requires NCQ support, it returns an error according
to the specifications.
This fixes HAL support on FreeBSD and derivatives, which fill up the
logs every second with:
acd0: FAILURE - unknown CMD (0x03) ILLEGAL REQUEST asc=0x20 ascq=0x00
Signed-off-by: Aurelien Jarno <aurelien@aurel32.net>
Signed-off-by: Kevin Wolf <kwolf@redhat.com>
|
|
Some SW drivers dont keep track of what they've written and
depend on the HW latching write contents for later
read+modify+write sequences.
Signed-off-by: Edgar E. Iglesias <edgar@axis.com>
|
|
Commit 36388314febad3d7675ab919287f03733a560ff6 moved most of the
interrupt logic to cpu-exec.c. Remove the remaining useless code
and fix software interrupts.
Signed-off-by: Aurelien Jarno <aurelien@aurel32.net>
Acked-by: Edgar E. Iglesias <edgar@axis.com>
Tested-by: Edgar E. Iglesias <edgar@axis.com>
|
|
When hw interrupt pending bits in CP0_Cause are set, the CPU should
see the hw interrupt line as active. The CPU may or may not take the
interrupt based on internal state (global irq mask etc) but the glue
logic shouldn't care.
This fixes MIPS external hw interrupts in combination with -icount.
Signed-off-by: Edgar E. Iglesias <edgar@axis.com>
|
|
* commit '9a62fb241c10327992a16bf99a131f98e70428a1':
Sparc32: reserve addresses for unimplemented devices on SS-20
target-ppc: fix power mode checking on 7400/7410
target-mips: fix xtlb exception for loongson
microblaze: Correct signal frame setup.
Make default invocation of block drivers safer (v3)
hw/bonito: remove incorrect pci_mem_base setting
ide scsi virtio-blk: Reject empty drives unless media is removable
virtio-blk: Fix virtio-blk-s390 to require drive
virtio-pci: Check for virtio_blk_init() failure
Block migration fail, ignore error from bdrv_getlength
qemu-img: Fix copy+paste bug in documentation
virtio-serial: Assert for virtio queue ready before virtqueue operations
virtio-serial: Check if virtio queue is ready before consuming data
virtio-9p: Avoid SEGV when log file couldn't be opened
pc: Avoid registering zero sized memory
Signed-off-by: Avi Kivity <avi@redhat.com>
|
|
The request completion callback of the LSI controller may start the next
request that can use the same tag as the completed one. As the latter is
still enqueued at that point, scsi_send_command will complain about the
tag reuse and cancel the completed request. That will cause a double
free later on when the completion path cleans up as well.
Fix this by dequeuing the request before invoking the callback.
Signed-off-by: Jan Kiszka <jan.kiszka@siemens.com>
Signed-off-by: Aurelien Jarno <aurelien@aurel32.net>
|
|
This change fixes initialization of e1000's microwire EEPROM internal
state values so that qemu's e1000 emulation works on NetBSD,
which doesn't use Intel's em driver but has its own wm driver
for the Intel i8254x Gigabit Ethernet.
Previously set_eecd() function in e1000.c clears EEPROM internal state
values on SK rising edge during CS==L, but according to FM93C06 EEPROM
(which is MicroWire compatible) data sheet, EEPROM internal status
should be cleared on CS rise edge regardless of SK input:
"... a rising edge on this (CS) signal is required to reset the internal
state-machine to accept a new cycle .."
and nothing should be changed during CS (chip select) is inactive.
Intel's em driver seems to explicitly raise SK output after CS is negated
in em_standby_eeprom() so many other OSes that use Intel's driver
don't have this problem even on the previous e1000.c implementation,
but I can't find any articles that say the MICROWIRE or EEPROM spec
requires such sequence, and actually hardware works fine without it
(i.e. real i82540EM has been working on NetBSD).
This fix also changes initialization to clear each state value in
struct eecd_state individually rather than using memset() against
the whole structre. The old_eecd member stores the last SK and CS
signal levels and it should be preserved even after reset of internal
EEPROM state to detect next signal edges for proper EEPROM emulation.
Signed-off-by: Izumi Tsutsui <tsutsui@ceres.dti.ne.jp>
Signed-off-by: Aurelien Jarno <aurelien@aurel32.net>
|
|
Starting with qemu -M pc-0.12 -device virtio-serial
results in
-device virtio-serial: Property 'virtio-serial-pci.max_nr_ports' not found
The property name 'max_ports' is incorrectly named 'max_nr_ports'. Fix
that.
Also fix the ppc440 machine type bamboo-0.12 which has this typo.
Reported-by: Daniel P. Berrange <berrange@redhat.com>
Signed-off-by: Amit Shah <amit.shah@redhat.com>
Signed-off-by: Aurelien Jarno <aurelien@aurel32.net>
|
|
Use empty_slot to reserve addresses for several unimplemented devices so they won't fault.
- BPP (parallel port), DBRI (audio), SX (pixel processor), and vsimms (framebuffer)
OBP for SS-20 either assumes these devices exist or probes without expecting faults.
Signed-off-by: Bob Breuer <breuerr@mc.net>
Signed-off-by: Blue Swirl <blauwirbel@gmail.com>
|
|
We need to know ring layout to allocate log buffer.
So init rings first.
Also fixes a theoretical memory-leak-on-error.
https://bugzilla.redhat.com/show_bug.cgi?id=615228
Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
Tested-by: Gerd Hoffmann <kraxel@redhat.com>
|
|
Add support for secrc field. Reportedly needed by old RHEL guests.
Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
|
|
We do range check for size, and get size as buffer,
but copy size + 4 bytes (4 is for FCS).
Let's copy size bytes but put size + 4 in length.
Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
|
|
|
|
|
|
This mistake makes PCI devices can't work correctly.
Signed-off-by: Huacai Chen <zltjiangshi@gmail.com>
Signed-off-by: Aurelien Jarno <aurelien@aurel32.net>
|
|
* commit 'b7fdb3ab0e22a9a8debcb928497b248f06778845': (23 commits)
qemu-options: add documentation for stdio signal=on|off
Update OpenBIOS images
target-ppc: add vexptefp instruction
softfloat: add float32_exp2()
Update SeaBIOS
pci/multi function bit: fix vt82c686.c.
target-sh4: Add support for ldc & stc with sgr
target-sh4: Split the LDST macro into 2 sub-macros
pci: fix bridge update
virtio-net: correct packet length math
pci hotplug: make pci hotplug return value to caller
vmware_vga: fix reset value for command register
rtl8139: address TODOs
pci hotplug: make pci_device_hot_remove() static
pcnet: address TODOs
pci: fix pci_device_reset
AppleSMC device emulation
Documentation: Fix spelling bugs
Makefile: Not every shell support {}
Makefile: add fsdev/*.{o,d} to clean
...
Signed-off-by: Marcelo Tosatti <mtosatti@redhat.com>
|
|
* commit '498238687fd3a2bf3efb32694732f88ceac72e99': (28 commits)
pci: introduce multifunction property.
qdev: implement qdev_prop_set_bit().
pci: remove PCIDeviceInfo::header_type
pci: don't overwrite multi functio bit in pci header type.
pci: insert assert that auto-assigned-address function is single function device.
pci: use PCI_DEVFN() where appropriate.
target-mips: add loongson 2E & 2F integer instructions
Fix warning about uninitialized variable
sheepdog: fix compile error on systems without TCP_CORK
ramblocks: No more being lazy about duplicate names
pci: Free the space allocated for the option rom on removal
block: add sheepdog driver for distributed storage support
ide: Reject invalid CHS geometry
ide: Reject readonly drives unless CD-ROM
ide: Make ide_init_drive() return success
ide: Replace IDEState members is_cdrom, is_cf by drive_kind
ide: Improve error messages
scsi: Error locations for -drive if=scsi device initialization
error: New qemu_opts_loc_restore()
scsi: Reject unimplemented error actions
...
Conflicts:
hw/pci.c
Signed-off-by: Marcelo Tosatti <mtosatti@redhat.com>
|
|
* commit '04b16653720cb3db353461e088612f8a24ff360b':
qemu_ram_free: Implement it
savevm: Create a new continue flag to avoid resending block name
savevm: Use RAM blocks for basis of migration
savevm: Migrate RAM based on name/offset
Signed-off-by: Marcelo Tosatti <mtosatti@redhat.com>
|
|
* commit '1724f04985367b15751f11f4a9558f8736b2ab59':
qemu_ram_alloc: Add DeviceState and name parameters
virtio-net: Incorporate a DeviceState pointer and let savevm track instances
eepro100: Add a dev field to eeprom new/free functions
savevm: Make use of DeviceState
Conflicts:
cpu-common.h
exec.c
Signed-off-by: Marcelo Tosatti <mtosatti@redhat.com>
|
|
* commit '0be71e324f774a77243f1a1487f468232d69542b':
savevm: Add DeviceState param
pci: Implement BusInfo.get_dev_path()
qdev: Add a get_dev_path() function to BusInfo
pc: Allocate all ram in a single qemu_ram_alloc()
Signed-off-by: Marcelo Tosatti <mtosatti@redhat.com>
|
|
* commit 'd17b5288d91c935cc8795fa0620721da0a3865e1': (54 commits)
Remove uses of ram.last_offset (aka last_ram_offset)
make rtc alatm work
scsi: Fix SCSI bus reset
Fix io-thread build breakage of a88790a14f
Include sys/mman.h before qemu-options.h
cris: Avoid debug clobbering for both I & D MMU state.
cris: Dont clobber the MMU state across calls to cpu_get_phys_page_debug.
cris: Break out rand LFSR update into a separate func.
block: Handle multiwrite errors only when all requests have completed
block: Fix early failure in multiwrite
qemu-img: avoid calling exit(1) to release resources properly
pc: Fix CMOS info for drives defined with -device
ide: Make PIIX and ISA IDE init functions return the qdev
block: Fix virtual media change for if=none
block: Clean up bdrv_snapshots()
savevm: Survive hot-unplug of snapshot device
blkdebug: Initialize state as 1
blkdebug: Free QemuOpts after having read the config
blkdebug: Fix set_state_opts definition
qemu-option: New qemu_opts_reset()
...
Conflicts:
exec.c
Signed-off-by: Marcelo Tosatti <mtosatti@redhat.com>
|
|
Disks without media make no sense. For SCSI, a Linux guest kernel
complains during boot. I didn't try other combinations.
scsi-generic doesn't need the additional check, because it already
requires bdrv_is_sg(), which fails without media.
Signed-off-by: Markus Armbruster <armbru@redhat.com>
Signed-off-by: Kevin Wolf <kwolf@redhat.com>
|
|
Move the check from virtio_blk_init_pci(), where it protects only
virtio-blk-pci, to virtio_blk_init(). Without that, virtio-blk-s390
initializes without a drive. I figure that can lead to null pointer
dereferences.
Signed-off-by: Markus Armbruster <armbru@redhat.com>
Signed-off-by: Kevin Wolf <kwolf@redhat.com>
|
|
It can't actually fail now, but the next commit will change that.
s390_virtio_blk_init() already checks for failure, but
virtio_blk_init_pci() doesn't. Fix that.
Signed-off-by: Markus Armbruster <armbru@redhat.com>
Signed-off-by: Kevin Wolf <kwolf@redhat.com>
|
|
In addition to the previous fix for calling do_flush_queued_data() only
when the virtqueue is ready, ensure do_flush_queued_data() gets a vq
that's suitably initialised.
Signed-off-by: Amit Shah <amit.shah@redhat.com>
Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
|
|
If a virtio-serial port is removed before the guest comes up and
initialises the virtqueues, qemu exits with the message
Guest moved used index from 0 to 61440
This happens because we try to clear any pending buffers from the
virtqueue.
Ensure the virtqueue is initialised before calling any virtqueue
operations.
Signed-off-by: Amit Shah <amit.shah@redhat.com>
Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
|
|
While running in debug mode if 9P server is unable to open the log file
it results in a SEGV deep down in glibc:
Program received signal SIGSEGV, Segmentation fault.
0x008fca8c in fwrite () from /lib/libc.so.6
(gdb) bt
#0 0x008fca8c in fwrite () from /lib/libc.so.6
#1 0x081eb87e in pprint_pdu (pdu=0x89a52e1c)
at /data/sripathi/code/qemu/new/qemu-next-upstream/hw/virtio-9p-debug.c:380
#2 0x0806dad8 in submit_pdu (s=0x897dc008, pdu=0x89a52e1c)
at /data/sripathi/code/qemu/new/qemu-next-upstream/hw/virtio-9p.c:3092
#3 0x0806dc63 in handle_9p_output (vdev=0x897dc008, vq=0x86d8218)
at /data/sripathi/code/qemu/new/qemu-next-upstream/hw/virtio-9p.c:3122
#4 0x081ac728 in virtio_queue_notify (vdev=0x897dc008, n=0)
at /data/sripathi/code/qemu/new/qemu-next-upstream/hw/virtio.c:563
#5 0x08063876 in virtio_ioport_write (opaque=0x86d7b98, addr=16, val=0)
at /data/sripathi/code/qemu/new/qemu-next-upstream/hw/virtio-pci.c:222
#6 0x08063e26 in virtio_pci_config_writew (opaque=0x86d7b98, addr=16, val=0)
at /data/sripathi/code/qemu/new/qemu-next-upstream/hw/virtio-pci.c:357
#7 0x080c881a in ioport_write (index=1, address=49296, data=0) at ioport.c:80
#8 0x080c8d4c in cpu_outw (addr=49296, val=0) at ioport.c:204
#9 0x08073010 in kvm_handle_io (port=49296, data=0xab393000, direction=1, size=2, count=1)
at /data/sripathi/code/qemu/new/qemu-next-upstream/kvm-all.c:735
...
...
This is ugly and misleading. The following patch adds a BUG_ON to catch this
error. With this patch we get an abort message like the following, which makes
it easier to analyze:
f12-kvm login: qemu: /data/sripathi/code/qemu/new/qemu-next-upstream/hw/virtio-9p-debug.c:353: pprint_pdu: Assertion `!(!llogfile)' failed.
Signed-off-by: Sripathi Kodi <sripathik@in.ibm.com>
Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
|
|
No need to call cpu_register_physical_memory() for a zero sized area.
Signed-off-by: Alex Williamson <alex.williamson@redhat.com>
Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
|
|
|
|
Commit 909bfdba fixed a hole with not closing resource file descriptors
but we need to be more careful about tracking which are real fds,
otherwise we might close fd 0, which doesn't work out so well for stdio.
Signed-off-by: Alex Williamson <alex.williamson@redhat.com>
Acked-by: Donald Dutile <ddutile@redhat.com>
Signed-off-by: Marcelo Tosatti <mtosatti@redhat.com>
|
|
The file, vt82c686.c, was added after the change set of
b80d4a9887fa4b6cc63f8c3a13ab2a45054d3e5c and
fecb93c45c749a4c994d8d12bdee17ce2012de9e
are created, but before the patch series was commit.
So similar fix is needed to vt82c686.c.
Cc: Huacai Chen <zltjiangshi@gmail.com>
Cc: Aurelien Jarno <aurelien@aurel32.net>
Cc: Michael S. Tsirkin <mst@redhat.com>
Cc: Blue Swirl <blauwirbel@gmail.com>
Signed-off-by: Isaku Yamahata <yamahata@valinux.co.jp>
Signed-off-by: Aurelien Jarno <aurelien@aurel32.net>
|