commit_msg
stringlengths
1
24.2k
commit_hash
stringlengths
2
84
project
stringlengths
2
40
source
stringclasses
4 values
labels
int64
0
1
repo_url
stringlengths
26
70
commit_url
stringlengths
74
118
commit_date
stringlengths
25
25
qemu-char: Inherit ptys and improve output from -serial pty Changes since V1: - Avoid crashing since qemu_opts_id() may return null on some systems according to Markus's suggestion. When controlling a qemu instance from another program, it's hard to know which serial port or monitor device is redirected to which pty. With more than one device using "pty" a lot of guesswork is involved. $ ./x86_64-softmmu/qemu-system-x86_64 -serial pty -serial pty -monitor pty char device redirected to /dev/pts/5 char device redirected to /dev/pts/6 char device redirected to /dev/pts/7 Although we can find out what everything else is connected to by the "info chardev" with "-monitor stdio" in the command line, It'd be very useful to be able to have qemu inherit pseudo-tty file descriptors so they could just be specified on the command line like: $ ./x86_64-softmmu/qemu-system-x86_64 -serial pty -serial pty -monitor pty char device compat_monitor0 redirected to /dev/pts/5 char device serial0 redirected to /dev/pts/6 char device serial1 redirected to /dev/pts/7 Referred link: https://bugs.launchpad.net/qemu/+bug/938552 Signed-off-by: Lei Li <[email protected]> Signed-off-by: Anthony Liguori <[email protected]>
586502189edf9fd0f89a83de96717a2ea826fdb0
qemu
devign
1
https://github.com/qemu/qemu
https://github.com/qemu/qemu/commit/586502189edf9fd0f89a83de96717a2ea826fdb0
2012-12-23 09:11:19-06:00
spice: add new spice-server callbacks to ui/spice-display.c Otherwise qemu crashes with non-qxl graphics cards. Signed-off-by: Gerd Hoffmann <[email protected]>
21a50d0b1a0745e485eff3e5aa393cdc4a1980b6
qemu
devign
1
https://github.com/qemu/qemu
https://github.com/qemu/qemu/commit/21a50d0b1a0745e485eff3e5aa393cdc4a1980b6
2012-11-21 14:46:11+01:00
hw/qxl: guest bug on primary create with stride %4 != 0 Due to usage of pixman for rendering on all spice surfaces we have pixman's requirement that the stride be word aligned. A guest not honoring that can crash spice and qemu with it due to failure to create a surface (in spice-server). Avoid this early on in primary surface creation and offscreen surface creation. Recently windows guests got odd width support which triggers a non word aligned primary surface in 16bit color depth. Off screen surfaces have always been word aligned, but doesn't hurt to check them here too. Signed-off-by: Alon Levy <[email protected]> Signed-off-by: Gerd Hoffmann <[email protected]>
48f4ba671bbb3dd212002d57b72a23375f51619b
qemu
devign
1
https://github.com/qemu/qemu
https://github.com/qemu/qemu/commit/48f4ba671bbb3dd212002d57b72a23375f51619b
2012-11-05 11:49:21+01:00
Issue warning when deprecated drive parameter boot=on|off is used 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 line options specific to qemu-kvm, port these switches from qemu-kvm to qemu.git. Port drive boot option. From the qemu-kvm original commit message: We do not want to maintain this option forever. It will be removed after a grace period of a few releases. So warn the user that this option has no effect and will become invalid soon. Signed-off-by: Marcelo Tosatti <[email protected]>
0d92d17a6d0d65af8cb905bdd5f9e04e210564ff
qemu
devign
1
https://github.com/qemu/qemu
https://github.com/qemu/qemu/commit/0d92d17a6d0d65af8cb905bdd5f9e04e210564ff
2012-10-30 23:39:52-02:00
sheepdog: avoid a few buffer overruns * parse_vdiname: Use pstrcpy, not strncpy, when the destination buffer must be NUL-terminated. * sd_open: Likewise, avoid buffer overrun. * do_sd_create: Likewise. Leave the preceding memset, since pstrcpy does not NUL-fill, and filename needs that. * sd_snapshot_create: Add a comment/question. * find_vdi_name: Remove a useless memset. * sd_snapshot_goto: Remove a useless memset. Use pstrcpy to NUL-terminate, because find_vdi_name requires that its vdi arg (filename parameter) be NUL-terminated. It seems ok not to NUL-fill the buffer. Do the same for snapid: remove useless memset-0 (instead, zero tag[0]). Use pstrcpy, not strncpy. * sd_snapshot_list: Use pstrcpy, not strncpy to write into the ->name member. Each must be NUL-terminated. Acked-by: Kevin Wolf <[email protected]> Acked-by: MORITA Kazutaka <[email protected]> Signed-off-by: Jim Meyering <[email protected]> Signed-off-by: Anthony Liguori <[email protected]>
3178e2755ec5a7fb1afe583fb6ac2622c2c42184
qemu
devign
1
https://github.com/qemu/qemu
https://github.com/qemu/qemu/commit/3178e2755ec5a7fb1afe583fb6ac2622c2c42184
2012-10-05 07:58:36-05:00
hw/arm_gic.c: Fix improper DPRINTF output. s->cpu_enabled is an array, so s->cpu_enabled ? "En" : "Dis" returns "En" always. We should use s->cpu_enabled[cpu] here. Signed-off-by: Evgeny Voevodin <[email protected]> Signed-off-by: Peter Maydell <[email protected]>
9ab1b6053f03d58ba8e7accc8f19c882fbffb66f
qemu
devign
1
https://github.com/qemu/qemu
https://github.com/qemu/qemu/commit/9ab1b6053f03d58ba8e7accc8f19c882fbffb66f
2012-10-12 11:54:37+01:00
qemu-iotests: add test for pausing a streaming operation These check that a paused streaming job does not advance its offset. Sometimes the new test fails; the map is different between the source and the destination of the streaming because qemu-io does not always pack adjacent clusters that have the same allocated/unallocated state. However, this also happens with the existing test_stream testcase, and is better fixed in qemu-io. Signed-off-by: Paolo Bonzini <[email protected]> Reviewed-by: Eric Blake <[email protected]> Signed-off-by: Kevin Wolf <[email protected]>
0c81734765c9af1705f8e531b9431d63ee8ffd3d
qemu
devign
1
https://github.com/qemu/qemu
https://github.com/qemu/qemu/commit/0c81734765c9af1705f8e531b9431d63ee8ffd3d
2012-09-28 19:14:32+02:00
Fix address handling in inet_nonblocking_connect getaddrinfo can give us a list of addresses, but we only try to connect to the first one. If that fails we never proceed to the next one. This is common on desktop setups that often have ipv6 configured but not actually working. To fix this make inet_connect_nonblocking retry connection with a different address. callers on inet_nonblocking_connect register a callback function that will be called when connect opertion completes, in case of failure the fd will have a negative value Signed-off-by: Orit Wasserman <[email protected]> Signed-off-by: Michael S. Tsirkin <[email protected]> Signed-off-by: Anthony Liguori <[email protected]>
233aa5c2d1cf4655ffe335025a68cf5454f87dad
qemu
devign
1
https://github.com/qemu/qemu
https://github.com/qemu/qemu/commit/233aa5c2d1cf4655ffe335025a68cf5454f87dad
2012-09-25 19:05:56-05:00
ehci: check for EHCI_ASYNC_FINISHED first in ehci_free_packet Otherwise we'll see the packet free twice in the trace log even though it actually happens only once. Signed-off-by: Gerd Hoffmann <[email protected]>
616789cde2a83fad5e634880fd20214f0c984fd5
qemu
devign
1
https://github.com/qemu/qemu
https://github.com/qemu/qemu/commit/616789cde2a83fad5e634880fd20214f0c984fd5
2012-09-11 07:42:59+02:00
ehci: Fix memory leak in handling of NAK-ed packets Currently each time we try to execute a NAK-ed packet we redo ehci_init_transfer, and usb_packet_map, re-allocing (without freeing) the sg list every time. This patch fixes this, it does this by introducing another async state, so that we also properly cleanup a NAK-ed packet on cancel. Signed-off-by: Hans de Goede <[email protected]> Signed-off-by: Gerd Hoffmann <[email protected]>
ef5b234477df80700b128f561f5877a0688a70c8
qemu
devign
1
https://github.com/qemu/qemu
https://github.com/qemu/qemu/commit/ef5b234477df80700b128f561f5877a0688a70c8
2012-09-11 07:42:59+02:00
i8259: add -no-spurious-interrupt-hack option This patch provides a way to optionally suppress spurious interrupts, as a workaround for systems described below: Some old operating systems do not handle spurious interrupts well, and qemu tends to generate them significantly more often than real hardware. Examples: - Microport UNIX System V/386 v 2.1 (ca 1987) (The main problem I'm fixing: Without this patch, it panics sporadically when accessing the hard disk.) - AT&T UNIX System V/386 Release 4.0 Version 2.1a (ca 1991) See screenshot in "QEMU Official OS Support List": http://www.claunia.com/qemu/objectManager.php?sClass=application&iId=9 (I don't have this system to test.) - A report about OS/2 boot lockup from 2004 by Hampa Hug: http://lists.nongnu.org/archive/html/qemu-devel/2004-09/msg00367.html (My patch was partially inspired by his.) Also: http://lists.nongnu.org/archive/html/qemu-devel/2005-06/msg00243.html (I don't have this system to test.) Signed-off-by: Matthew Ogilvie <[email protected]> Signed-off-by: malc <[email protected]>
f278d4947fff814dcde2ef2acad36d172ff8be35
qemu
devign
1
https://github.com/qemu/qemu
https://github.com/qemu/qemu/commit/f278d4947fff814dcde2ef2acad36d172ff8be35
2012-08-24 07:44:39+04:00
Fix invalidate if memory requested was not bucket aligned When memory is mapped in qemu_map_cache with lock != 0 a reverse mapping is created pointing to the virtual address of location requested. The cached mapped entry is saved in last_address_vaddr with the memory location of the base virtual address (without bucket offset). However when this entry is invalidated the virtual address saved in the reverse mapping is used. This cause that the mapping is freed but the last_address_vaddr is not reset. Signed-off-by: Frediano Ziglio <[email protected]> Signed-off-by: Stefano Stabellini <[email protected]>
27b7652ef515bb4c694f79d657d2052c72b19536
qemu
devign
1
https://github.com/qemu/qemu
https://github.com/qemu/qemu/commit/27b7652ef515bb4c694f79d657d2052c72b19536
2012-08-22 10:17:04+00:00
xbzrle: fix compilation on ppc32 When compiling the xbzrle code on my ppc32 user space, I hit the following gcc compiler warning (treated as an error): cc1: warnings being treated as errors savevm.c: In function ‘xbzrle_encode_buffer’: savevm.c:2476: error: overflow in implicit constant conversion Fix this by making the cast explicit, rather than implicit. Signed-off-by: Alexander Graf <[email protected]>
a5b71725c7067f6805eb30ff8e03dce3b6bf7a53
qemu
devign
1
https://github.com/qemu/qemu
https://github.com/qemu/qemu/commit/a5b71725c7067f6805eb30ff8e03dce3b6bf7a53
2012-08-15 19:43:15+02:00
migration: don't rely on any QERR_SOCKET_* Use the in_progress argument for QERR_SOCKET_CONNECT_IN_PROGRESS. The other errors are handled the same by checking if the error is set and then calling migrate_fd_error() if it's. It's also necessary to change inet_connect_opts() not to set QERR_SOCKET_CONNECT_IN_PROGRESS. This error is only used by tcp_start_outgoing_migration() and not changing it along with the usage of in_progress would break migration. Furthermore this commit fixes a bug. Today, there's a spurious error report when migration succeeds: (qemu) migrate tcp:0:4444 migrate: Connection can not be completed immediately (qemu) After this commit no spurious error is reported anymore. Signed-off-by: Luiz Capitulino <[email protected]> Reviewed-by: Markus Armbruster <[email protected]>
540c79fec9e8b6a6582ec4c65aa2c4c5366e4b89
qemu
devign
1
https://github.com/qemu/qemu
https://github.com/qemu/qemu/commit/540c79fec9e8b6a6582ec4c65aa2c4c5366e4b89
2012-08-13 13:20:39-03:00
exec.c: Fix off-by-one error in register_subpage subpage_register() expects "end" to be the last byte in the mapping. Registering a non-page-aligned memory region that extends up to or beyond a page boundary causes subpage_register() to silently fail through the (end >= PAGE_SIZE) check. This bug does not cause noticeable problems for mappings that do not extend to a page boundary, though they do register an extra byte. Signed-off-by: Tyler Hall <[email protected]> Reviewed-by: Peter Maydell <[email protected]> Reviewed-by: Avi Kivity <[email protected]> Signed-off-by: Stefan Hajnoczi <[email protected]>
adb2a9b5d4d5170f0b58b9f92f816048f6b8932b
qemu
devign
1
https://github.com/qemu/qemu
https://github.com/qemu/qemu/commit/adb2a9b5d4d5170f0b58b9f92f816048f6b8932b
2012-08-03 14:25:22+01:00
lsi: use qdev_reset_all By first resetting the devices, lsi_soft_reset will find the queue already cleared so there is no need to do that forcibly (which may also leak SCSIRequests, and/or worse due to dangling references to the lsi_request in the hba_private field). Signed-off-by: Paolo Bonzini <[email protected]>
2f0772c5b4818d4b2078be9dace0036d1030faee
qemu
devign
1
https://github.com/qemu/qemu
https://github.com/qemu/qemu/commit/2f0772c5b4818d4b2078be9dace0036d1030faee
2012-07-26 17:44:08+02:00
qapi: fix error propagation Don't overwrite / leak previously set errors. Make traversal cope with missing mandatory sub-structs. Don't try to end a container that could not be started. v1->v2: - unchanged v2->v3: - instead of examining, assert that we never overwrite errors with error_set() - allow visitors to set a NULL struct pointer successfully, so traversal of incomplete objects can continue - check for a NULL "obj" before accessing "(*obj)->has_XXX" (this is not a typo, "obj != NULL" implies "*obj != NULL" here) - fix start_struct / end_struct balance for unions as well Signed-off-by: Paolo Bonzini <[email protected]> Signed-off-by: Laszlo Ersek <[email protected]> Signed-off-by: Stefan Hajnoczi <[email protected]>
d195325b05199038b5907fa791729425b9720d21
qemu
devign
1
https://github.com/qemu/qemu
https://github.com/qemu/qemu/commit/d195325b05199038b5907fa791729425b9720d21
2012-07-23 11:55:17+01:00
powerpc pci: fixed packing of ranges[] By default mingw-gcc is trying to pack structures the way to preserve binary compatibility with MS Visual C what leads to incorrect and unexpected padding in the PCI bus ranges property of the sPAPR PHB. The patch replaces __attribute__((packed)) with more strict QEMU_PACKED which actually is __attribute__((gcc_struct, packed)) on Windows. Signed-off-by: Alexey Kardashevskiy <[email protected]> Tested-by: Stefan Weil <[email protected]> Reviewed-by: Stefan Weil <[email protected]> Acked-by: Alexander Graf <[email protected]> Signed-off-by: Stefan Hajnoczi <[email protected]>
c4889f54237aec5195d42de2c87292d6e41dd704
qemu
devign
1
https://github.com/qemu/qemu
https://github.com/qemu/qemu/commit/c4889f54237aec5195d42de2c87292d6e41dd704
2012-07-21 10:54:40+01:00
qemu-iotests: add qed.py image manipulation utility The qed.py utility can inspect and manipulate QED image files. It can be used for testing to see the state of image metadata and also to inject corruptions into the image file. It also has a scrubbing feature to copy just the metadata out of an image file, allowing users to share broken image files without revealing data in bug reports. This has lived in my local repo for a long time but could be useful to others. Signed-off-by: Stefan Hajnoczi <[email protected]> Signed-off-by: Kevin Wolf <[email protected]>
e77964f79b905760ce7f0406fc6b988daeabbb65
qemu
devign
1
https://github.com/qemu/qemu
https://github.com/qemu/qemu/commit/e77964f79b905760ce7f0406fc6b988daeabbb65
2012-08-06 22:39:14+02:00
monitor: Fix memory leak with readline completion Each string which is shown during readline completion in the QEMU monitor is allocated dynamically but currently never deallocated. Add the missing loop which calls g_free for the allocated strings. Signed-off-by: Stefan Weil <[email protected]> Reviewed-by: Stefan Hajnoczi <[email protected]> Signed-off-by: Luiz Capitulino <[email protected]>
7618be6230efebab643513eb92fd93c79da36e4d
qemu
devign
1
https://github.com/qemu/qemu
https://github.com/qemu/qemu/commit/7618be6230efebab643513eb92fd93c79da36e4d
2012-06-15 10:41:05-03:00
Revert "rtl8139: do the network/host communication only in normal operating mode" This reverts commit ff71f2e8cacefae99179993204172bc65e4303df. This is because the linux 8139cp driver would leave the card in "Config Register Write Enable" mode after the eeprom were read or write ( which is unexpected in the spec ). Also a physical 8139 card can still DMA into host memory in modes other than Normal mode, so we need revert this commit to align with the behavior of physical card. The issue of 8139cp driver should be fixed in linux seperately. Signed-off-by: Jason Wang <[email protected]> Signed-off-by: Anthony Liguori <[email protected]>
9c92bf7f6c3f675e60b8ba8a5287bb88ea1eac36
qemu
devign
1
https://github.com/qemu/qemu
https://github.com/qemu/qemu/commit/9c92bf7f6c3f675e60b8ba8a5287bb88ea1eac36
2012-06-04 12:58:36+08:00
qapi: fix double free in qmp_output_visitor_cleanup() Stack entries in QmpOutputVisitor are navigation links (weak references), except the bottom (ie. least recently added) entry, which owns the root QObject [1]. Make qmp_output_visitor_cleanup() drop the stack entries, then release the QObject tree by the root. Attempting to serialize an invalid enum inside a dictionary is an example for triggering the double free. [1] http://lists.nongnu.org/archive/html/qemu-devel/2012-03/msg03276.html Signed-off-by: Laszlo Ersek <[email protected]> Signed-off-by: Luiz Capitulino <[email protected]>
f24582d6ad8a080e008974c000bf0ae635d036ac
qemu
devign
1
https://github.com/qemu/qemu
https://github.com/qemu/qemu/commit/f24582d6ad8a080e008974c000bf0ae635d036ac
2012-03-27 09:11:00-03:00
Remove screendump dummy functions. The code in console.c verifies whenever a screen_dump function pointer is present before calling it, so there is no need to supply an dummy function. Remove them. Also report an error to notify the user that he didn't got a screenshot. Signed-off-by: Anthony Liguori <[email protected]>
167351020420c285b67cdf0603501b3d3b15e3f7
qemu
devign
1
https://github.com/qemu/qemu
https://github.com/qemu/qemu/commit/167351020420c285b67cdf0603501b3d3b15e3f7
2012-02-24 13:36:04-06:00
qed: do not evict in-use L2 table cache entries The L2 table cache reduces QED metadata reads that would be required when translating LBAs to offsets into the image file. Since requests execute in parallel it is possible to share an L2 table between multiple requests. There is a potential data corruption issue when an in-use L2 table is evicted from the cache because the following situation occurs: 1. An allocating write performs an update to L2 table "A". 2. Another request needs L2 table "B" and causes table "A" to be evicted. 3. A new read request needs L2 table "A" but it is not cached. As a result the L2 update from #1 can overlap with the L2 fetch from #3. We must avoid doing overlapping I/O requests here since the worst case outcome is that the L2 fetch completes before the L2 update and yields stale data. In that case we would effectively discard the L2 update and lose data clusters! Thanks to Benoît Canet <[email protected]> for extensive testing and debugging which lead to discovery of this bug. Reported-by: Benoît Canet <[email protected]> Signed-off-by: Stefan Hajnoczi <[email protected]> Tested-by: Benoît Canet <[email protected]> Signed-off-by: Kevin Wolf <[email protected]>
14fe292d86da90b79e2fb56a4986d27346339a00
qemu
devign
1
https://github.com/qemu/qemu
https://github.com/qemu/qemu/commit/14fe292d86da90b79e2fb56a4986d27346339a00
2012-03-12 15:14:06+01:00
qemu-iotests: fix pattern for write test The write pattern value 0axb is invalid and evaluates to 0, so the read check (which uses a correct value of 0xab) will fail. This failure will only be detected with a separate patch for qemu-io. Without it, qemu-io cannot interpret hex values and always uses a pattern value of 0. Signed-off-by: Stefan Weil <[email protected]> Signed-off-by: Christoph Hellwig <[email protected]>
c83f64d498756a7e024be3c696380a26b288635c
qemu
devign
1
https://github.com/qemu/qemu
https://github.com/qemu/qemu/commit/c83f64d498756a7e024be3c696380a26b288635c
2012-02-22 16:17:02+01:00
qom: introduce QERR_PROPERTY_VALUE_OUT_OF_RANGE This will be used when reject invalid values for integer fields that are less than 64-bits wide. Reviewed-by: Anthony Liguori <[email protected]> Signed-off-by: Paolo Bonzini <[email protected]> Signed-off-by: Anthony Liguori <[email protected]>
6aced82c4f304c47d7affb8371edda093b11c81a
qemu
devign
1
https://github.com/qemu/qemu
https://github.com/qemu/qemu/commit/6aced82c4f304c47d7affb8371edda093b11c81a
2011-12-19 10:27:34-06:00
net: take ownership of fd in socket init functions Today net/socket.c has no consistent policy for closing the socket file descriptor when initialization fails. This means we leak the file descriptor in some cases or we could also try to close it twice. Make error paths consistent by taking ownership of the file descriptor and closing it on error. Signed-off-by: Stefan Hajnoczi <[email protected]> Signed-off-by: Anthony Liguori <[email protected]>
e5d1fca0f20babbe355957b9ba536fe6187691cc
qemu
devign
1
https://github.com/qemu/qemu
https://github.com/qemu/qemu/commit/e5d1fca0f20babbe355957b9ba536fe6187691cc
2011-12-12 17:06:21-06:00
tcp_close(): check for close() errors too (v2) In case close() fails, we want to report the error back. Changes v1 -> v2: - Use braces on if statement to match coding style Signed-off-by: Eduardo Habkost <[email protected]> Signed-off-by: Anthony Liguori <[email protected]>
61a5872fd66be718ad022102bf813d7e4e9324c5
qemu
devign
1
https://github.com/qemu/qemu
https://github.com/qemu/qemu/commit/61a5872fd66be718ad022102bf813d7e4e9324c5
2011-12-12 11:47:20-06:00
qemu_fclose: return last_error if set (v3) This will make sure no error will be missed as long as callers always check for qemu_fclose() return value. For reference, this is the complete list of qemu_fclose() callers: - exec_close(): already fixed to check for negative values, not -1 - migrate_fd_cleanup(): already fixed to consider only negative values as error, not any non-zero value - exec_accept_incoming_migration(): no return value check (yet) - fd_accept_incoming_migration(): no return value check (yet) - tcp_accept_incoming_migration(): no return value check (yet) - unix_accept_incoming_migration(): no return value check (yet) - do_savevm(): no return value check (yet) - load_vmstate(): no return value check (yet) Changes v1 -> v2: - Add small comment about the need to return previously-spotted errors Changes v2 -> v3: - Add braces to "if" statements to match coding style Signed-off-by: Eduardo Habkost <[email protected]> Signed-off-by: Anthony Liguori <[email protected]>
d82ca915875ac55ba291435f7eb4fe7bfcb2cecb
qemu
devign
1
https://github.com/qemu/qemu
https://github.com/qemu/qemu/commit/d82ca915875ac55ba291435f7eb4fe7bfcb2cecb
2011-12-12 11:47:19-06:00
sheepdog: Avoid deadlock in error path s->lock should be unlocked before leaving add_aio_request. Signed-off-by: Dong Xu Wang <[email protected]> Signed-off-by: Kevin Wolf <[email protected]>
c3fecea50dc0f27198b8658a0c9c4fbfdd0f95db
qemu
devign
1
https://github.com/qemu/qemu
https://github.com/qemu/qemu/commit/c3fecea50dc0f27198b8658a0c9c4fbfdd0f95db
2011-11-22 10:33:43+01:00
vl: Tighten parsing of -m argument strtosz_suffix() fails unless the size is followed by 0, whitespace or ','. Useless here, because we need to fail for any junk following the size, even if it starts with whitespace or ','. Check manually. Things like "-m 1024," are now caught. Signed-off-by: Markus Armbruster <[email protected]> Signed-off-by: Anthony Liguori <[email protected]>
961b42b9dc858936f32effc3f47c76b1c4e7de56
qemu
devign
1
https://github.com/qemu/qemu
https://github.com/qemu/qemu/commit/961b42b9dc858936f32effc3f47c76b1c4e7de56
2011-11-28 16:20:52-06:00
readline: Fix buffer overrun on re-add to history readline_hist_add() moves the history entry to the end of history. It uses memmove() to move rs->history[idx + 1..] to rs->history[idx..]. However, its size argument is off by two array elements, so it writes one element beyond rs->history[], and reads two. On my system, this clobbers rs->hist_entry and the hole right after it. Since the function assigns to rs->hist_entry in time, the bug has no ill effects for me. Spotted by Coverity. Signed-off-by: Markus Armbruster <[email protected]> Signed-off-by: Stefan Hajnoczi <[email protected]>
8af42882a51c632a14d77277df0740f1aa8c958a
qemu
devign
1
https://github.com/qemu/qemu
https://github.com/qemu/qemu/commit/8af42882a51c632a14d77277df0740f1aa8c958a
2011-11-07 08:03:49+00:00
block: Fix vpc initialization of the Dynamic Disk Header The Data Offset field in the Dynamic Disk Header is an 8 byte field. Although the specification (2006-10-11) gives an example of initializing only the first 4 bytes, images generated by Microsoft on Windows initialize all 8 bytes. Failure to initialize all 8 bytes results in errors from utilities like Citrix's vhd-util which checks specifically for the proper Data Offset field initialization. Signed-off-by: Charles Arnold <[email protected]> Reviewed-by: Andreas Färber <[email protected]> Signed-off-by: Kevin Wolf <[email protected]>
78439f6af1caa3e8bdafc9fc2d62aeefa53ed63a
qemu
devign
1
https://github.com/qemu/qemu
https://github.com/qemu/qemu/commit/78439f6af1caa3e8bdafc9fc2d62aeefa53ed63a
2011-11-11 14:02:58+01:00
qemu-io: delete bs instead of leaking it Using bdrv_close() is not enough to free a BlockDriverState. Since we explicitly create it with bdrv_new(), use bdrv_delete() to close and delete it. Signed-off-by: Stefan Hajnoczi <[email protected]> Signed-off-by: Kevin Wolf <[email protected]>
b46578555c4bce64e3daba4591334aba2d12c156
qemu
devign
1
https://github.com/qemu/qemu
https://github.com/qemu/qemu/commit/b46578555c4bce64e3daba4591334aba2d12c156
2011-10-28 19:25:49+02:00
vmdk: Fix use of uninitialised value In error cases, cid is never set. Signed-off-by: Kevin Wolf <[email protected]>
bac8d7b45dd855759204117e5a05452ede01bbab
qemu
devign
1
https://github.com/qemu/qemu
https://github.com/qemu/qemu/commit/bac8d7b45dd855759204117e5a05452ede01bbab
2011-10-28 19:25:49+02:00
savevm: improve subsections detection on load We add qemu_peek_buffer, that is identical to qemu_get_buffer, just that it don't update f->buf_index. We add a paramenter to qemu_peek_byte() to be able to peek more than one byte. Once this is done, to see if we have a subsection we look: - 1st byte is QEMU_VM_SUBSECTION - 2nd byte is a length, and is bigger than section name - 3rd element is a string that starts with section_name So, we shouldn't have false positives (yes, content could still get us wrong but probabilities are really low). v2: - Alex Williamsom found that we could get negative values on index. - Rework code to fix that part. - Rewrite qemu_get_buffer() using qemu_peek_buffer() v3: - return "done" on error case v4: - fix qemu_file_skip() off by one. Signed-off-by: Juan Quintela <[email protected]>
c63807244fb55071675907460a0ecf228c1766c8
qemu
devign
1
https://github.com/qemu/qemu
https://github.com/qemu/qemu/commit/c63807244fb55071675907460a0ecf228c1766c8
2011-10-20 13:23:11+02:00
Add support for 128-bit arithmetic The memory API supports 64-bit buses (e.g. PCI). A size on such a bus cannot be represented with a 64-bit data type, if both 0 and the entire address space size are to be represented. Futhermore, any address arithemetic may overflow and return unexpected results. Introduce a 128-bit signed integer type for use in such cases. Addition, subtraction, and comparison are the only operations supported. Signed-off-by: Avi Kivity <[email protected]>
b7cd3db6f4d79f11abf0572fdc5e41d0811ea2e2
qemu
devign
1
https://github.com/qemu/qemu
https://github.com/qemu/qemu/commit/b7cd3db6f4d79f11abf0572fdc5e41d0811ea2e2
2011-10-16 13:13:05+02:00
build: fix race with creating qapi-generated Since qapi-generated/ is a global QEMU include path, we need to make sure it is created before anything is compiled, so do this in the configure phase rather than via the Makefile. Signed-off-by: Michael Roth <[email protected]> Signed-off-by: Anthony Liguori <[email protected]>
e098fc3fd2a5c9be6b38f6f54bd466f218b7c4e9
qemu
devign
1
https://github.com/qemu/qemu
https://github.com/qemu/qemu/commit/e098fc3fd2a5c9be6b38f6f54bd466f218b7c4e9
2011-09-23 10:55:34-05:00
hw/scsi-bus.c: Fix use of uninitialised variable Don't use req before it has been initialised in scsi_req_new(). This fixes a compile failure due to gcc complaining about this. Signed-off-by: Peter Maydell <[email protected]> Acked-by: Paolo Bonzini <[email protected]> Signed-off-by: Blue Swirl <[email protected]>
3b6ffe50300f13240e1b46420ad05da1116df410
qemu
devign
1
https://github.com/qemu/qemu
https://github.com/qemu/qemu/commit/3b6ffe50300f13240e1b46420ad05da1116df410
2011-08-14 19:34:25+00:00
sdl: Do not make full screen mode resizable This prevents continuous resizing events and improper screen setups when going full screen. CC: Stefano Stabellini <[email protected]> Signed-off-by: Jan Kiszka <[email protected]> Signed-off-by: Anthony Liguori <[email protected]>
91ada9808408fcad818ced7309f47c5fb91c6075
qemu
devign
1
https://github.com/qemu/qemu
https://github.com/qemu/qemu/commit/91ada9808408fcad818ced7309f47c5fb91c6075
2011-08-05 10:57:34-05:00
pcie_host: verify mmcfg address range For a conventional pci device behind a pcie-to-pci bridge, pci_host handlers get confused by an out of bounds access in the range [256, 4K). Check for such an access and make it have no effect. Signed-off-by: Isaku Yamahata <[email protected]> Signed-off-by: Michael S. Tsirkin <[email protected]>
43e86c8f5b6d9f6279e20dede4e1f7829bdc43b7
qemu
devign
1
https://github.com/qemu/qemu
https://github.com/qemu/qemu/commit/43e86c8f5b6d9f6279e20dede4e1f7829bdc43b7
2011-07-29 08:01:52+03:00
vhost: remove an incorrect assert The 'to' can go negative when the first region gets removed (it gets incremented by to 0 immediately afterward), which makes the assertion fail. Nothing breaks if to < 0 here so just remove the assert. Tested-by: David Ahern <[email protected]> Signed-off-by: Michael S. Tsirkin <[email protected]>
cb4b4fde82b064472c13fb9d983ca36a70e560aa
qemu
devign
1
https://github.com/qemu/qemu
https://github.com/qemu/qemu/commit/cb4b4fde82b064472c13fb9d983ca36a70e560aa
2011-08-03 18:00:53+03:00
iothread: replace fair_mutex with a condition variable This conveys the intention better, and scales to more than >1 threads contending the mutex with the iothread (as long as all of them have a "quiescent point" like the TCG thread has). Also, on Mac OS X the fair_mutex somehow didn't work as intended and deadlocked. Signed-off-by: Paolo Bonzini <[email protected]> Tested-by: Alexander Graf <[email protected]> Signed-off-by: Anthony Liguori <[email protected]>
46daff13c854769bfa8c51e77719325ea0f47b1b
qemu
devign
1
https://github.com/qemu/qemu
https://github.com/qemu/qemu/commit/46daff13c854769bfa8c51e77719325ea0f47b1b
2011-07-23 11:18:51-05:00
libcacard: don't leak vcard_emul_alloc_arrays mem vcard_emul_mirror_card and vcard_emul_init use vcard_emul_alloc_arrays to allocate memory for temporary arrays which will contain elements that in the end will be used one by one in cac_card_init. The arrays themselves are never stored anywhere, they are only used as temporary containers. Hence the memory that was allocated for these arrays should be freed after use or they will be leaked.
ee83d41466ab393d82d9abf57b9ec24d4e6633be
qemu
devign
1
https://github.com/qemu/qemu
https://github.com/qemu/qemu/commit/ee83d41466ab393d82d9abf57b9ec24d4e6633be
2011-07-22 18:05:36+03:00
PPC: 440: Use 440 style MMU as default, so Qemu knows the MMU type We have some KVM interaction code in Qemu that tries to be clever and ignore some capabilities when running on BookE style MMUs. Unfortunately, the default CPU bamboo was defaulting to was not a BookE-style MMU, resulting in the check to fail. With this patch, guests can run again on 440 with -enable-kvm. Signed-off-by: Alexander Graf <[email protected]>
0dd4bc7dd45de7afa88662d24bd50a3aafdbab64
qemu
devign
1
https://github.com/qemu/qemu
https://github.com/qemu/qemu/commit/0dd4bc7dd45de7afa88662d24bd50a3aafdbab64
2011-06-17 02:58:35+02:00
Fix buffer overrun in sched_getaffinity Zeroing of the cpu array should start from &cpus[kernel_ret] not &cpus[num_zeros_to_fill]. This fixes a crash in EFL's edje_cc running under qemu-arm. Signed-off-by: Mike McCormack <[email protected]> Reviewed-by: Stefan Hajnoczi <[email protected]> Acked-by: Mike Frysinger <[email protected]> Signed-off-by: Riku Voipio <[email protected]>
e95d3bf04d8a54af43bb8db3b8eb64d68c9f6927
qemu
devign
1
https://github.com/qemu/qemu
https://github.com/qemu/qemu/commit/e95d3bf04d8a54af43bb8db3b8eb64d68c9f6927
2011-05-02 10:00:01+03:00
kvm: ppc: fixes for KVM_SET_SREGS on init Classic/server ppc has had SREGS for a while now (though I think not always?), but it's still missing for booke. Check the capability before calling KVM_SET_SREGS. Without this, booke kvm fails to boot as of commit 84b4915dd2c0eaa86c970ffc42a68ea8ba9e48b5 (kvm: Handle kvm_init_vcpu errors). Also, don't write random stack state into the non-PVR sregs fields -- have kvm fill it in first. Eventually booke will have sregs and it will have its own capability to be tested here. However, we will want a way for platform code to request to look like the actual CPU we're running on, especially if SoC devices are being directly assigned. Signed-off-by: Scott Wood <[email protected]> Signed-off-by: Alexander Graf <[email protected]>
5666ca4ae06d20497f887241151278e266947087
qemu
devign
1
https://github.com/qemu/qemu
https://github.com/qemu/qemu/commit/5666ca4ae06d20497f887241151278e266947087
2011-05-09 22:31:37+02:00
target-arm: Set Q bit for overflow in SMUAD and SMLAD SMUAD and SMLAD are supposed to set the Q bit if the addition of the two 16x16 multiply products and optional accumulator overflows considered as a signed value. However we were only doing this check for the addition of the accumulator, not when adding the products, with the effect that we were mishandling the edge case where both inputs are 0x80008000. Signed-off-by: Peter Maydell <[email protected]> Signed-off-by: Aurelien Jarno <[email protected]>
e1d177b922f52569e900e96d611caa09655bdec9
qemu
devign
1
https://github.com/qemu/qemu
https://github.com/qemu/qemu/commit/e1d177b922f52569e900e96d611caa09655bdec9
2011-03-22 07:56:08+01:00
linux-user: Add configure check for linux/fiemap.h and IOC_FS_FIEMAP Add a configure check for the existence of linux/fiemap.h and the IOC_FS_FIEMAP ioctl. This fixes a compilation failure on Linux systems which don't have that header file. Signed-off-by: Peter Maydell <[email protected]> Signed-off-by: Aurelien Jarno <[email protected]>
dace20dcc98f90a931e88aa641f5633cdcf30c30
qemu
devign
1
https://github.com/qemu/qemu
https://github.com/qemu/qemu/commit/dace20dcc98f90a931e88aa641f5633cdcf30c30
2011-01-12 00:06:06+01:00
linux-user: fix memory leaks with NPTL emulation Running programs that create large numbers of threads, such as this snippet from libstdc++'s pthread7-rope.cc: const int max_thread_count = 4; const int max_loop_count = 10000; ... for (int j = 0; j < max_loop_count; j++) { ... for (int i = 0; i < max_thread_count; i++) pthread_create (&tid[i], NULL, thread_main, 0); for (int i = 0; i < max_thread_count; i++) pthread_join (tid[i], NULL); } in user-mode emulation will quickly run out of memory. This is caused by a failure to free memory in do_syscall prior to thread exit: /* TODO: Free CPU state. */ pthread_exit(NULL); The first step in fixing this is to make all TaskStates used by QEMU dynamically allocated. The TaskState used by the initial thread was not, as it was allocated on main's stack. So fix that, free the cpu_env, free the TaskState, and we're home free, right? Not exactly. When we create a thread, we do: ts = qemu_mallocz(sizeof(TaskState) + NEW_STACK_SIZE); ... new_stack = ts->stack; ... ret = pthread_attr_setstack(&attr, new_stack, NEW_STACK_SIZE); If we blindly free the TaskState, then, we yank the current (host) thread's stack out from underneath it while it still has things to do, like calling pthread_exit. That causes problems, as you might expect. The solution adopted here is to let the C library allocate the thread's stack (so the C library can properly clean it up at pthread_exit) and provide a hint that we want NEW_STACK_SIZE bytes of stack. With those two changes, we're done, right? Well, almost. You see, we're creating all these host threads and their parent threads never bother to check that their children are finished. There's no good place for the parent threads to do so. Therefore, we need to create the threads in a detached state so the parent thread doesn't have to call pthread_join on the child to release the child's resources; the child does so automatically. With those three major changes, we can comfortably run programs like the above without exhausting memory. We do need to delete 'stack' from the TaskState structure. Signed-off-by: Nathan Froyd <[email protected]> Signed-off-by: Riku Voipio <[email protected]>
48e15fc2de29276f0c93482f5175b95e50557fbf
qemu
devign
1
https://github.com/qemu/qemu
https://github.com/qemu/qemu/commit/48e15fc2de29276f0c93482f5175b95e50557fbf
2010-12-03 15:09:38+02:00
pci/bridge: fix pci_bridge_reset() The lower bits of base/limit registers is RO and shouldn't be zero cleared on reset. This patch fixes it. In fact, the default value of base/limit registers aren't specified in the spec. And some bridges disable forwarding on reset instead of zeroing base/limit registers. So introduce one function to disable bridge forwarding so that such bridges can use it. It will be used later. Signed-off-by: Isaku Yamahata <[email protected]> Signed-off-by: Michael S. Tsirkin <[email protected]>
0208def1cadd4f72f862e62548c2af268a543b20
qemu
devign
1
https://github.com/qemu/qemu
https://github.com/qemu/qemu/commit/0208def1cadd4f72f862e62548c2af268a543b20
2010-10-20 12:05:10+02:00
scsi-disk: respect the page control (PC) field in the MODE SENSE command The page control (PC) field defines the type of mode parameter values to be returned in the mode pages: PC=0 : Current values PC=1 : Changeable values PC=2 : Default values PC=3 : Saved values The current implementation always returns the same type of parameters. This is OK for Current and Default values as we don't support changes to be done by the MODE SELECT command. For Saved values the following applies (implemented by this patch): "A PC field value of 3h requests that the target return the saved values of the mode parameters. Implementation of saved page parameters is optional. Mode parameters not supported by the target shall be set to zero. If saved values are not implemented, the command shall be terminated with CHECK CONDITION status, the sense key set to ILLEGAL REQUEST and the additional sense code set to SAVING PARAMETERS NOT SUPPORTED." For Changeable values the following applies (implemented by this patch): "A PC field value of 1h requests that the target return a mask denoting those mode parameters that are changeable. In the mask, the fields of the mode parameters that are changeable shall be set to all one bits and the fields of the mode parameters that are non-changeable (i.e. defined by the target) shall be set to all zero bits." In newer versions of the SCSI-2 spec the following clause was added. "If the logical unit does not implement changeable parameters mode pages and the device server receives a MODE SENSE command with 01b in the PC field, then the command shall be terminated with CHECK CONDITION status, with the sense key set to ILLEGAL REQUEST, and the additional sense code set to INVALID FIELD IN CDB." This was not yet included in the SCSI-2 Working Drafts from 1986-1993. I assume that the variant to return CHECK CONDITION for PC=1 is not widely implemented by real devices. I have a legacy OS which fails, if MODE_SENSE returns non GOOD for PC=1. So for highest compatibility I implemented the former variant with this patch. The last Working Draft X3T9.2 Rev. 10L 7-SEP-93 can be found here: http://ldkelley.com/SCSI2/SCSI2/SCSI2-08.html#8.2.10 In mode_sense_page() this patch also avoids multiple hard coded definitions of the same mode page length. Instead I use the varable p[1]. In fact the returned length of the mode pages 4 and 5 were wrong (2 bytes less). Signed-off-by: Bernhard Kohl <[email protected]> Signed-off-by: Kevin Wolf <[email protected]>
282ab04eb1e6f4faa6c5d2827e3209c4a1eec40e
qemu
devign
1
https://github.com/qemu/qemu
https://github.com/qemu/qemu/commit/282ab04eb1e6f4faa6c5d2827e3209c4a1eec40e
2010-09-08 12:39:07+02:00
vpc: Use bdrv_(p)write_sync for metadata writes Use bdrv_(p)write_sync to ensure metadata integrity in case of a crash. Signed-off-by: Kevin Wolf <[email protected]>
078a458e077d6b0db262c4b05fee51d01de2d1d2
qemu
devign
1
https://github.com/qemu/qemu
https://github.com/qemu/qemu/commit/078a458e077d6b0db262c4b05fee51d01de2d1d2
2010-06-22 14:38:02+02:00
check-qjson: Add more escape tests While there make the fail_unless() calls print error messages. IMPORTANT: The test for "\/" is failing, don't know why. Signed-off-by: Luiz Capitulino <[email protected]>
d22b0bd7fc85f991275ffc60a550ed42f4c1b04c
qemu
devign
1
https://github.com/qemu/qemu
https://github.com/qemu/qemu/commit/d22b0bd7fc85f991275ffc60a550ed42f4c1b04c
2010-06-11 15:25:14-03:00
qcow2: Fix error handling in l2_allocate l2_allocate has some intermediate states in which the image is inconsistent. Change the order to write to the L1 table only after the new L2 table has successfully been initialized. Also reset the L2 cache in failure case, it's very likely wrong. Signed-off-by: Kevin Wolf <[email protected]>
175e11526e2613b3dc031c23fec3107aa4a80307
qemu
devign
1
https://github.com/qemu/qemu
https://github.com/qemu/qemu/commit/175e11526e2613b3dc031c23fec3107aa4a80307
2010-05-28 13:14:25+02:00
virtio-serial: Fix check for 'assert'; prevent NULL derefs In the flush_queued_data() function, we expect port to be valid. Assert only for port and not port || discard. Reported-by: Juan Quintela <[email protected]> Signed-off-by: Amit Shah <[email protected]> Signed-off-by: Anthony Liguori <[email protected]>
a1c5975270f2335e1d7129c084a6e562d7b99bdd
qemu
devign
1
https://github.com/qemu/qemu
https://github.com/qemu/qemu/commit/a1c5975270f2335e1d7129c084a6e562d7b99bdd
2010-05-03 12:09:48-05:00
KVM: Rework of guest debug state writing So far we synchronized any dirty VCPU state back into the kernel before updating the guest debug state. This was a tribute to a deficite in x86 kernels before 2.6.33. But as this is an arch-dependent issue, it is better handle in the x86 part of KVM and remove the writeback point for generic code. This also avoids overwriting the flushed state later on if user space decides to change some more registers before resuming the guest. We furthermore need to reinject guest exceptions via the appropriate mechanism. That is KVM_SET_GUEST_DEBUG for older kernels and KVM_SET_VCPU_EVENTS for recent ones. Using both mechanisms at the same time will cause state corruptions. Signed-off-by: Jan Kiszka <[email protected]> Signed-off-by: Marcelo Tosatti <[email protected]>
b0b1d69079fcb9453f45aade9e9f6b71422147b0
qemu
devign
1
https://github.com/qemu/qemu
https://github.com/qemu/qemu/commit/b0b1d69079fcb9453f45aade9e9f6b71422147b0
2010-03-04 00:29:26-03:00
block: Simplify usb_msd_initfn() test for "can read bdrv key" The old test assumes that "hotplugged" implies "we have a current monitor for reading the key". This is in fact true, but it's not obviously true. Aside: if it were false, we could pass a null pointer to monitor_read_bdrv_key_start(), which would then crash. The previous commit permits us to check for "we have a current monitor" directly, so do that.
a44264880ef42254edb88f9ec5d6f35e3e84089b
qemu
devign
1
https://github.com/qemu/qemu
https://github.com/qemu/qemu/commit/a44264880ef42254edb88f9ec5d6f35e3e84089b
2010-03-16 16:55:05+01:00
tcg/mips: fix crash in tcg_out_qemu_ld() The address register is overriden when it corresponds to v0 and the fast path is taken, which leads to a crash. Fix that by using the a0 register instead. Signed-off-by: Aurelien Jarno <[email protected]>
cca1af8c4d2ef6449fd61494ba2cb087b838011c
qemu
devign
1
https://github.com/qemu/qemu
https://github.com/qemu/qemu/commit/cca1af8c4d2ef6449fd61494ba2cb087b838011c
2010-02-09 22:54:22+01:00
kvm: Fix eflags corruption in kvm mode This should explain a lot of the weird breakages of upstream KVM we've seen recently (actually we should have seen it much earlier): Stop translating eflags into TCG format when in kvm mode as we never translate it back and rather sync this broken state into the kernel. Signed-off-by: Jan Kiszka <[email protected]> Signed-off-by: Avi Kivity <[email protected]>
14dcc3e2ac52d7a2a1cfe2e54c332d8042485a39
qemu
devign
1
https://github.com/qemu/qemu
https://github.com/qemu/qemu/commit/14dcc3e2ac52d7a2a1cfe2e54c332d8042485a39
2010-02-21 11:12:37+02:00
Fix backcompat for hotplug of SCSI controllers SCSI controllers have no trouble existing without any attached disks. This could be achieved with the (legacy) monitor syntax pci_add pci_addr=auto storage if=scsi This is now denied with scsi requires a backing file/device. failed to add if=scsi There is no need for this denial and it breaks compatability with existing QEMU usage, so remove the check for presence of a drive. Signed-off-by: Daniel P. Berrange <[email protected]> Signed-off-by: Anthony Liguori <[email protected]>
ec7efac4a967c650ae1cd8cebe28e7c69cbe3864
qemu
devign
1
https://github.com/qemu/qemu
https://github.com/qemu/qemu/commit/ec7efac4a967c650ae1cd8cebe28e7c69cbe3864
2009-12-18 11:26:33-06:00
net: check for TUNSETOFFLOAD support before trying to enable offload features This avoids the "TUNSETOFFLOAD ioctl() failed: Invalid argument" message on kernels without TUNSETOFFLOAD support. Signed-off-by: Pierre Riteau <[email protected]> Signed-off-by: Mark McLoughlin <[email protected]> Signed-off-by: Anthony Liguori <[email protected]>
2e50326c44c802ca9b9d591341085e49208927be
qemu
devign
1
https://github.com/qemu/qemu
https://github.com/qemu/qemu/commit/2e50326c44c802ca9b9d591341085e49208927be
2009-12-03 09:41:35-06:00
Expose a mechanism to trace block writes To support live migration without shared storage we need to be able to trace writes to disk while migrating. This Patch expose dirty block tracking per device to be polled from upper layer. Changes from v4: - Register dirty tracking for each block device. - Minor coding style issues. - Block.c will now manage a dirty bitmap per device once bdrv_set_dirty_tracking() is called. Bitmap is polled by the upper layer (block-migration.c). Signed-off-by: Liran Schour <[email protected]> Signed-off-by: Anthony Liguori <[email protected]>
7cd1e32a860895ccca89eb90a0226efbcd969b55
qemu
devign
1
https://github.com/qemu/qemu
https://github.com/qemu/qemu/commit/7cd1e32a860895ccca89eb90a0226efbcd969b55
2009-11-17 08:03:31-06:00
qcow2: Fix grow_refcount_table error handling In case of failure, we haven't increased the refcount for the newly allocated cluster yet. Therefore we must not free the cluster or its refcount will become negative (and endless recursion is possible). Signed-off-by: Kevin Wolf <[email protected]> Signed-off-by: Anthony Liguori <[email protected]>
c5baaa489f5557fa01431ba0c5de28b43fc9631e
qemu
devign
1
https://github.com/qemu/qemu
https://github.com/qemu/qemu/commit/c5baaa489f5557fa01431ba0c5de28b43fc9631e
2009-10-27 12:28:35-05:00
qdev: don't crash on unset drive properties. Signed-off-by: Gerd Hoffmann <[email protected]> Signed-off-by: Anthony Liguori <[email protected]>
41b5e892b7dbf553b356b51004a6966233e71a6d
qemu
devign
1
https://github.com/qemu/qemu
https://github.com/qemu/qemu/commit/41b5e892b7dbf553b356b51004a6966233e71a6d
2009-10-05 09:32:50-05:00
Correctly free nd structure When we "free" a NICInfo structure, we can leak pointers, since we don't do much more than setting used = 0. We free() the model parameter, but we don't set it to NULL. This means that a new user of this structure will see garbage in there. It was not noticed before because reusing a NICInfo is not that common, but it can be, for users of device pci hotplug. A user hit it, described at https://bugzilla.redhat.com/show_bug.cgi?id=524022 This patch memset's the whole structure, guaranteeing that anyone reusing it will see a fresh NICinfo. Also, we free some other strings that are currently leaking. This codebase is quite old, so this patch should feed all stable trees. Signed-off-by: Glauber Costa <[email protected]> Signed-off-by: Anthony Liguori <[email protected]>
a9796703447fc5c5691b749915f0f627f47f05a9
qemu
devign
1
https://github.com/qemu/qemu
https://github.com/qemu/qemu/commit/a9796703447fc5c5691b749915f0f627f47f05a9
2009-10-05 09:32:44-05:00
microblaze: Correct prio between MMU and unaligned exceptions. The microblaze gives MMU faults priority. For stores we still have a flaw that the value leaks to memory in the case of an unaligned exception. Signed-off-by: Edgar E. Iglesias <[email protected]>
a12f65078105d5f280b39ddb72a6ebdfa3b2164c
qemu
devign
1
https://github.com/qemu/qemu
https://github.com/qemu/qemu/commit/a12f65078105d5f280b39ddb72a6ebdfa3b2164c
2009-09-11 10:35:27+02:00
PPC: convert Uni-north to qdev: also fixes Mac99 machine crash Signed-off-by: Blue Swirl <[email protected]>
2e29bd04786003561303dcad940b38afe790fb9b
qemu
devign
1
https://github.com/qemu/qemu
https://github.com/qemu/qemu/commit/2e29bd04786003561303dcad940b38afe790fb9b
2009-07-31 20:23:28+00:00
bsd-users: fix strace Hi! Attached patch fixes an unlock bug in strace. Catched by gcc due to an use of uninitialized variable. Signed-off-by: Christoph Egger <[email protected]> -- ---to satisfy European Law for business letters: Advanced Micro Devices GmbH Karl-Hammerschmidt-Str. 34, 85609 Dornach b. Muenchen Geschaeftsfuehrer: Thomas M. McCoy, Giuliano Meroni Sitz: Dornach, Gemeinde Aschheim, Landkreis Muenchen Registergericht Muenchen, HRB Nr. 43632
18c9a9c3c2698d71575d49c308db88f295ddffed
qemu
devign
1
https://github.com/qemu/qemu
https://github.com/qemu/qemu/commit/18c9a9c3c2698d71575d49c308db88f295ddffed
2009-07-17 17:48:03+00:00
Allow adjustment of http block device's readahead size, via a new ":readahead=###:" suffix. Signed-off-by: Nolan Leake <nolan <at> sigbus.net> Signed-off-by: Anthony Liguori <[email protected]>
c76f4952bbf47116255bc00780ceae3bc8a657c0
qemu
devign
1
https://github.com/qemu/qemu
https://github.com/qemu/qemu/commit/c76f4952bbf47116255bc00780ceae3bc8a657c0
2009-07-09 16:06:40-05:00
slirp: Factor out one-time initialization In order to prepare re-initialization and multi-instance slirp, factor out init code that is of global scope and (at least for now) only need to be run once. This also fixes the potentially uninitialized use of our_addr in get_dns_addr. Signed-off-by: Jan Kiszka <[email protected]> Signed-off-by: Anthony Liguori <[email protected]>
df46189412567906312684eb72ba87c6a86a4cdb
qemu
devign
1
https://github.com/qemu/qemu
https://github.com/qemu/qemu/commit/df46189412567906312684eb72ba87c6a86a4cdb
2009-06-29 08:52:47-05:00
Apply TCGV_UNUSED on variables that GCC mistakenly thinks can be used uninitialized
d2e9fd8f703203c2eeeed120b1ef6c3a6574e0ab
qemu
devign
1
https://github.com/qemu/qemu
https://github.com/qemu/qemu/commit/d2e9fd8f703203c2eeeed120b1ef6c3a6574e0ab
2009-06-20 05:51:47+04:00
Prevent CD-ROM media eject while device is locked Section 10.8.25 ("START/STOP UNIT Command") of SFF-8020i states that if the device is locked we should refuse to eject if the device is locked. ASC_MEDIA_REMOVAL_PREVENTED is the appropriate return in this case. In order to stop itself from ejecting the media it is running from, Fedora's installer (anaconda) requires the CDROMEJECT ioctl() to fail if the drive has been previously locked. See also https://bugzilla.redhat.com/501412 Signed-off-by: Mark McLoughlin <[email protected]> Signed-off-by: Anthony Liguori <[email protected]>
aea2a33c73f28ecd8f10b242ecadddcc79c1c28b
qemu
devign
1
https://github.com/qemu/qemu
https://github.com/qemu/qemu/commit/aea2a33c73f28ecd8f10b242ecadddcc79c1c28b
2009-06-16 15:52:37-05:00
Make `-icount' help fit 80 chars screen width (Robert Riebisch) On Windows default screen width for the command prompt (A.K.A. "DOS window") is 80 chars. `-icount' help is 87 chars wide. So make it fit. Signed-off-by: Robert Riebisch <[email protected]> Signed-off-by: Anthony Liguori <[email protected]> git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@6991 c046a42c-6fe2-441c-8c8c-71466251a162
bc14ca2453f22f20569699bda5f12e892131092c
qemu
devign
1
https://github.com/qemu/qemu
https://github.com/qemu/qemu/commit/bc14ca2453f22f20569699bda5f12e892131092c
2009-04-05 18:43:37+00:00
Compile all files with -ffixed-g5 etc. to avoid env (%g5) corruption git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@6972 c046a42c-6fe2-441c-8c8c-71466251a162
762e823086ad37453c2308bccf01223f07759eab
qemu
devign
1
https://github.com/qemu/qemu
https://github.com/qemu/qemu/commit/762e823086ad37453c2308bccf01223f07759eab
2009-04-04 09:21:28+00:00
Fix Sparc64 VGA memory size bug exposed by r6604 git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@6618 c046a42c-6fe2-441c-8c8c-71466251a162
176050719287eb73f6ff8610843cbcbbb0ae388b
qemu
devign
1
https://github.com/qemu/qemu
https://github.com/qemu/qemu/commit/176050719287eb73f6ff8610843cbcbbb0ae388b
2009-02-12 17:29:32+00:00
mips: limit RAM size to 256MB on malta and qemu boards This avoid crash when a bigger RAM size is requested (the devices are mapped at 0x01000000). Signed-off-by: Aurelien Jarno <[email protected]> git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@6419 c046a42c-6fe2-441c-8c8c-71466251a162
0ccff151b42a5b684ce22473b68972a94bc708fb
qemu
devign
1
https://github.com/qemu/qemu
https://github.com/qemu/qemu/commit/0ccff151b42a5b684ce22473b68972a94bc708fb
2009-01-24 15:07:25+00:00
powerpc/kvm: Fix a uninitialized bug (Liu Yu) Signed-off-by: Liu Yu <[email protected]> Acked-by: Hollis Blanchard <[email protected]> Signed-off-by: Anthony Liguori <[email protected]> git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@6327 c046a42c-6fe2-441c-8c8c-71466251a162
57be80f948cdbb75ef00fd8345845d83010d8af1
qemu
devign
1
https://github.com/qemu/qemu
https://github.com/qemu/qemu/commit/57be80f948cdbb75ef00fd8345845d83010d8af1
2009-01-15 21:18:42+00:00
check for bs->drv in bdrv_flush (Christoph Hellwig) All the bdrv_ helpers should check for bs->drv being zero as that means there is no backend image open. bdrv_flush fails to perform that check and can thus cause NULL pointer dereferences. Found using qemu-io. Signed-off-by: Christoph Hellwig <[email protected]> Signed-off-by: Anthony Liguori <[email protected]> git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@6943 c046a42c-6fe2-441c-8c8c-71466251a162
081501daceca74d2091e798d5dcd342c14d66d1a
qemu
devign
1
https://github.com/qemu/qemu
https://github.com/qemu/qemu/commit/081501daceca74d2091e798d5dcd342c14d66d1a
2009-03-29 01:31:51+00:00
ppc: fix crash in ppc system single step support There was a bogus case where two system debug ops get generated. This patch removes the broken system debug op. This was a left over after making some changes to correctly generate debug ops on branch operations inside gen_goto_tb(); The test case against this patch is to turn on single stepping with timers, boot a linux kernel, set a breakpoint a do_fork and in gdb execute "si 3000". Then qemu-system-ppc will fault executing a debug op, which should not have been executed. Signed-off-by: Jason Wessel <[email protected]> Signed-off-by: Aurelien Jarno <[email protected]> git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@5391 c046a42c-6fe2-441c-8c8c-71466251a162
ee600be6a6379697d04673fd9ab10b66732b42e1
qemu
devign
1
https://github.com/qemu/qemu
https://github.com/qemu/qemu/commit/ee600be6a6379697d04673fd9ab10b66732b42e1
2008-10-01 22:01:37+00:00
Add support for the 'k' (kill) and 'D' (detach) packets (Jason Wessel). Implement the 'k' gdbserial packet which kills the qemu instance via the debugger stub. Implement the 'D' detach packet for the gdb stub such that you can disconnect gdb with the "detach" command. This required implementing a cpu_breakpoint_remove_all() and a cpu_watchpoint_remove_all() function to cleanup all the breakpoints and watchpoints prior to leaving the gdb stub else simulation can stop with no debugger attached. On a '?' packet remove all the breakpoints and watchpoints. This is considered more of a safety net in case you force killed gdb or it crashed and you are reconnecting. The identical behavior exists for kgdb in the linux kernel. git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@4478 c046a42c-6fe2-441c-8c8c-71466251a162
7d03f82f81e0e6c106ca0d2445a0fc49dc9ddc7b
qemu
devign
1
https://github.com/qemu/qemu
https://github.com/qemu/qemu/commit/7d03f82f81e0e6c106ca0d2445a0fc49dc9ddc7b
2008-05-17 18:58:29+00:00
Upgrade emulated UART to 16550A (Stefano Stabellini) This patch upgrades the emulated UART to 16550A, the code comes from xen-unstable. The main improvement was introduced with the following patch and subsequent email thread: http://lists.xensource.com/archives/html/xen-devel/2007-12/msg00129.html The changes compared to previous version are: - change clock_gettime to qemu_get_clock - no token bucket anymore; - fixed a small bug handling IRQs; this was the problem that prevented kgdb to work over the serial (thanks to Jason Wessel for the help spotting and reproducing this bug). - many many style fixes; - savevm version number increased; - not including termios.h and sys/ioctl.h anymore, declaring static constants in qemu-char.h instead; Signed-off-by: Stefano Stabellini <[email protected]> Signed-off-by: Anthony Liguori <[email protected]> git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@4993 c046a42c-6fe2-441c-8c8c-71466251a162
81174dae3f9189519cd60c7b79e91c291b021bbe
qemu
devign
1
https://github.com/qemu/qemu
https://github.com/qemu/qemu/commit/81174dae3f9189519cd60c7b79e91c291b021bbe
2008-08-11 14:17:04+00:00
Check for out of range update regions (original patch from Anthony Liguori). git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@4024 c046a42c-6fe2-441c-8c8c-71466251a162
a8fbaf96e0791d72078d22b75c5f3c1f1d1ee45d
qemu
devign
1
https://github.com/qemu/qemu
https://github.com/qemu/qemu/commit/a8fbaf96e0791d72078d22b75c5f3c1f1d1ee45d
2008-03-06 20:43:34+00:00
Work around a crash when timer signal occurs before main loop, original patch by 武田 俊也. git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@3820 c046a42c-6fe2-441c-8c8c-71466251a162
4f8eb8daebd72bdc214c63a3b2577f95bbadb27d
qemu
devign
1
https://github.com/qemu/qemu
https://github.com/qemu/qemu/commit/4f8eb8daebd72bdc214c63a3b2577f95bbadb27d
2007-12-16 12:39:38+00:00
Update OpenBIOS images to SVN revision 181. Changes: r177: Reset fixes: * recalculate CRC to avoid error message and halt after reset * fix bug that crashed SS10/SMP when reset r178: Remove unused variable r179: Improved Module ID generation r180: Add support for eccmemctl r181: Add support for SPARCstation 20 machine type git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@3804 c046a42c-6fe2-441c-8c8c-71466251a162
52df269ca821e8bed49ae2d46fe67486f3ef88de
qemu
devign
1
https://github.com/qemu/qemu
https://github.com/qemu/qemu/commit/52df269ca821e8bed49ae2d46fe67486f3ef88de
2007-12-11 19:33:21+00:00
Fix invalid PowerPC 64 rldimi optimized case. git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@3638 c046a42c-6fe2-441c-8c8c-71466251a162
271a916e8a4188b0ec94bafff18aa93de0047820
qemu
devign
1
https://github.com/qemu/qemu
https://github.com/qemu/qemu/commit/271a916e8a4188b0ec94bafff18aa93de0047820
2007-11-14 05:26:46+00:00
Synchronize with latest PowerPC ISA VEA: * fix invalid instructions bits masks * new wait instruction * more comments about effect of cache instructions on the MMU git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@3287 c046a42c-6fe2-441c-8c8c-71466251a162
0db1b20e478efd378c19e79057453a79b4c81e11
qemu
devign
1
https://github.com/qemu/qemu
https://github.com/qemu/qemu/commit/0db1b20e478efd378c19e79057453a79b4c81e11
2007-09-30 03:46:38+00:00
Fix qemu SIGFPE caused by division-by-zero due to underflow. git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@2673 c046a42c-6fe2-441c-8c8c-71466251a162
80c27194a7be757ef5a9cec978d1d8faaa4cee81
qemu
devign
1
https://github.com/qemu/qemu
https://github.com/qemu/qemu/commit/80c27194a7be757ef5a9cec978d1d8faaa4cee81
2007-04-15 21:21:33+00:00
xilinx_spips: Correct usage of an uninitialized local variable Coverity found that the variable tx_rx in the function xilinx_spips_flush_txfifo was being used uninitialized (CID 1383841). This patch corrects this by always initializing tx_rx to zeros. Signed-off-by: Francisco Iglesias <[email protected]> Message-id: [email protected] Reviewed-by: Peter Maydell <[email protected]> Signed-off-by: Peter Maydell <[email protected]>
fbe5dac7b2777626670097218ce4dfc4a19a17e9
qemu
devign
1
https://github.com/qemu/qemu
https://github.com/qemu/qemu/commit/fbe5dac7b2777626670097218ce4dfc4a19a17e9
2018-01-25 11:45:30+00:00
s390x: fix storage attributes migration for non-small guests Fix storage attribute migration so that it does not fail for guests with more than a few GB of RAM. With such guests, the index in the buffer would go out of bounds, usually by large amounts, thus receiving -EFAULT from the kernel. Migration itself would be successful, but storage attributes would then not be migrated completely. This patch fixes the out of bounds access, and thus migration of all storage attributes when the guest have large amounts of memory. Cc: [email protected] Signed-off-by: Claudio Imbrenda <[email protected]> Fixes: 903fd80b03243476 ("s390x/migration: Storage attributes device") Message-Id: <[email protected]> Reviewed-by: Christian Borntraeger <[email protected]> Signed-off-by: Cornelia Huck <[email protected]>
46fa893355e0bd88f3c59b886f0d75cbd5f0bbbe
qemu
devign
1
https://github.com/qemu/qemu
https://github.com/qemu/qemu/commit/46fa893355e0bd88f3c59b886f0d75cbd5f0bbbe
2018-01-22 11:04:52+01:00
tcg/ppc: Allow a 32-bit offset to the constant pool We recently relaxed the limit of the number of opcodes that can appear in a TranslationBlock. In certain cases this has resulted in relocation overflow. Signed-off-by: Richard Henderson <[email protected]>
030ffe39dd4128eb90483af82a5b23b23054a466
qemu
devign
1
https://github.com/qemu/qemu
https://github.com/qemu/qemu/commit/030ffe39dd4128eb90483af82a5b23b23054a466
2018-01-16 08:21:56-08:00
tests: fix coroutine leak in /basic/entered The coroutine is not finished by the time the test ends, resulting in ASAN warning: ==7005==ERROR: LeakSanitizer: detected memory leaks Direct leak of 312 byte(s) in 1 object(s) allocated from: #0 0x7fd35290fa38 in __interceptor_calloc (/lib64/libasan.so.4+0xdea38) #1 0x7fd3506c5f75 in g_malloc0 ../glib/gmem.c:124 #2 0x55994af03e47 in qemu_coroutine_new /home/elmarco/src/qemu/util/coroutine-ucontext.c:144 #3 0x55994aefed99 in qemu_coroutine_create /home/elmarco/src/qemu/util/qemu-coroutine.c:76 #4 0x55994ac1eb50 in verify_entered_step_1 /home/elmarco/src/qemu/tests/test-coroutine.c:80 #5 0x55994af03c75 in coroutine_trampoline /home/elmarco/src/qemu/util/coroutine-ucontext.c:119 #6 0x7fd34ec02bef (/lib64/libc.so.6+0x50bef) Do not yield() to let the coroutine terminate. Signed-off-by: Marc-André Lureau <[email protected]> Reviewed-by: Stefan Hajnoczi <[email protected]> Message-Id: <[email protected]> Signed-off-by: Paolo Bonzini <[email protected]>
6b2fef739127ee6135d5ccc2da0bf1f3bebf66b7
qemu
devign
1
https://github.com/qemu/qemu
https://github.com/qemu/qemu/commit/6b2fef739127ee6135d5ccc2da0bf1f3bebf66b7
2018-01-16 14:54:50+01:00
input: fix memory leak If kbd_queue is not empty and queue_count >= queue_limit, we should free evt. Change-Id: Ieeacf90d5e7e370a40452ec79031912d8b864d83 Signed-off-by: linzhecheng <[email protected]> Message-id: [email protected] Signed-off-by: Gerd Hoffmann <[email protected]>
fca4774a96843ba9d32a5d5d1c3826e1478facae
qemu
devign
1
https://github.com/qemu/qemu
https://github.com/qemu/qemu/commit/fca4774a96843ba9d32a5d5d1c3826e1478facae
2018-01-12 14:20:39+01:00
target/xtensa: add internal/noop SRs and opcodes Add two special registers: MMID and DDR: - MMID is write-only and the only side effect of writing to it is output to the trace port, which is not emulated; - DDR is only accessible in debug mode, which is not emulated. Add two debug-mode-only opcodes: - rfdd and rfdo do return from the debug mode, which is not emulated. Add three internal opcodes for full MMU: - hwwdtlba and hwwitlba are the internal opcodes that write a value into autoupdate DTLB or ITLB entry. - ldpte is internal opcode that loads PTE entry that covers the most recent page fault address. None of these three opcodes may appear in a valid instruction. Signed-off-by: Max Filippov <[email protected]>
13f6a7cd3a736b40e14b28d7e4df45ec9333f155
qemu
devign
1
https://github.com/qemu/qemu
https://github.com/qemu/qemu/commit/13f6a7cd3a736b40e14b28d7e4df45ec9333f155
2018-01-09 09:55:39-08:00
build-sys: compile with -Og or -O1 when --enable-debug When --enable-debug is turned on, configure doesn't set -O level, and uses default compiler -O0 level, which is slow. Instead, use -Og if supported by the compiler (optimize debugging experience), or -O1 (keeps code somewhat debuggable and works around compiler bugs). Unfortunately, gcc has many false-positive maybe-uninitialized errors with Og and O1 (f27 gcc 7.2.1 20170915): /home/elmarco/src/qemu/hw/ipmi/isa_ipmi_kcs.c: In function ‘ipmi_kcs_ioport_read’: /home/elmarco/src/qemu/hw/ipmi/isa_ipmi_kcs.c:279:12: error: ‘ret’ may be used uninitialized in this function [-Werror=maybe-uninitialized] return ret; ^~~ cc1: all warnings being treated as errors make: *** [/home/elmarco/src/qemu/rules.mak:66: hw/ipmi/isa_ipmi_kcs.o] Error 1 make: *** Waiting for unfinished jobs.... /home/elmarco/src/qemu/hw/ide/ahci.c: In function ‘ahci_populate_sglist’: /home/elmarco/src/qemu/hw/ide/ahci.c:903:58: error: ‘tbl_entry_size’ may be used uninitialized in this function [-Werror=maybe-uninitialized] if ((off_idx == -1) || (off_pos < 0) || (off_pos > tbl_entry_size)) { ~~~~~~~~~^~~~~~~~~~~~~~~~~ cc1: all warnings being treated as errors make: *** [/home/elmarco/src/qemu/rules.mak:66: hw/ide/ahci.o] Error 1 /home/elmarco/src/qemu/hw/display/qxl.c: In function ‘qxl_add_memslot’: /home/elmarco/src/qemu/hw/display/qxl.c:1397:52: error: ‘pci_start’ may be used uninitialized in this function [-Werror=maybe-uninitialized] memslot.virt_end = virt_start + (guest_end - pci_start); ~~~~~~~~~~~~~^~~~~~~~~~~~ /home/elmarco/src/qemu/hw/display/qxl.c:1389:9: error: ‘pci_region’ may be used uninitialized in this function [-Werror=maybe-uninitialized] qxl_set_guest_bug(d, "%s: pci_region = %d", __func__, pci_region); ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ cc1: all warnings being treated as errors There seems to be a long list of related bugs in upstream GCC, some of them are being fixed very recently: https://gcc.gnu.org/bugzilla/show_bug.cgi?id=24639 For now, let's workaround it by using Wno-maybe-uninitialized (gcc-only). Suggested-by: Paolo Bonzini <[email protected]> Signed-off-by: Marc-André Lureau <[email protected]> Message-Id: <[email protected]> Tested-by: Philippe Mathieu-Daudé <[email protected]> Signed-off-by: Paolo Bonzini <[email protected]>
906548689e37ab6cca1e93b3f8d9327a4e17e8af
qemu
devign
1
https://github.com/qemu/qemu
https://github.com/qemu/qemu/commit/906548689e37ab6cca1e93b3f8d9327a4e17e8af
2018-01-12 13:22:02+01:00
Split adb.c into adb.c, adb-mouse.c and adb-kbd.c It makes the code clearer to separate the bus implementation from the devices one. Replace ADB_DPRINTF() with trace events (and adding new ones in adb-kbd.c). Some minor changes to make checkpatch.pl happy. Signed-off-by: Laurent Vivier <[email protected]> Reviewed-by: Philippe Mathieu-Daudé <[email protected]> Reviewed-by: Mark Cave-Ayland <[email protected]> Message-Id: <[email protected]>
77cb0f5aafc8e6d0c6d3c339f381c9b7921648e0
qemu
devign
1
https://github.com/qemu/qemu
https://github.com/qemu/qemu/commit/77cb0f5aafc8e6d0c6d3c339f381c9b7921648e0
2017-12-21 20:11:28+01:00
9pfs: deprecate handle backend This backend raise some concerns: - doesn't support symlinks - fails +100 tests in the PJD POSIX file system test suite [1] - requires the QEMU process to run with the CAP_DAC_READ_SEARCH capability, which isn't recommended for security reasons This backend should not be used and wil be removed. The 'local' backend is the recommended alternative. [1] https://www.tuxera.com/community/posix-test-suite/ Signed-off-by: Greg Kurz <[email protected]> Reviewed-by: Daniel P. Berrange <[email protected]> Reviewed-by: Aneesh Kumar K.V <[email protected]>
db3b3c7281ca82e2647e072a1f97db111313dd73
qemu
devign
1
https://github.com/qemu/qemu
https://github.com/qemu/qemu/commit/db3b3c7281ca82e2647e072a1f97db111313dd73
2018-01-08 11:18:23+01:00
spapr/rtas: disable the decrementer interrupt when a CPU is unplugged When a CPU is stopped with the 'stop-self' RTAS call, its state 'halted' is switched to 1 and, in this case, the MSR is not taken into account anymore in the cpu_has_work() routine. Only the pending hardware interrupts are checked with their LPCR:PECE* enablement bit. If the DECR timer fires after 'stop-self' is called and before the CPU 'stop' state is reached, the nearly-dead CPU will have some work to do and the guest will crash. This case happens very frequently with the not yet upstream P9 XIVE exploitation mode. In XICS mode, the DECR is occasionally fired but after 'stop' state, so no work is to be done and the guest survives. I suspect there is a race between the QEMU mainloop triggering the timers and the TCG CPU thread but I could not quite identify the root cause. To be safe, let's disable in the LPCR all the exceptions which can cause an exit while the CPU is in power-saving mode and reenable them when the CPU is started. Signed-off-by: Cédric Le Goater <[email protected]> Signed-off-by: David Gibson <[email protected]>
9a94ee5bb15793ef69692998ef57794a33074134
qemu
devign
1
https://github.com/qemu/qemu
https://github.com/qemu/qemu/commit/9a94ee5bb15793ef69692998ef57794a33074134
2017-12-15 09:49:24+11:00
spapr: don't initialize PATB entry if max-cpu-compat < power9 if KVM is enabled and KVM capabilities MMU radix is available, the partition table entry (patb_entry) for the radix mode is initialized by default in ppc_spapr_reset(). It's a problem if we want to migrate the guest to a POWER8 host while the kernel is not started to set the value to the one expected for a POWER8 CPU. The "-machine max-cpu-compat=power8" should allow to migrate a POWER9 KVM host to a POWER8 KVM host, but because patb_entry is set, the destination QEMU tries to enable radix mode on the POWER8 host. This fails and cancels the migration: Process table config unsupported by the host error while loading state for instance 0x0 of device 'spapr' load of migration failed: Invalid argument This patch doesn't set the PATB entry if the user provides a CPU compatibility mode that doesn't support radix mode. Signed-off-by: Laurent Vivier <[email protected]> Signed-off-by: David Gibson <[email protected]>
1481fe5fcfeb7fcf3c1ebb9d8c0432e3e0188ccf
qemu
devign
1
https://github.com/qemu/qemu
https://github.com/qemu/qemu/commit/1481fe5fcfeb7fcf3c1ebb9d8c0432e3e0188ccf
2017-12-15 09:50:29+11:00
nbd/server: CVE-2017-15118 Stack smash on large export name Introduced in commit f37708f6b8 (2.10). The NBD spec says a client can request export names up to 4096 bytes in length, even though they should not expect success on names longer than 256. However, qemu hard-codes the limit of 256, and fails to filter out a client that probes for a longer name; the result is a stack smash that can potentially give an attacker arbitrary control over the qemu process. The smash can be easily demonstrated with this client: $ qemu-io f raw nbd://localhost:10809/$(printf %3000d 1 | tr ' ' a) If the qemu NBD server binary (whether the standalone qemu-nbd, or the builtin server of QMP nbd-server-start) was compiled with -fstack-protector-strong, the ability to exploit the stack smash into arbitrary execution is a lot more difficult (but still theoretically possible to a determined attacker, perhaps in combination with other CVEs). Still, crashing a running qemu (and losing the VM) is bad enough, even if the attacker did not obtain full execution control. CC: [email protected] Signed-off-by: Eric Blake <[email protected]>
51ae4f8455c9e32c54770c4ebc25bf86a8128183
qemu
devign
1
https://github.com/qemu/qemu
https://github.com/qemu/qemu/commit/51ae4f8455c9e32c54770c4ebc25bf86a8128183
2017-11-28 06:58:01-06:00