Re: [Qemu-devel] [PATCH 1/3] replay: Define ReplayMode without QAPI

2017-07-31 Thread Pavel Dovgalyuk
> From: Markus Armbruster [mailto:arm...@redhat.com] > ReplayMode is defined in the QAPI schema, but not used there. Of the > stuff QAPI generates for it only the typedef is actually used. Use of > QAPI is pointless and only complicates things, so don't. This a bit useless now, but we plan to ad

Re: [Qemu-devel] [RFC 11/29] migration: new postcopy-pause state

2017-07-31 Thread Peter Xu
On Fri, Jul 28, 2017 at 10:53:00AM -0500, Eric Blake wrote: > On 07/28/2017 03:06 AM, Peter Xu wrote: > > Introducing a new state "postcopy-paused", which can be used to pause a > > postcopy migration. It is targeted to support network failures during > > postcopy migration. Now when network down f

Re: [Qemu-devel] [PATCH] migration: optimize the downtime

2017-07-31 Thread Jay Zhou
Hi Dave, On 2017/7/25 18:34, Dr. David Alan Gilbert wrote: After checking the codes of the newest libvirt, I think it is the same in the qemuMigrationWaitForCompletion function, which is used to poll qemu every 50ms. Checking with Jiri Denemark (added to cc), newer libvirt should use events wh

Re: [Qemu-devel] [RFC 16/29] qmp: hmp: add migrate "resume" option

2017-07-31 Thread Peter Xu
On Fri, Jul 28, 2017 at 10:57:12AM -0500, Eric Blake wrote: > On 07/28/2017 03:06 AM, Peter Xu wrote: > > It will be used when we want to resume one paused migration. > > > > Signed-off-by: Peter Xu > > --- > > hmp-commands.hx | 7 --- > > hmp.c | 4 +++- > > migration/

Re: [Qemu-devel] [PATCH v2 1/1] monitor: improve tracing in handle_qmp_command

2017-07-31 Thread Markus Armbruster
Eric Blake writes: > On 07/28/2017 12:01 PM, Markus Armbruster wrote: >> "Denis V. Lunev" writes: >> >>> Calculate req_json only if trace_handle_qmp_command enabled. >>> >>> Signed-off-by: Denis V. Lunev >>> CC: Stefan Hajnoczi >>> CC: Lluís Vilanova >>> CC: Dr. David Alan Gilbert >>> CC: M

Re: [Qemu-devel] [PATCH v3 09/12] tests/libqos/pci: Clean up string interpolation into QMP input

2017-07-31 Thread Markus Armbruster
Eric Blake writes: > On 07/28/2017 11:35 AM, Eric Blake wrote: +QObject *extra_args = qobject_from_jsonf("{ 'shm': '%s', 'size': '1M' }", + tmpshm); >>> > >> Passing '%s' through qobject_from_jsonf() is generally wrong (it would >> p

Re: [Qemu-devel] [PATCH v3 08/12] qtests: convert tests to use qmp_cmd

2017-07-31 Thread Markus Armbruster
Eric Blake writes: > On 07/28/2017 01:53 PM, Markus Armbruster wrote: >> Eric Blake writes: >> >>> Now that we have the qmp_cmd() helper, we can further simplify >>> some of the tests by using it. >>> >>> Signed-off-by: Eric Blake >>> --- > >>> } >>> -resp = qmp("{'execute': 'qom-list

Re: [Qemu-devel] [PULL v1 0/7] MMIO Exec pull request

2017-07-31 Thread KONRAD Frederic
On 07/28/2017 12:13 PM, Peter Maydell wrote: On 28 July 2017 at 10:18, Peter Maydell wrote: Talking to David about this on IRC, even "don't allow migration" is a bit tricky, because you can't register a migration-blocker if a migration is already in progress. Two further options: * disable

[Qemu-devel] [Bug 1707587] [NEW] Read certificate from USB key failed

2017-07-31 Thread Dean Yu
Public bug reported: QEMU release version: qemu-2.9.0 VM operation system: win7 32bit I have an usb key which can be redirected and recognized in VM. However, it is failed to get the certificate when using the official application for this usb key. What's more, the whole app is stalled untill thi

Re: [Qemu-devel] [PATCH v3 07/12] qtest: Add a new helper qmp_cmd() and friends

2017-07-31 Thread Markus Armbruster
Eric Blake writes: > On 07/28/2017 08:06 AM, Eric Blake wrote: >> On 07/28/2017 07:57 AM, Stefan Hajnoczi wrote: >>> On Tue, Jul 25, 2017 at 04:15:18PM -0500, Eric Blake wrote: +QDict *qtest_qmp_cmd(QTestState *s, const char *cmd, QObject *args) +{ +QDict *dict = qdict_new(); >

Re: [Qemu-devel] [PATCH v3 03/12] qtest: Document calling conventions

2017-07-31 Thread Markus Armbruster
Eric Blake writes: > On 07/28/2017 01:32 PM, Markus Armbruster wrote: >> Eric Blake writes: >> >>> We have two flavors of vararg usage in qtest; make it clear that >>> qmp() has different semantics than hmp(), and let the compiler >>> enforce that hmp() is used correctly. However, qmp() (and fr

[Qemu-devel] qemu guest agent support 'guest-exec'

2017-07-31 Thread Hu, Robert
Hi, >From $qemu_src/qga/ code, guest-exec should be supported. But from $qemu_src/scripts/qmp/qemu-ga-client output, it is not supported, on client side. Why didn't implement on client side? or any configuration I missed? Best Regards, Robert Hoo

Re: [Qemu-devel] [PATCH 3/3] s390x/css: generate channel path initialized CRW for channel path hotplug

2017-07-31 Thread Cornelia Huck
On Fri, 28 Jul 2017 16:29:14 +0200 Halil Pasic wrote: > On 07/28/2017 02:58 PM, Cornelia Huck wrote: > > On Fri, 28 Jul 2017 14:32:11 +0200 > > Halil Pasic wrote: > > > >> On 07/28/2017 12:11 PM, Cornelia Huck wrote: > >>> On Thu, 27 Jul 2017 18:15:07 +0200 > >>> Halil Pasic wrote: > >

Re: [Qemu-devel] [Bug 1707297] [NEW] qemu became more picky parsing -m option

2017-07-31 Thread Markus Armbruster
John Florian <1707...@bugs.launchpad.net> writes: > Public bug reported: > > With qemu-kvm-2.9.0-3.fc26.x86_64 I am no longer to specify the memory > size using something like "-m 1.0GiB" but with qemu- > kvm-2.7.1-7.fc25.x86_64 I could without any problem. I now get an error > message like:

Re: [Qemu-devel] [PATCH 3/3] s390x/css: generate channel path initialized CRW for channel path hotplug

2017-07-31 Thread Cornelia Huck
On Mon, 31 Jul 2017 09:46:17 +0800 Dong Jia Shi wrote: > * Cornelia Huck [2017-07-28 14:58:19 +0200]: > > Exposing real channel paths to the guest means that the guest OS needs > > to be able to deal with path-related things, but OTOH it has more > > control. As I don't think we'll ever want to

Re: [Qemu-devel] How to make ELF headers/symbol sections available for multiboot?

2017-07-31 Thread Peter Maydell
On 28 July 2017 at 22:28, Anatol Pomozov wrote: > So I need to perform 2 things: > > - Load ELF section headers into target's memory. I did by appending > additional space to mbs.mb_buf and copying header data. Is it the best > way to do? > > - Next I need to load other ELF sections such as symb

[Qemu-devel] [PATCH v6 3/7] qemu.py: use python logging system

2017-07-31 Thread Amador Pahim
Let's provide extra control and flexibility by using python logging system instead of print and/or sys.std*.write(). Signed-off-by: Amador Pahim --- scripts/qemu.py | 16 +--- 1 file changed, 13 insertions(+), 3 deletions(-) diff --git a/scripts/qemu.py b/scripts/qemu.py index 77565

[Qemu-devel] [PATCH v6 2/7] qemu.py: fix is_running() return before first launch()

2017-07-31 Thread Amador Pahim
is_running() returns None when called before the first time we call launch(): >>> import qemu >>> vm = qemu.QEMUMachine('qemu-system-x86_64') >>> vm.is_running() >>> It should retunt False instead. This patch fixes that. Signed-off-by: Amador Pahim --- scripts/qemu.py | 2 +- 1

[Qemu-devel] [PATCH v6 1/7] qemu.py: use poll() instead of 'returncode'

2017-07-31 Thread Amador Pahim
The 'returncode' Popen attribute is not guaranteed to be updated. It actually depends on a call to either poll(), wait() or communicate(). On the other hand, poll() will: "Check if child process has terminated. Set and return returncode attribute." Let's use the poll() to check whether the proces

[Qemu-devel] [PATCH v6 6/7] qemu.py: cleanup and improve launch()/shutdown()

2017-07-31 Thread Amador Pahim
launch() is currently taking care of a number of flows, each one if its own exception treatment, depending on the VM state and the files creation state. This patch makes launch() more resilient, off-loading the core calls to the new _launch() and calling shutdown() if any exception is raised by _l

[Qemu-devel] [PATCH v6 5/7] qemu.py: use os.path.null instead of /dev/null

2017-07-31 Thread Amador Pahim
For increased portability, let's use os.path.devnull. Signed-off-by: Amador Pahim --- scripts/qemu.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/scripts/qemu.py b/scripts/qemu.py index 9434ccc30b..d313c6d4db 100644 --- a/scripts/qemu.py +++ b/scripts/qemu.py @@ -80,7

[Qemu-devel] [PATCH v6 4/7] qemu.py: improve message on negative exit code

2017-07-31 Thread Amador Pahim
The current message shows 'self._args', which contains only part of the options used in the qemu command line. This patch makes the qemu full args list an instance variable and then uses it in the negative exit code message. Signed-off-by: Amador Pahim --- scripts/qemu.py | 17 -

[Qemu-devel] [PATCH v6 7/7] qemu.py: include debug information on launch error

2017-07-31 Thread Amador Pahim
When launching a VM, if an exception happens and the VM is not initiated, it is useful to see the qemu command line that was executed and the output of that command. Before this patch: >>> import qemu >>> vm = qemu.QEMUMachine('qemu-system-aarch64', debug=True) >>> vm.launch() Tra

Re: [Qemu-devel] [PATCH 0/3] Channel Path realted CRW generation

2017-07-31 Thread Cornelia Huck
On Fri, 28 Jul 2017 23:50:48 +0800 Dong Jia Shi wrote: > * Cornelia Huck [2017-07-28 13:53:01 +0200]: > > > > You're bound to get different kinds of notifications: via a CRW with > > > > source channel path, via event information retrievable via CHSC > > > > (indicated by a CRW with source CSS)

[Qemu-devel] [PATCH v6 0/7] scripts/qemu.py fixes and cleanups

2017-07-31 Thread Amador Pahim
Changes v1->v2: - Style fixes to make checkpatch.pl happy. - Rebased. Changes v2->v3: - Fix typo in patch 3 ("qemu.py: make 'args' public") commit message. Changes v3->v4: - Squash the 2 first commits since they are co-dependant. - Cleanup launch() and shutdown(). - Reorder the commits, putti

Re: [Qemu-devel] [PATCH 2/3] COLO: Define COLOMode without QAPI

2017-07-31 Thread Markus Armbruster
Eric Blake writes: > On 07/28/2017 12:17 PM, Dr. David Alan Gilbert wrote: >> * Markus Armbruster (arm...@redhat.com) wrote: >>> COLOMode is defined in the QAPI schema, but not used there. Of the >>> stuff QAPI generates for it only the typedef is actually used. Use of >>> QAPI is pointless and

Re: [Qemu-devel] [PATCH v2 1/4] coding_style: add point about 0x in trace-events

2017-07-31 Thread Stefan Hajnoczi
On Sat, Jul 29, 2017 at 04:11:56PM +0300, Vladimir Sementsov-Ogievskiy wrote: > Signed-off-by: Vladimir Sementsov-Ogievskiy > --- > CODING_STYLE | 23 +++ > 1 file changed, 23 insertions(+) > > diff --git a/CODING_STYLE b/CODING_STYLE > index 2fa0c0b65b..2e6a0507be 100644 > -

Re: [Qemu-devel] [PATCH v2 2/4] trace-events: fix code style: %# -> 0x%

2017-07-31 Thread Stefan Hajnoczi
On Sat, Jul 29, 2017 at 04:11:57PM +0300, Vladimir Sementsov-Ogievskiy wrote: > In trace format '#' flag of printf is forbidden. Fix it to '0x%'. > > This patch is created by the following: > > check that we have a problem > > find . -name trace-events | xargs grep '%#' | wc -l > 56 > > check th

Re: [Qemu-devel] [PATCH v2 3/4] checkpatch: check trace-events code style

2017-07-31 Thread Stefan Hajnoczi
On Sat, Jul 29, 2017 at 04:11:58PM +0300, Vladimir Sementsov-Ogievskiy wrote: > Accordingly to CODING_STYLE, check that in trace-events: > 1. hex numbers are prefixed with '0x' > 2. '#' flag of printf is not used > 3. The exclusion from 1. are period-separated groups of numbers > > Signed-off-by:

Re: [Qemu-devel] [PULL 0/2] ppc-for-2.10 queue 20170731

2017-07-31 Thread Peter Maydell
ble in the git repository at: > > git://github.com/dgibson/qemu.git tags/ppc-for-2.10-20170731 > > for you to fetch changes up to fc7e0765fc385eed08c19a8823a970f4e98379b0: > > Revert "spapr: populate device tree depending on

Re: [Qemu-devel] [PATCH v2 4/4] trace-events: fix code style: print 0x before hex numbers

2017-07-31 Thread Stefan Hajnoczi
On Sat, Jul 29, 2017 at 04:11:59PM +0300, Vladimir Sementsov-Ogievskiy wrote: > The only exception are groups of numers separated by symbols > '.', ' ', ':', '/', like 'ab.09.7d'. > > This patch is made by the following: > > > find . -name trace-events | xargs python script.py > > where script.p

Re: [Qemu-devel] [PATCH v2 2/2] Add more function keys to cocoa.m

2017-07-31 Thread Daniel P. Berrange
On Sun, Jul 30, 2017 at 04:29:47PM -0400, Programmingkid wrote: > Enable the Cocoa front-end to be able to use function keys F16 to F20. > > Signed-off-by: John Arbuckle > --- > ui/cocoa.m | 5 + > 1 file changed, 5 insertions(+) Reviewed-by: Daniel P. Berrange Regards, Daniel -- |: htt

Re: [Qemu-devel] [PATCH for 2.10] trace: ensure .stp files are rebuilt if trace tool source changes

2017-07-31 Thread Stefan Hajnoczi
On Fri, Jul 28, 2017 at 02:36:31PM +0100, Daniel P. Berrange wrote: > The make rules for generating the .stp files forgot to add a dep > on $(tracetool-y) to trigger a rebuild if the trace tool source > changes. > > Signed-off-by: Daniel P. Berrange > --- > Makefile.target | 9 ++--- > 1 fil

Re: [Qemu-devel] [PATCH v2 1/2] Add more function keys to QEMU

2017-07-31 Thread Daniel P. Berrange
On Sun, Jul 30, 2017 at 04:29:27PM -0400, Programmingkid wrote: > There are now keyboards that have 19 function keys. This patch extends QEMU > so these function keys can be used. > > Signed-off-by: John Arbuckle > --- > qapi-schema.json | 12 +++- > ui/input-keymap.c | 9 + >

Re: [Qemu-devel] [PATCH v2 4/4] trace-events: fix code style: print 0x before hex numbers

2017-07-31 Thread Cornelia Huck
On Sat, 29 Jul 2017 16:11:59 +0300 Vladimir Sementsov-Ogievskiy wrote: > The only exception are groups of numers separated by symbols > '.', ' ', ':', '/', like 'ab.09.7d'. > (...) > Signed-off-by: Vladimir Sementsov-Ogievskiy > --- > accel/tcg/trace-events| 2 +- > block/trace-events

Re: [Qemu-devel] [PATCH for 2.10] trace: ensure unique function / variable names per .stp file

2017-07-31 Thread Stefan Hajnoczi
On Fri, Jul 28, 2017 at 02:36:57PM +0100, Daniel P. Berrange wrote: > The simpletrace compatibility code for systemtap creates a > function and some global variables for mapping to event ID > numbers. We generate multiple -simpletrace.stp files though, > one per target and systemtap considers funct

[Qemu-devel] [PATCH v3 3/7] block: tidy ThrottleGroupMember initializations

2017-07-31 Thread Manos Pitsidianakis
Move the CoMutex and CoQueue inits inside throttle_group_register_tgm() which is called whenever a ThrottleGroupMember is initialized. There's no need for them to be separate. Reviewed-by: Stefan Hajnoczi Signed-off-by: Manos Pitsidianakis --- block/block-backend.c | 3 --- block/throttle-gro

[Qemu-devel] [PATCH v3 0/7] add throttle block driver filter

2017-07-31 Thread Manos Pitsidianakis
This series adds a throttle block driver filter. Currently throttling is done at the BlockBackend level. Using block driver interfaces we can move the throttling to any point in the BDS graph using a throttle node which uses the existing throttling code. This allows for potentially more complex con

[Qemu-devel] [PATCH v3 5/7] block: add throttle block filter driver

2017-07-31 Thread Manos Pitsidianakis
block/throttle.c uses existing I/O throttle infrastructure inside a block filter driver. I/O operations are intercepted in the filter's read/write coroutines, and referred to block/throttle-groups.c The driver can be used with the syntax -drive driver=throttle,file.filename=foo.qcow2, \ li

[Qemu-devel] [PATCH v3 2/7] block: add aio_context field in ThrottleGroupMember

2017-07-31 Thread Manos Pitsidianakis
timer_cb() needs to know about the current Aio context of the throttle request that is woken up. In order to make ThrottleGroupMember backend agnostic, this information is stored in an aio_context field instead of accessing it from BlockBackend. Reviewed-by: Stefan Hajnoczi Signed-off-by: Manos P

[Qemu-devel] [PATCH v3 6/7] block: add BlockDevOptionsThrottle to QAPI

2017-07-31 Thread Manos Pitsidianakis
This is needed to configure throttle filter driver nodes with QAPI. Signed-off-by: Manos Pitsidianakis --- qapi/block-core.json | 20 +++- 1 file changed, 19 insertions(+), 1 deletion(-) diff --git a/qapi/block-core.json b/qapi/block-core.json index 0bdc69aa5f..f5ce67c4fb 100644

[Qemu-devel] [PATCH v3 4/7] block: convert ThrottleGroup to object with QOM

2017-07-31 Thread Manos Pitsidianakis
ThrottleGroup is converted to an object. This will allow the future throttle block filter drive easy creation and configuration of throttle groups in QMP and cli. A new QAPI struct, ThrottleLimits, is introduced to provide a shared struct for all throttle configuration needs in QMP. ThrottleGroup

[Qemu-devel] [PATCH v3 7/7] block: add throttle block filter driver interface tests

2017-07-31 Thread Manos Pitsidianakis
Signed-off-by: Manos Pitsidianakis --- tests/qemu-iotests/184 | 237 + tests/qemu-iotests/184.out | 319 + tests/qemu-iotests/group | 1 + 3 files changed, 557 insertions(+) create mode 100755 tests/qemu-iotests/

[Qemu-devel] [PATCH v3 1/7] block: move ThrottleGroup membership to ThrottleGroupMember

2017-07-31 Thread Manos Pitsidianakis
This commit eliminates the 1:1 relationship between BlockBackend and throttle group state. Users will be able to create multiple throttle nodes, each with its own throttle group state, in the future. The throttle group state cannot be per-BlockBackend anymore, it must be per-throttle node. This i

Re: [Qemu-devel] [RFC PATCH v2 4/6] hw/pci: introduce bridge-only vendor-specific capability to provide some hints to firmware

2017-07-31 Thread Marcel Apfelbaum
On 29/07/2017 2:12, Michael S. Tsirkin wrote: On Thu, Jul 27, 2017 at 12:39:54PM +0300, Marcel Apfelbaum wrote: On 27/07/2017 2:28, Michael S. Tsirkin wrote: On Thu, Jul 27, 2017 at 12:54:07AM +0300, Alexander Bezzubikov wrote: 2017-07-26 22:43 GMT+03:00 Michael S. Tsirkin : On Sun, Jul 23, 2

Re: [Qemu-devel] [for-2.11 PATCH 04/26] spapr_drc: use g_strdup_printf() instead of snprintf()

2017-07-31 Thread Philippe Mathieu-Daudé
Hi David, On 07/26/2017 12:58 AM, David Gibson wrote: On Tue, Jul 25, 2017 at 07:58:53PM +0200, Greg Kurz wrote: Passing a stack allocated buffer of arbitrary length to snprintf() without checking the return value can cause the resultant strings to be silently truncated. Signed-off-by: Greg Ku

Re: [Qemu-devel] [PATCH v2 for 2.10 0/8] docs: fix broken paths

2017-07-31 Thread Michael Tokarev
29.07.2017 01:46, Philippe Mathieu-Daudé wrote: > Hi Michael, you already applied this series to -trivial, however I updated the > commits message, not requested but not a heavy task to do neither. Since you > didn't not sent PR yet, if you mind can you take those instead? Else it's not > a big dea

Re: [Qemu-devel] [PATCH] fix qemu-system-unicore32 crashing when calling without -kernel

2017-07-31 Thread Michael Tokarev
28.07.2017 14:53, Eduardo Otubo wrote: > Starting qemu-system-unicore32 without the -kernel parameter results in > an assert() returns false and aborts qemu. This patch replaces it with a > proper error message followed by exit(1). Applied to -trivial, thanks! /mjt

Re: [Qemu-devel] [PATCH] unicore32: abort when entering "x 0" on the monitor

2017-07-31 Thread Michael Tokarev
28.07.2017 14:51, Eduardo Otubo wrote: > Starting Qemu with "qemu-system-unicore32 -M puv3,accel=qtest -S -nographic" > and entering "x 0 " at the monitor prompt leads to abort(): Applied to -trivial, thanks! /mjt

Re: [Qemu-devel] [PATCH] build-sys: there is no qemu-ga.c

2017-07-31 Thread Michael Tokarev
27.07.2017 18:45, Marc-André Lureau wrote: > It got moved in qga/main.c from commit 2870dc3456c9c. Applied to -trivial, thanks! /mjt

Re: [Qemu-devel] [PATCH] tests: test-netfilter && pxe-test require slirp

2017-07-31 Thread Michael Tokarev
27.07.2017 18:45, Marc-André Lureau wrote: > If slirp is disabled, it will fail with: Applied to -trivial, thanks! /mjt

[Qemu-devel] [PULL 07/25] tests: add missing dependency to build QTEST_QEMU_BINARY

2017-07-31 Thread Michael Tokarev
From: Philippe Mathieu-Daudé This allow a one liner from fresh repository clone, i.e.: ./configure && make -j check-qtest-aarch64 Signed-off-by: Philippe Mathieu-Daudé Reviewed-by: Alex Bennée Reviewed-by: Stefan Hajnoczi Reviewed-by: John Snow Signed-off-by: Michael Tokarev --- tests/M

[Qemu-devel] [PULL 10/25] qcow2: fix null pointer dereference

2017-07-31 Thread Michael Tokarev
From: Philippe Mathieu-Daudé It seems this assert() was somehow misplaced. block/qcow2-refcount.c:2193:42: warning: Array access (from variable 'on_disk_reftable') results in a null pointer dereference on_disk_reftable[refblock_index] = refblock_offset;

[Qemu-devel] [PULL 09/25] ivshmem: fix incorrect error handling in ivshmem_recv_msg()

2017-07-31 Thread Michael Tokarev
From: Philippe Mathieu-Daudé Screwed up in commit 3a55fc0f, v2.6.0. If qemu_chr_fe_read_all() returns -EINTR the do {} statement continues and the n accumulator used to complete reads upto sizeof(msg) is decremented by 4 (the value of EINTR on Linux). To avoid that, use simpler if() statements a

[Qemu-devel] [PULL 02/25] fix qemu-system-unicore32 crashing when calling without -kernel

2017-07-31 Thread Michael Tokarev
From: Eduardo Otubo Starting qemu-system-unicore32 without the -kernel parameter results in an assert() returns false and aborts qemu. This patch replaces it with a proper error message followed by exit(1). Signed-off-by: Eduardo Otubo Tested-by: Thomas Huth Signed-off-by: Michael Tokarev ---

[Qemu-devel] [PULL 00/25 for-2.10] Trivial patches for 2017-07-31

2017-07-31 Thread Michael Tokarev
since commit 0c26c080ee592ea47597d3ab8fd712d7d2c4ba0f: Merge remote-tracking branch 'remotes/dgibson/tags/ppc-for-2.10-20170731' into staging (2017-07-31 09:59:26 +0100) are available in the git repository at: git://git.corpit.ru/qemu.git tags/trivial-patches-fetch for you to fetc

[Qemu-devel] [PULL 06/25] qemu-system-tricore: segfault when entering "x 0" on the monitor

2017-07-31 Thread Michael Tokarev
From: Eduardo Otubo Starting Qemu with "qemu-system-tricore -nographic -M tricore_testboard -S" and entering "x 0" at the monitor prompt leads to Segmentation fault. This happens because tricore_cpu_get_phys_page_debug() is not implemented yet, this is a temporary workaround to avoid the crash.

[Qemu-devel] [PULL 04/25] tests: test-netfilter && pxe-test require slirp

2017-07-31 Thread Michael Tokarev
From: Marc-André Lureau If slirp is disabled, it will fail with: qemu-system-x86_64: -netdev user,id=qtest-bn0: Parameter 'type' expects a netdev backend type Signed-off-by: Marc-André Lureau Signed-off-by: Michael Tokarev --- tests/Makefile.include | 8 1 file changed, 4 insertion

[Qemu-devel] [PULL 08/25] loader: check get_image_size() return value

2017-07-31 Thread Michael Tokarev
From: Philippe Mathieu-Daudé since a negative value means it errored. hw/core/loader.c:149:9: warning: Loss of sign in implicit conversion if (size > max_sz) { ^~~~ hw/core/loader.c:171:9: warning: Loss of sign in implicit conversion if (size > memory_region_size(mr)) { ^

[Qemu-devel] [PULL 12/25] net/eth: fix incorrect check of iov_to_buf() return value

2017-07-31 Thread Michael Tokarev
From: Philippe Mathieu-Daudé So we have sizeof(struct in6_address) != sizeof(uintptr_t) and Clang > Coverity on this, see 4555ca6816c :) net/eth.c:426:30: warning: The code calls sizeof() on a pointer type. This can produce an unexpected result return bytes_read == sizeof(dst_addr);

[Qemu-devel] [PULL 19/25] docs: fix broken paths to docs/interop dir

2017-07-31 Thread Michael Tokarev
From: Cleber Rosa With the move of some docs to docs/interop on d59157e, a couple of references were not updated. Signed-off-by: Cleber Rosa [PMD: fixed a typo and another reference of docs/interop/qmp-spec.txt] Signed-off-by: Philippe Mathieu-Daudé Reviewed-by: Eric Blake Signed-off-by: Mich

[Qemu-devel] [PULL 16/25] syscall: fix use of uninitialized values

2017-07-31 Thread Michael Tokarev
From: Philippe Mathieu-Daudé linux-user/syscall.c:1627:35: warning: 1st function call argument is an uninitialized value target_saddr->sa_family = tswap16(addr->sa_family); ^~~~ linux-user/syscall.c:1629:25: warning: The left operand

[Qemu-devel] [PULL 13/25] m68k/translate: fix incorrect copy/paste

2017-07-31 Thread Michael Tokarev
From: Philippe Mathieu-Daudé db3d7945ae extended gen_cc_cond() for cond [6, 7, 9, 10] but misswrote [4, 5] target/m68k/translate.c:1323:70: warning: identical expressions on both sides of logical operator if (op == CC_OP_ADDB || op == CC_OP_ADDW || op == CC_OP_ADDL || op ==

[Qemu-devel] [PULL 18/25] thunk: assert nb_fields is valid

2017-07-31 Thread Michael Tokarev
From: Philippe Mathieu-Daudé thunk.c:91:32: warning: Call to 'malloc' has an allocation size of 0 bytes se->field_offsets[i] = malloc(nb_fields * sizeof(int)); ^~~ Reported-by: Clang Static Analyzer Signed-off-by: Philippe Mathie

[Qemu-devel] [PULL 17/25] syscall: check inotify() and eventfd() return value

2017-07-31 Thread Michael Tokarev
From: Philippe Mathieu-Daudé linux-user/syscall.c:555:25: warning: Out of bound memory access (accessed memory precedes memory block) target_fd_trans[fd] = trans; ^~~ Reported-by: Clang Static Analyzer Suggested-by: Laurent Vivier Signed-off-by: Philippe Mathieu

Re: [Qemu-devel] [for-2.11 PATCH 04/26] spapr_drc: use g_strdup_printf() instead of snprintf()

2017-07-31 Thread Greg Kurz
On Mon, 31 Jul 2017 07:11:45 -0300 Philippe Mathieu-Daudé wrote: > Hi David, > > On 07/26/2017 12:58 AM, David Gibson wrote: > > On Tue, Jul 25, 2017 at 07:58:53PM +0200, Greg Kurz wrote: > >> Passing a stack allocated buffer of arbitrary length to snprintf() > >> without checking the return v

[Qemu-devel] [PULL 22/25] docs: fix broken paths to docs/devel/atomics.txt

2017-07-31 Thread Michael Tokarev
From: Philippe Mathieu-Daudé With the move of some docs/ to docs/devel/ on ac06724a71, a couple of references were not updated. Signed-off-by: Philippe Mathieu-Daudé Signed-off-by: Michael Tokarev --- docs/devel/lockcnt.txt | 2 +- include/qemu/atomic.h | 4 ++-- tcg/README | 2 +

[Qemu-devel] [PULL 11/25] ui/vnc: fix leak of SocketAddress **

2017-07-31 Thread Michael Tokarev
From: Philippe Mathieu-Daudé Extract the (correct) cleaning code as a new function vnc_free_addresses() then use it to remove the memory leaks. Reported-by: Clang Static Analyzer Signed-off-by: Philippe Mathieu-Daudé Reviewed-by: Daniel P. Berrange Signed-off-by: Michael Tokarev --- ui/vnc.c

[Qemu-devel] [PULL 03/25] MAINTAINERS: Improve the NetBSD regex pattern

2017-07-31 Thread Michael Tokarev
From: Thomas Huth Currently get_maintainers.pl claims that the configure script is maintained by Kamil: $ scripts/get_maintainer.pl -f configure Kamil Rytarowski (maintainer:NETBSD) qemu-devel@nongnu.org (open list:All patches CC here) This happens because the regex pattern for the NETBSD e

[Qemu-devel] [PULL 21/25] docs: fix broken paths to docs/devel/qapi-code-gen.txt

2017-07-31 Thread Michael Tokarev
From: Philippe Mathieu-Daudé With the move of some docs to docs/interop on ac06724a71, a couple of references were not updated. Signed-off-by: Philippe Mathieu-Daudé Signed-off-by: Michael Tokarev --- docs/devel/writing-qmp-commands.txt | 2 +- include/qapi/visitor.h | 2 +- qapi

[Qemu-devel] [PULL 15/25] syscall: fix dereference of undefined pointer

2017-07-31 Thread Michael Tokarev
From: Philippe Mathieu-Daudé linux-user/syscall.c:5581:9: warning: Dereference of undefined pointer value if (*host_rt_dev_ptr != 0) { ^~~~ Reported-by: Clang Static Analyzer Suggested-by: Laurent Vivier Signed-off-by: Philippe Mathieu-Daudé Reviewed-by: Laurent Vivier

[Qemu-devel] [PULL 20/25] docs: fix broken paths to docs/interop/qcow2.txt

2017-07-31 Thread Michael Tokarev
From: Philippe Mathieu-Daudé With the move of some docs to docs/interop on d59157ea05, a reference path was not updated. Signed-off-by: Philippe Mathieu-Daudé Reviewed-by: Kevin Wolf Signed-off-by: Michael Tokarev --- docs/qcow2-cache.txt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)

[Qemu-devel] xhci: guard xhci_kick_epctx against recursive calls for 2.8?

2017-07-31 Thread Michael Tokarev
After applying commit 96d87bdda3919bb16f754b3d3fd1227e1f38f13c: Author: Gerd Hoffmann Date: Thu Feb 2 12:36:12 2017 +0100 xhci: guard xhci_kick_epctx against recursive calls Track xhci_kick_epctx processing being active in a variable. Check the variable before calling xhci_kick_e

Re: [Qemu-devel] [PATCH v3 2/3] pci: add QEMU-specific PCI capability structure

2017-07-31 Thread Marcel Apfelbaum
On 29/07/2017 2:34, Aleksandr Bezzubikov wrote: On PCI init PCI bridge devices may need some extra info about bus number to reserve, IO, memory and prefetchable memory limits. QEMU can provide this with special vendor-specific PCI capability. This capability is intended to be used only for Red H

[Qemu-devel] [PULL 05/25] build-sys: there is no qemu-ga.c

2017-07-31 Thread Michael Tokarev
From: Marc-André Lureau It got moved in qga/main.c from commit 2870dc3456c9c. Signed-off-by: Marc-André Lureau Reviewed-by: Michael Roth Signed-off-by: Michael Tokarev --- Makefile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Makefile b/Makefile index ef721480eb..97a58

[Qemu-devel] [PULL 01/25] tests: check-qom-proplist: fix leak

2017-07-31 Thread Michael Tokarev
From: Marc-André Lureau user_creatable_add_opts() returns a reference (the other reference is for the root parent/child link). Leak introduced in commit a1af255f065cc. Signed-off-by: Marc-André Lureau Reviewed-by: Markus Armbruster Signed-off-by: Michael Tokarev --- tests/check-qom-proplist

[Qemu-devel] [PULL 23/25] docs: fix broken paths to docs/devel/tracing.txt

2017-07-31 Thread Michael Tokarev
From: Philippe Mathieu-Daudé With the move of some docs/ to docs/devel/ on ac06724a71, no references were updated. Signed-off-by: Philippe Mathieu-Daudé Reviewed-by: Stefan Hajnoczi Signed-off-by: Michael Tokarev --- audio/trace-events | 2 +- block/trace-events | 2

[Qemu-devel] [PULL 25/25] docs: fix broken paths to docs/specs/ivshmem-spec.txt

2017-07-31 Thread Michael Tokarev
From: Philippe Mathieu-Daudé When this file was rewritten/renamed in fdee2025dd, a reference path was not updated. Signed-off-by: Philippe Mathieu-Daudé Signed-off-by: Michael Tokarev --- docs/specs/pci-ids.txt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/specs/pci

[Qemu-devel] [PULL 14/25] linux-user/sh4: fix incorrect memory write

2017-07-31 Thread Michael Tokarev
From: Philippe Mathieu-Daudé not hit since 2009! :) linux-user/elfload.c:1102:20: warning: Out of bound memory access (access exceeds upper limit of memory block) (*regs[i]) = tswap32(env->gregs[i]); ~~~^~~~ Reported-by: Clang Static Analyzer Signed-

Re: [Qemu-devel] [PATCH v3 3/3] pci: enable RedHat PCI bridges to reserve additional buses on PCI init

2017-07-31 Thread Marcel Apfelbaum
On 29/07/2017 2:34, Aleksandr Bezzubikov wrote: In case of Red Hat Generic PCIE Root Port reserve additional buses, which number is provided in a vendor-specific capability. Signed-off-by: Aleksandr Bezzubikov --- src/fw/pciinit.c | 37 +++-- src/hw/pci_ids.h

[Qemu-devel] [PULL 24/25] docs: fix broken paths to docs/config/ich9-ehci-uhci.cfg

2017-07-31 Thread Michael Tokarev
From: Philippe Mathieu-Daudé With the move of some docs/ to docs/devel/ on ac06724a71, a reference path was not updated. Signed-off-by: Philippe Mathieu-Daudé Signed-off-by: Michael Tokarev --- docs/usb2.txt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/usb2.txt b/d

Re: [Qemu-devel] [PATCH v3 1/5] hw/i386: allow SHPC for Q35 machine

2017-07-31 Thread Marcel Apfelbaum
On 29/07/2017 2:37, Aleksandr Bezzubikov wrote: Unmask previously masked SHPC feature in _OSC method. Signed-off-by: Aleksandr Bezzubikov --- hw/i386/acpi-build.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/hw/i386/acpi-build.c b/hw/i386/acpi-build.c index 6b7bade

Re: [Qemu-devel] [PATCH 3/3] s390x/css: generate channel path initialized CRW for channel path hotplug

2017-07-31 Thread Cornelia Huck
On Mon, 31 Jul 2017 11:51:37 +0800 Dong Jia Shi wrote: > * Cornelia Huck [2017-07-27 13:59:10 +0200]: > > > On Thu, 27 Jul 2017 03:54:18 +0200 > > Dong Jia Shi wrote: > > > > > When a channel path is hot plugged into a CSS, we should generate > > > a channel path initialized CRW (channel re

Re: [Qemu-devel] [PATCH v3 2/5] hw/pci: introduce pcie-pci-bridge device

2017-07-31 Thread Marcel Apfelbaum
On 29/07/2017 2:37, Aleksandr Bezzubikov wrote: Introduce a new PCIExpress-to-PCI Bridge device, which is a hot-pluggable PCI Express device and supports devices hot-plug with SHPC. This device is intended to replace the DMI-to-PCI Bridge in an overwhelming majority of use-cases. Signed-off-by:

Re: [Qemu-devel] How to make ELF headers/symbol sections available for multiboot?

2017-07-31 Thread Kevin Wolf
Am 30.07.2017 um 23:42 hat Eduardo Habkost geschrieben: > CCing Alex, the original author of load_multiboot(), and Kevin, > who touched multiboot code recently. For some values of "recently". :-) > On Fri, Jul 28, 2017 at 02:28:34PM -0700, Anatol Pomozov wrote: > > Hi > > > > I am looking at x86

Re: [Qemu-devel] [PATCH v3 3/5] hw/pci: introduce bridge-only vendor-specific capability to provide some hints to firmware

2017-07-31 Thread Marcel Apfelbaum
On 29/07/2017 2:37, Aleksandr Bezzubikov wrote: On PCI init PCI bridges may need some extra info about bus number to reserve, IO, memory and prefetchable memory limits. QEMU can provide this with a special vendor-specific PCI capability. Signed-off-by: Aleksandr Bezzubikov --- hw/pci/pci_brid

Re: [Qemu-devel] [PATCH v3 4/5] hw/pci: add QEMU-specific PCI capability to Generic PCI Express Root Port

2017-07-31 Thread Marcel Apfelbaum
On 29/07/2017 2:37, Aleksandr Bezzubikov wrote: From: Aleksandr Bezzubikov To enable hotplugging of a newly created pcie-pci-bridge, we need to tell firmware (SeaBIOS in this case) Not only SeaBIOS, also OVMF - so all guest firmware to reserve additional buses for pcie-root-port, that allo

Re: [Qemu-devel] [PATCH v3 5/5] docs: update documentation considering PCIE-PCI bridge

2017-07-31 Thread Marcel Apfelbaum
On 29/07/2017 2:37, Aleksandr Bezzubikov wrote: Signed-off-by: Aleksandr Bezzubikov --- docs/pcie.txt| 46 ++ docs/pcie_pci_bridge.txt | 121 +++ 2 files changed, 147 insertions(+), 20 deletions(-) create mode 100644

Re: [Qemu-devel] [PULL 00/25 for-2.10] Trivial patches for 2017-07-31

2017-07-31 Thread Peter Maydell
Daudé. > > Please consider applying. > > Thanks, > > /mjt > > The following changes since commit 0c26c080ee592ea47597d3ab8fd712d7d2c4ba0f: > > Merge remote-tracking branch 'remotes/dgibson/tags/ppc-for-2.10-20170731' > into staging (2017-07-31 09:59:26

Re: [Qemu-devel] [PATCH] hw/arm: use defined type name instead of hard-coded string

2017-07-31 Thread Peter Maydell
On 27 July 2017 at 14:48, Philippe Mathieu-Daudé wrote: > On 07/27/2017 09:36 AM, Peter Maydell wrote: >> >> On 17 July 2017 at 14:30, Philippe Mathieu-Daudé wrote: >>> >>> Signed-off-by: Philippe Mathieu-Daudé >>> --- >>> >>> Hi Peter, this patch is waiting the IDE queue to enters since it depe

Re: [Qemu-devel] [Qemu-arm] [PATCH for-2.10 0/5] M profile MPU bugfixes

2017-07-31 Thread Peter Maydell
On 27 July 2017 at 11:59, Peter Maydell wrote: > This patchset fixes some bugs in the M profile MPU code: > * the guest shouldn't be able to make system space executable > * PPB region accesses should not be subject to MPU lookups > * we were not resetting the PMSAv7 MPU state for M profile CPU

Re: [Qemu-devel] [PATCH for-2.11 1/3] qemu-iotests: set TEST_DIR to a unique dir for each test

2017-07-31 Thread Eric Blake
On 07/31/2017 12:04 AM, Jeff Cody wrote: > Right now, all qemu-iotests output data into the same scratch directory, > and so each tests needs to be responsible for cleanup up its own files. And, tests must either use unique names or else cannot be run in parallel. > > Have each test use 'scratch

Re: [Qemu-devel] [PATCH for-2.11 2/3] qemu-iotests: remove file cleanup from bash tests

2017-07-31 Thread Eric Blake
On 07/31/2017 12:04 AM, Jeff Cody wrote: > All files for a given test are now self-contained in a subdirectory, > and therefore the "./check" script can do all file-related cleanup > without any help. > > This removes file cleanups from the bash tests. The only cleanup left > is whatever is neede

Re: [Qemu-devel] [PATCH for 2.10] hw/mps2_scc: fix incorrect properties

2017-07-31 Thread Peter Maydell
On 30 July 2017 at 00:49, Philippe Mathieu-Daudé wrote: > Signed-off-by: Philippe Mathieu-Daudé > --- > sorry, I missed them in my review :( > > hw/misc/mps2-scc.c | 4 ++-- > 1 file changed, 2 insertions(+), 2 deletions(-) > > diff --git a/hw/misc/mps2-scc.c b/hw/misc/mps2-scc.c > index cc58d26

Re: [Qemu-devel] [PATCH v3 03/12] qtest: Document calling conventions

2017-07-31 Thread Eric Blake
On 07/31/2017 03:20 AM, Markus Armbruster wrote: >>> It's not "worse", it's just different :) >>> >>> Suggest: >> >> "Mikey likes it" (no idea if that pop culture reference from my >> childhood has broader range than the US) > > 'fraid I'm out of range :) It's not fair of me to leave you hangin

[Qemu-devel] [PULL 6/7] target/arm: Migrate MPU_RNR register state for M profile cores

2017-07-31 Thread Peter Maydell
The PMSAv7 region number register is migrated for R profile cores using the cpreg scheme, but M profile doesn't use cpregs, and so we weren't migrating the MPU_RNR register state at all. Fix that by adding a migration subsection for the M profile case. Signed-off-by: Peter Maydell Reviewed-by: Ph

[Qemu-devel] [PULL 7/7] hw/mps2_scc: fix incorrect properties

2017-07-31 Thread Peter Maydell
From: Philippe Mathieu-Daudé Signed-off-by: Philippe Mathieu-Daudé Message-id: 20170729234930.725-1-f4...@amsat.org Reviewed-by: Peter Maydell Signed-off-by: Peter Maydell --- hw/misc/mps2-scc.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/hw/misc/mps2-scc.c b/hw/mi

[Qemu-devel] [PULL 1/7] target/arm: Correct MPU trace handling of write vs execute

2017-07-31 Thread Peter Maydell
Correct off-by-one bug in the PSMAv7 MPU tracing where it would print a write access as "reading", an insn fetch as "writing", and a read access as "execute". Since we have an MMUAccessType enum now, we can make the code clearer in the process by using that rather than the raw 0/1/2 values. Signe

[Qemu-devel] [PULL 4/7] target/arm: Rename cp15.c6_rgnr to pmsav7.rnr

2017-07-31 Thread Peter Maydell
Almost all of the PMSAv7 state is in the pmsav7 substruct of the ARM CPU state structure. The exception is the region number register, which is in cp15.c6_rgnr. This exception is a bit odd for M profile, which otherwise generally does not store state in the cp15 substruct. Rename cp15.c6_rgnr to p

[Qemu-devel] [PULL 5/7] target/arm: Move PMSAv7 reset into arm_cpu_reset() so M profile MPUs get reset

2017-07-31 Thread Peter Maydell
When the PMSAv7 implementation was originally added it was for R profile CPUs only, and reset was handled using the cpreg .resetfn hooks. Unfortunately for M profile cores this doesn't work, because they do not register any cpregs. Move the reset handling into arm_cpu_reset(), where it will work fo

  1   2   3   >