[Qemu-devel] [PATCH for-2.12] chardev/char-fe: Allow NULL chardev in qemu_chr_fe_init()

2018-03-23 Thread Peter Maydell
All the functions in char-fe.c handle the CharBackend having a NULL Chardev pointer, which means that the backend exists but is not connected to anything. The exception is qemu_chr_fe_init(), which will crash if passed a NULL Chardev pointer argument. This can happen for various boards if they're s

Re: [Qemu-devel] [PATCH] monitor: fix expected qmp_capabilities error description regression

2018-03-23 Thread Peter Xu
On Fri, Mar 23, 2018 at 11:32:39AM +0100, Marc-André Lureau wrote: > Fix regression introduced in commit cf869d53172920536a14180a83292b240e9d0545: > > Before: > {"execute":"foo"} > {"error": {"class": "CommandNotFound", "desc": "Expecting capabilities > negotiation with 'qmp_capabilities'"}} > >

[Qemu-devel] [PATCH v2] vhost: Allow adjoining regions

2018-03-23 Thread Dr. David Alan Gilbert (git)
From: "Dr. David Alan Gilbert" My rework of section adding combines overlapping or adjoining regions, but checks they're actually the same underlying RAM block. Fix the case where two blocks adjoin but don't overlap; that new region should get added (but not combined), but my previous patch was d

Re: [Qemu-devel] [PATCH for-2.12 0/4] Turn OOB off for 2.12-rc1, revert OOB tests

2018-03-23 Thread Eric Blake
On 03/23/2018 09:08 AM, Peter Xu wrote: Temporarily disable OOB for 2.12 since it break (a lot of) things. Luckily it's only a switch so not so hard. Meanwhile, revert all new tests that checks against it. Tests done: all target builds and "make check" passed, but only on x86_64 host. It can pa

Re: [Qemu-devel] [PATCH for-2.12 1/4] Revert "monitor: enable IO thread for (qmp & !mux) typed"

2018-03-23 Thread Eric Blake
On 03/23/2018 09:08 AM, Peter Xu wrote: This reverts commit 3fd2457d18edf5736f713dfe1ada9c87a9badab1. Signed-off-by: Peter Xu Not fatal to taking this patch as-is, but it's always nice to include a rationale when reverting, something along the lines of: It turns out that enabling OOB cause

Re: [Qemu-devel] [PATCH] monitor: fix expected qmp_capabilities error description regression

2018-03-23 Thread Marc-André Lureau
Hi On Fri, Mar 23, 2018 at 4:35 PM, Peter Xu wrote: > On Fri, Mar 23, 2018 at 11:32:39AM +0100, Marc-André Lureau wrote: >> Fix regression introduced in commit cf869d53172920536a14180a83292b240e9d0545: >> >> Before: >> {"execute":"foo"} >> {"error": {"class": "CommandNotFound", "desc": "Expecting

[Qemu-devel] [PATCH PULL 0/8] RDMA queue

2018-03-23 Thread Marcel Apfelbaum
The following changes since commit 4c2c1015905fa1d616750dfe024b4c0b35875950: Merge remote-tracking branch 'remotes/borntraeger/tags/s390x-20180323' into staging (2018-03-23 10:20:54 +) are available in the git repository at: https://github.com/marcel-apf/qemu tags/rdma-pu

[Qemu-devel] [PATCH PULL 6/8] hw/rdma: Change host_virt to void *

2018-03-23 Thread Marcel Apfelbaum
From: Yuval Shaia To avoid compilation warnings on 32-bit machines: rdma_backend.c: In function 'rdma_backend_create_mr': rdma_backend.c:409:37: error: cast to pointer from integer of different size [-Werror=int-to-pointer-cast] mr->ibmr = ibv_reg_mr(pd->ibpd, (void *)addr, length, access

[Qemu-devel] [PATCH PULL 3/8] rdma: fix up include directives

2018-03-23 Thread Marcel Apfelbaum
From: "Michael S. Tsirkin" Our rule right now is to use <> for external headers only. RDMA code violates that, fix it up. Signed-off-by: Michael S. Tsirkin Reviewed-by: Daniel P. Berrangé Reviewed-by: Marcel Apfelbaum Signed-off-by: Marcel Apfelbaum --- hw/rdma/rdma_backend.c| 6 ++

[Qemu-devel] [PATCH PULL 4/8] make: switch from -I to -iquote

2018-03-23 Thread Marcel Apfelbaum
From: "Michael S. Tsirkin" Our rule right now is to use <> for external headers, "" for internal ones. The idea was to avoid conflicts between e.g. a system file named and an internal one by the same name. Unfortunately we use -I compiler flag so it does not help: a system file doing #include

[Qemu-devel] [PATCH PULL 1/8] hw/rdma: Add Query QP operation

2018-03-23 Thread Marcel Apfelbaum
From: Yuval Shaia This operation is needed by rdma devices - implement it. Signed-off-by: Yuval Shaia Reviewed-by: Marcel Apfelbaum Signed-off-by: Marcel Apfelbaum --- hw/rdma/rdma_backend.c | 12 hw/rdma/rdma_backend.h | 2 ++ hw/rdma/rdma_rm.c | 18 ++ hw

[Qemu-devel] [PATCH PULL 7/8] hw/rdma: Use correct print format in CHK_ATTR macro

2018-03-23 Thread Marcel Apfelbaum
From: Yuval Shaia Macro should not cast the given variable to u64 instead it should use the supplied format argument (fmt). Reported-by: Eric Blake Signed-off-by: Yuval Shaia Reviewed-by: Eric Blake Tested-by: Eric Blake Reviewed-by: Philippe Mathieu-Daudé Message-Id: <20180322095220.9976-3

[Qemu-devel] [PATCH PULL 8/8] hw/rdma: Fix 32-bit compilation

2018-03-23 Thread Marcel Apfelbaum
From: Yuval Shaia Use the correct printf formats, so that a 32-bit compile doesn't spit out lots of warnings about %lx being incompatible with uint64_t. Suggested-by: Eric Blake Signed-off-by: Yuval Shaia Reviewed-by: Eric Blake Tested-by: Eric Blake Reviewed-by: Philippe Mathieu-Daudé Mess

Re: [Qemu-devel] [PATCH for-2.12 0/4] Turn OOB off for 2.12-rc1, revert OOB tests

2018-03-23 Thread Eric Blake
On 03/23/2018 10:42 AM, Eric Blake wrote: On 03/23/2018 09:08 AM, Peter Xu wrote: Temporarily disable OOB for 2.12 since it break (a lot of) things. Luckily it's only a switch so not so hard. Meanwhile, revert all new tests that checks against it. Tests done: all target builds and "make check"

[Qemu-devel] [PATCH PULL 2/8] hw/rdma: Add support for Query QP verb to pvrdma device

2018-03-23 Thread Marcel Apfelbaum
From: Yuval Shaia This IB verb is needed by some applications - implement it. Signed-off-by: Yuval Shaia Reviewed-by: Marcel Apfelbaum Signed-off-by: Marcel Apfelbaum --- hw/rdma/vmw/pvrdma_cmd.c | 24 +++- 1 file changed, 23 insertions(+), 1 deletion(-) diff --git a/hw/

[Qemu-devel] [PATCH PULL 5/8] hw/rdma: fix clang compilation errors

2018-03-23 Thread Marcel Apfelbaum
Fix some enum castings and extra parentheses. Reported-by: Michael S. Tsirkin Signed-off-by: Marcel Apfelbaum Message-Id: <20180321140316.96045-1-mar...@redhat.com> Reviewed-by: Yuval Shaia --- hw/rdma/vmw/pvrdma_cmd.c | 5 +++-- hw/rdma/vmw/pvrdma_main.c | 4 ++-- 2 files changed, 5 insertio

Re: [Qemu-devel] [Consult] nfs-vsocks support

2018-03-23 Thread Stefan Hajnoczi
On Fri, Mar 23, 2018 at 05:54:53PM +0800, Liu, Jing2 wrote: > I am currently trying to use nfs-vsocks on x86 for vitural machine > filesystem by some manuals on > https://www.spinics.net/lists/linux-nfs/msg64563.html > and https://lwn.net/Articles/647516/ > > It tells the quickstart steps with the

Re: [Qemu-devel] [PATCH for-2.12] chardev/char-fe: Allow NULL chardev in qemu_chr_fe_init()

2018-03-23 Thread Thomas Huth
On 23.03.2018 16:29, Peter Maydell wrote: > All the functions in char-fe.c handle the CharBackend > having a NULL Chardev pointer, which means that the > backend exists but is not connected to anything. The > exception is qemu_chr_fe_init(), which will crash if > passed a NULL Chardev pointer argum

Re: [Qemu-devel] [PATCH v8 14/23] monitor: separate QMP parser and dispatcher

2018-03-23 Thread Marc-André Lureau
On Fri, Mar 9, 2018 at 9:59 AM, Peter Xu wrote: > Originally QMP goes through these steps: > > JSON Parser --> QMP Dispatcher --> Respond > /|\(2)(3) | >(1) | \|/ (4) >+- main thread + > > This patch does t

Re: [Qemu-devel] [PATCH for-2.12 REPOST] migration: convert socket server to QIONetListener

2018-03-23 Thread Dr. David Alan Gilbert
* Daniel P. Berrangé (berra...@redhat.com) wrote: > From: "Daniel P. Berrange" > > Instead of creating a QIOChannelSocket directly for the migration > server socket, use a QIONetListener. This provides the ability > to listen on multiple sockets at the same time, so enables > full support for IPv

[Qemu-devel] [Bug 1740219] Re: static linux-user ARM emulation has several-second startup time

2018-03-23 Thread LukeShu
I don't believe so. The patchset applies cleanly on 2.11.0, and fixes the issue there. -- You received this bug notification because you are a member of qemu- devel-ml, which is subscribed to QEMU. https://bugs.launchpad.net/bugs/1740219 Title: static linux-user ARM emulation has several-seco

Re: [Qemu-devel] [PATCH] migration: Fix rate limiting issue on RDMA migration

2018-03-23 Thread Dr. David Alan Gilbert
* Lidong Chen (jemmy858...@gmail.com) wrote: > RDMA migration implement save_page function for QEMUFile, but > ram_control_save_page do not increase bytes_xfer. So when doing > RDMA migration, it will use whole bandwidth. > > Signed-off-by: Lidong Chen Queued > --- > migration/qemu-file.c | 2

[Qemu-devel] [Bug 1740219] Re: static linux-user ARM emulation has several-second startup time

2018-03-23 Thread LukeShu
Oh, but it's worth noting that patch 1/10 had a mistake in it, which was corrected when applied as 8756e1361d177e91dc6d88f37749b809fd2407fb. -- You received this bug notification because you are a member of qemu- devel-ml, which is subscribed to QEMU. https://bugs.launchpad.net/bugs/1740219 Titl

[Qemu-devel] [PATCH] block: simplify code around releasing bitmaps

2018-03-23 Thread Paolo Bonzini
QLIST_REMOVE does not require walking the list, and once the "bitmap" argument is removed from bdrv_do_release_matching_dirty_bitmap_locked the code simplifies a lot and it is worth inlining everything in the callers of bdrv_do_release_matching_dirty_bitmap. Signed-off-by: Paolo Bonzini --- bloc

[Qemu-devel] [PATCH] block: remove bdrv_dirty_bitmap_make_anon

2018-03-23 Thread Paolo Bonzini
All this function is doing will be repeated by bdrv_do_release_matching_dirty_bitmap_locked, except resetting bm->persistent. But even that does not matter because the bitmap will be freed. Signed-off-by: Paolo Bonzini --- block/dirty-bitmap.c | 9 - blockdev.c

Re: [Qemu-devel] [PATCH for-2.12] chardev/char-fe: Allow NULL chardev in qemu_chr_fe_init()

2018-03-23 Thread Paolo Bonzini
On 23/03/2018 16:29, Peter Maydell wrote: > All the functions in char-fe.c handle the CharBackend > having a NULL Chardev pointer, which means that the > backend exists but is not connected to anything. The > exception is qemu_chr_fe_init(), which will crash if > passed a NULL Chardev pointer argum

Re: [Qemu-devel] [PATCH 4/5] migration/block: limit the number of parallel I/O requests

2018-03-23 Thread Dr. David Alan Gilbert
* Peter Lieven (p...@kamp.de) wrote: > the current implementation submits up to 512 I/O requests in parallel > which is much to high especially for a background task. > This patch adds a maximum limit of 16 I/O requests that can > be submitted in parallel to avoid monopolizing the I/O device. > >

Re: [Qemu-devel] [PATCH for 2.13 1/5] linux-user: cleanup signal.c

2018-03-23 Thread Laurent Vivier
Le 23/03/2018 à 15:22, Peter Maydell a écrit : > On 22 March 2018 at 21:58, Laurent Vivier wrote: >> move all target specific parts to >> signal.inc.c in arch directory >> >> Signed-off-by: Laurent Vivier >> --- >> linux-user/aarch64/signal.inc.c| 556 +++ >> linux-user/alpha/signal.inc.c

Re: [Qemu-devel] [PATCH v2 2/5] error: Strip trailing '\n' from error string arguments (again again)

2018-03-23 Thread Eric Blake
On 03/23/2018 09:31 AM, Laurent Vivier wrote: Re-run Coccinelle script scripts/coccinelle/err-bad-newline.cocci, and found new error_report() occurences with '\n'. s/occurences/occurrences/ Signed-off-by: Laurent Vivier --- target/i386/hvf/hvf.c | 24 1 file chan

Re: [Qemu-devel] [PATCH for 2.13 1/5] linux-user: cleanup signal.c

2018-03-23 Thread Peter Maydell
On 23 March 2018 at 16:51, Laurent Vivier wrote: > Le 23/03/2018 à 15:22, Peter Maydell a écrit : >> On 22 March 2018 at 21:58, Laurent Vivier wrote: >>> move all target specific parts to >>> signal.inc.c in arch directory >>> >>> Signed-off-by: Laurent Vivier >>> --- >>> linux-user/aarch64/sig

Re: [Qemu-devel] [PATCH v2 0/7] ramfb: simple boot framebuffer, no legacy vga

2018-03-23 Thread Gerd Hoffmann
On Fri, Mar 23, 2018 at 04:12:21PM +0100, Laszlo Ersek wrote: > On 03/23/18 15:51, Gerd Hoffmann wrote: > > Hi, > > > >> I believe the only point of this device model (and the associated guest > >> fw driver) is Windows-on-KVM/aarch64. > > > > The other one is vgpu boot display. > > Interestin

[Qemu-devel] [Bug 1191326] Re: QNX 4 doesn't boot on qemu >= 1.3

2018-03-23 Thread Lukas Jirkovsky
This is still a problem with QEMU 2.11. Note that the problem in #10 is unrelated to the issue (though GUI works for with the the demo floppy). The problem mentioned in this bug is related to a QNX that is already installed to a disk. Unfortunately the QNX demo floppy that was once free and which

Re: [Qemu-devel] [PATCH v3 0/2] linux-headers: unistd.h fixups

2018-03-23 Thread Dr. David Alan Gilbert
* Michael S. Tsirkin (m...@redhat.com) wrote: > It turns out that we have unistd.h for some architectures but not > others. We are thus unable to use e.g. usefaultfd on these systems. > > Fix up update-linux-headers.sh to make sure we > get it for all architectures which have linux-headers/ > (un

Re: [Qemu-devel] [PATCH for-2.12 0/4] Turn OOB off for 2.12-rc1, revert OOB tests

2018-03-23 Thread Eric Blake
On 03/23/2018 10:53 AM, Eric Blake wrote: Actually, we should revert things in reverse order of the original commits, so that we aren't introducing yet more temporary breakage. Since you reverted: $ git describe 3fd2457 d003f7a 91ad450 0213031 --match=v\* v2.11.0-2595-g3fd2457d18e v2.11.0-259

Re: [Qemu-devel] [PATCH] target/xtensa: fix timers test

2018-03-23 Thread Philippe Mathieu-Daudé
Hi Max, On 03/23/2018 10:17 AM, Max Filippov wrote: > Change frequency of the core used in tests so that clock cycle takes > exactly 64ns. Change icount power used in tests to 6, so that each > instruction takes exactly 1 clock cycle. With these changes the > assumptions of the xtensa timers test

[Qemu-devel] [PULL 1/4] Revert "tests: qmp-test: add oob test"

2018-03-23 Thread Eric Blake
From: Peter Xu This reverts commit d003f7a8f9cafe50119975844fa01afc2baf41fb. Enabling OOB caused several iotests failures; due to the imminent 2.12 release, the safest action is to disable OOB, but first we have to revert tests that rely on OOB. Signed-off-by: Peter Xu Message-Id: <20180323140

[Qemu-devel] [PULL 0/4] QAPI patches for 2018-03-23, for 2.12-rc1

2018-03-23 Thread Eric Blake
The following changes since commit 4c2c1015905fa1d616750dfe024b4c0b35875950: Merge remote-tracking branch 'remotes/borntraeger/tags/s390x-20180323' into staging (2018-03-23 10:20:54 +) are available in the Git repository at: git://repo.or.cz/qemu/ericb.git tags/pull-qapi-

[Qemu-devel] [PULL 2/4] Revert "tests: qmp-test: verify command batching"

2018-03-23 Thread Eric Blake
From: Peter Xu This reverts commit 91ad45061af0fe44ac5dadb5bedaf4d7a08077c8. Enabling OOB caused several iotests failures; due to the imminent 2.12 release, the safest action is to disable OOB, but first we have to revert tests that rely on OOB. Signed-off-by: Peter Xu Message-Id: <20180323140

[Qemu-devel] [PULL 4/4] qapi: Force UTF8 encoding when parsing qapi files

2018-03-23 Thread Eric Blake
Commit d4e5ec877 already fixed things to work around Python 3's lame bug of having LC_ALL=C not be 8-bit clean, when parsing the main QMP qapi files; but failed to do likewise in the tests directory. As a result, running 'LC_ALL=C make check' fails on escape-too-big and unicode-str when using pyth

[Qemu-devel] [PULL 3/4] Revert "monitor: enable IO thread for (qmp & !mux) typed"

2018-03-23 Thread Eric Blake
From: Peter Xu This reverts commit 3fd2457d18edf5736f713dfe1ada9c87a9badab1. Enabling OOB caused several iotests failures; due to the imminent 2.12 release, the safest action is to disable OOB for now. If other patches fix the issues that iotests exposed, it may be turned back on in time for th

Re: [Qemu-devel] [PATCH v4 1/3] update-linux-headers.sh: add unistd.h and kvm on MIPS

2018-03-23 Thread Dr. David Alan Gilbert
* Michael S. Tsirkin (m...@redhat.com) wrote: > Rework the update script slightly, add the unistd.h header and its > dependencies on all architectures. > > This also removes the IA64 and MIPS from a KVM blacklist: > Linux dropped IA64, and there was never a reason to > exclude MIPS from kvm specif

Re: [Qemu-devel] [PATCH 0/4] coccinelle: re-run scripts from scripts/coccinelle

2018-03-23 Thread Eric Blake
On 03/23/2018 07:37 AM, Michael Tokarev wrote: 22.03.2018 19:12, Laurent Vivier wrote: I've re-run some scripts from the coccinelle directory, and they have found some problems. This series fixes them. Laurent Vivier (4): error: Strip trailing '\n' from error string arguments (again again)

Re: [Qemu-devel] [PATCH v2 0/5] coccinelle: re-run scripts from scripts/coccinelle

2018-03-23 Thread Eric Blake
On 03/23/2018 09:31 AM, Laurent Vivier wrote: I've re-run some scripts from the coccinelle directory, and they have found some problems. This series fixes them. v2: only change PATCH 4/4 - keep comments - fix indentation I didn't remove changes in autogenerated files as it seems the

Re: [Qemu-devel] [PATCH for-2.12 0/4] Fix crashes with CAN bus and ISA DMA devices

2018-03-23 Thread John Snow
On 03/16/2018 06:15 AM, Paolo Bonzini wrote: > On 16/03/2018 10:51, Thomas Huth wrote: >> The new CAN bus devices and some older ISA devices that use DMA can be >> used to crash QEMU. These patches introduce some proper checks so that >> the users get a proper error message instead. >> >> Alexey

Re: [Qemu-devel] [PATCH v2 0/7] ramfb: simple boot framebuffer, no legacy vga

2018-03-23 Thread Laszlo Ersek
On 03/23/18 18:07, Gerd Hoffmann wrote: > On Fri, Mar 23, 2018 at 04:12:21PM +0100, Laszlo Ersek wrote: >> On 03/23/18 15:51, Gerd Hoffmann wrote: >>> Hi, >>> I believe the only point of this device model (and the associated guest fw driver) is Windows-on-KVM/aarch64. >>> >>> The other

Re: [Qemu-devel] [PATCH for-2.12 0/4] Turn OOB off for 2.12-rc1, revert OOB tests

2018-03-23 Thread Christian Borntraeger
On 03/23/2018 06:17 PM, Eric Blake wrote: > On 03/23/2018 10:53 AM, Eric Blake wrote: > >> Actually, we should revert things in reverse order of the original commits, >> so that we aren't introducing yet more temporary breakage. >> >> Since you reverted: >> >> $ git describe 3fd2457 d003f7a 91a

Re: [Qemu-devel] [PATCH for-2.12 0/4] Turn OOB off for 2.12-rc1, revert OOB tests

2018-03-23 Thread Eric Blake
On 03/23/2018 01:30 PM, Christian Borntraeger wrote: Even that didn't work - 'make check' fails with either 1/4 or 4/4 applied in isolation, so I'm squashing them into a single patch. Yes, "qmp: introduce QMPCapability" added an assert, that was fixed by a later on patch. So the original ser

Re: [Qemu-devel] [PULL 11/26] pci-bridge/i82801b11: clear bridge registers on platform reset

2018-03-23 Thread Laszlo Ersek
Michael, Peter, On 02/08/18 20:09, Michael S. Tsirkin wrote: > From: Laszlo Ersek > > The "i82801b11-bridge" device model is a descendant of "base-pci-bridge" > (TYPE_PCI_BRIDGE). However, unlike other similar devices, such as > > - pci-bridge, > - pcie-pci-bridge, > - PCIE Root Port, > - xio31

[Qemu-devel] [PULL 04/10] hw/arm/bcm2836: Use the Cortex-A7 instead of Cortex-A15

2018-03-23 Thread Peter Maydell
The BCM2836 uses a Cortex-A7, not a Cortex-A15. Update the device to use the correct CPU. https://www.raspberrypi.org/documentation/hardware/raspberrypi/bcm2836/QA7_rev3.4.pdf When the BCM2836 was introduced (bad5623690b) the Cortex-A7 was not available, so the very similar Cortex-A15 was used. Si

[Qemu-devel] [PULL 02/10] sdhci: fix incorrect use of Error *

2018-03-23 Thread Peter Maydell
From: Paolo Bonzini Detected by Coverity (CID 1386072, 1386073, 1386076, 1386077). local_err was unused, and this made the static analyzer unhappy. Signed-off-by: Paolo Bonzini Message-id: 20180320151355.25854-1-pbonz...@redhat.com Reviewed-by: Peter Maydell Signed-off-by: Peter Maydell ---

[Qemu-devel] [PULL 00/10] target-arm queue

2018-03-23 Thread Peter Maydell
Ten arm-related bug fixes for 2.12... thanks -- PMM The following changes since commit 4c2c1015905fa1d616750dfe024b4c0b35875950: Merge remote-tracking branch 'remotes/borntraeger/tags/s390x-20180323' into staging (2018-03-23 10:20:54 +) are available in the Git repository

[Qemu-devel] [PULL 06/10] mach-virt: Set VM's SMBIOS system version to mc->name

2018-03-23 Thread Peter Maydell
From: Wei Huang Instead of using "1.0" as the system version of SMBIOS, we should use mc->name for mach-virt machine type to be consistent other architectures. With this patch, "dmidecode -t 1" (e.g., "-M virt-2.12,accel=kvm") will show: Handle 0x0100, DMI type 1, 27 bytes System Informa

[Qemu-devel] [PULL 05/10] i.MX: Support serial RS-232 break properly

2018-03-23 Thread Peter Maydell
From: Trent Piepho Linux does not detect a break from this IMX serial driver as a magic sysrq. Nor does it note a break in the port error counts. The former is because the Linux driver uses the BRCD bit in the USR2 register to trigger the RS-232 break handler in the kernel, which is where sysrq

[Qemu-devel] [PULL 01/10] arm/translate-a64: treat DISAS_UPDATE as variant of DISAS_EXIT

2018-03-23 Thread Peter Maydell
From: Victor Kamensky In OE project 4.15 linux kernel boot hang was observed under single cpu aarch64 qemu. Kernel code was in a loop waiting for vtimer arrival, spinning in TC generated blocks, while interrupt was pending unprocessed. This happened because when qemu tried to handle vtimer interr

[Qemu-devel] [PULL 03/10] hw/intc/arm_gicv3: Fix secure-GIC NS ICC_PMR and ICC_RPR accesses

2018-03-23 Thread Peter Maydell
If the GIC has the security extension support enabled, then a non-secure access to ICC_PMR must take account of the non-secure view of interrupt priorities, where real priorities 0x00..0x7f are secure-only and not visible to the non-secure guest, and priorities 0x80..0xff are shown to the guest as

[Qemu-devel] [PULL 07/10] target/arm: Honour MDCR_EL2.TDE when routing exceptions due to BKPT/BRK

2018-03-23 Thread Peter Maydell
The MDCR_EL2.TDE bit allows the exception level targeted by debug exceptions to be set to EL2 for code executing at EL0. We handle this in the arm_debug_target_el() function, but this is only used for hardware breakpoint and watchpoint exceptions, not for the exception generated when the guest exe

[Qemu-devel] [PULL 09/10] target/arm: Set FSR for BKPT, BRK when raising exception

2018-03-23 Thread Peter Maydell
Now that we have a helper function specifically for the BRK and BKPT instructions, we can set the exception.fsr there rather than in arm_cpu_do_interrupt_aarch32(). This allows us to use our new arm_debug_exception_fsr() helper. In particular this fixes a bug where we were hardcoding the short-for

[Qemu-devel] [PULL 08/10] target/arm: Factor out code to calculate FSR for debug exceptions

2018-03-23 Thread Peter Maydell
When a debug exception is taken to AArch32, it appears as a Prefetch Abort, and the Instruction Fault Status Register (IFSR) must be set. The IFSR has two possible formats, depending on whether LPAE is in use. Factor out the code in arm_debug_excp_handler() which picks an FSR value into its own uti

[Qemu-devel] [PULL 10/10] target/arm: Always set FAR to a known unknown value for debug exceptions

2018-03-23 Thread Peter Maydell
For debug exceptions due to breakpoints or the BKPT instruction which are taken to AArch32, the Fault Address Register is architecturally UNKNOWN. We were using that as license to simply not set env->exception.vaddress, but this isn't correct, because it will expose to the guest whatever old value

[Qemu-devel] [Bug 1673976] Re: linux-user clone() can't handle glibc posix_spawn() (causes locale-gen to assert)

2018-03-23 Thread Éric Hoffman
Hello Sorry for the delay... Actually, you only need the parent to get the status from the child, which can be passed in other way than through common memory. The idea is to use pipefd to actually wait for the child to either terminate or successfully call execve. As follow: When the TARGET_N

Re: [Qemu-devel] [Qemu-ppc] [PATCH v2 3/5] error: Remove NULL checks on error_propagate() calls

2018-03-23 Thread Thomas Huth
On 23.03.2018 15:32, Laurent Vivier wrote: > Re-run Coccinelle patch > scripts/coccinelle/error_propagate_null.cocci > > Signed-off-by: Laurent Vivier > --- > io/channel-websock.c | 4 +--- > 1 file changed, 1 insertion(+), 3 deletions(-) > > diff --git a/io/channel-websock.c b/io/channel-webso

[Qemu-devel] [Bug 1673976] Re: linux-user clone() can't handle glibc posix_spawn() (causes locale-gen to assert)

2018-03-23 Thread Peter Maydell
> Actually, you only need the parent to get the status from the child, which can be passed in other way than through common memory. Certainly, it *can* be, but the glibc code we're trying to run in the guest here doesn't do it in some other way, it uses common memory. Having QEMU effectively pause

Re: [Qemu-devel] [PATCH for-2.12 1/2] i386/hyperv: add hv-frequencies cpu property

2018-03-23 Thread Eduardo Habkost
On Fri, Mar 23, 2018 at 03:58:07PM +0300, Roman Kagan wrote: > In order to guarantee compatibility on migration, QEMU should have > complete control over the features it announces to the guest via CPUID. > > However, the declared availability of Hyper-V frequency MSRs > (HV_X64_MSR_TSC_FREQUENCY a

Re: [Qemu-devel] [PATCH v3 2/2] i386/kvm: lower requirements for Hyper-V frequency MSRs exposure

2018-03-23 Thread Eduardo Habkost
On Fri, Mar 23, 2018 at 12:45:30PM +0300, Roman Kagan wrote: > On Thu, Mar 22, 2018 at 03:38:13PM -0300, Eduardo Habkost wrote: > > On Thu, Mar 22, 2018 at 04:58:03PM +0300, Roman Kagan wrote: > > > On Thu, Mar 22, 2018 at 10:22:18AM -0300, Eduardo Habkost wrote: > > > > On Thu, Mar 22, 2018 at 04:

Re: [Qemu-devel] [PATCH for-2.12 2/2] i386/hyperv: error out if features requested but unsupported

2018-03-23 Thread Eduardo Habkost
On Fri, Mar 23, 2018 at 03:58:08PM +0300, Roman Kagan wrote: > In order to guarantee compatibility on migration, QEMU should have > complete control over the features it announces to the guest via CPUID. > > However, for a number of Hyper-V-related cpu properties, if the > corresponding feature is

Re: [Qemu-devel] [PATCH v3] RISC-V: Fix riscv_isa_string memory size bug

2018-03-23 Thread Palmer Dabbelt
On Thu, 22 Mar 2018 15:17:16 PDT (-0700), d...@redhat.com wrote: "Richard W.M. Jones" writes: DJ, am I remembering correctly that you tried the test case on the HiFive evaluation board and it didn't demonstrate the bug? I tested it on the vc707 board, without seeing the bug. FWIW, the cores

Re: [Qemu-devel] [RFC PATCH 0/5] atapi: change unlimited recursion to while loop

2018-03-23 Thread John Snow
On 02/23/2018 10:26 AM, Paolo Bonzini wrote: > Real hardware doesn't have an unlimited stack, so the unlimited > recursion in the ATAPI code smells a bit. In fact, the call to > ide_transfer_start easily becomes a tail call with a small change > to the code (patch 4). The remaining four patches

Re: [Qemu-devel] [PATCH v5.2 for 2.13 3/4] docs: tpm: add VM save/restore example and troubleshooting guide

2018-03-23 Thread Dr. David Alan Gilbert
* Stefan Berger (stef...@linux.vnet.ibm.com) wrote: > On 03/21/2018 02:42 PM, Dr. David Alan Gilbert wrote: > > * Stefan Berger (stef...@linux.vnet.ibm.com) wrote: > > > Extend the docs related to TPM with specs related to VM save and > > > restore and a troubleshooting guide for TPM migration. > >

Re: [Qemu-devel] [Qemu-block] [RFC PATCH 0/5] atapi: change unlimited recursion to while loop

2018-03-23 Thread Paolo Bonzini
On 23/03/2018 21:08, John Snow wrote: > > > On 02/23/2018 10:26 AM, Paolo Bonzini wrote: >> Real hardware doesn't have an unlimited stack, so the unlimited >> recursion in the ATAPI code smells a bit. In fact, the call to >> ide_transfer_start easily becomes a tail call with a small change >> to

Re: [Qemu-devel] [PATCH] i386/kvm: add support for KVM_CAP_X86_DISABLE_EXITS

2018-03-23 Thread Eduardo Habkost
On Fri, Mar 16, 2018 at 07:36:42AM -0700, Wanpeng Li wrote: > From: Wanpeng Li > > This patch adds support for KVM_CAP_X86_DISABLE_EXITS. Provides userspace > with > per-VM capability(KVM_CAP_X86_DISABLE_EXITS) to not intercept MWAIT/HLT/PAUSE > in order that to improve latency in some workloa

[Qemu-devel] [PULL 0/5] migration queue

2018-03-23 Thread Dr. David Alan Gilbert (git)
From: "Dr. David Alan Gilbert" The following changes since commit 4c2c1015905fa1d616750dfe024b4c0b35875950: Merge remote-tracking branch 'remotes/borntraeger/tags/s390x-20180323' into staging (2018-03-23 10:20:54 +) are available in the Git repository at: gi

[Qemu-devel] [PULL 2/5] migration: Fix rate limiting issue on RDMA migration

2018-03-23 Thread Dr. David Alan Gilbert (git)
From: Lidong Chen RDMA migration implement save_page function for QEMUFile, but ram_control_save_page do not increase bytes_xfer. So when doing RDMA migration, it will use whole bandwidth. Signed-off-by: Lidong Chen Message-Id: <1520692378-1835-1-git-send-email-lidongc...@tencent.com> Reviewed-

[Qemu-devel] [PULL 3/5] migration/block: limit the number of parallel I/O requests

2018-03-23 Thread Dr. David Alan Gilbert (git)
From: Peter Lieven the current implementation submits up to 512 I/O requests in parallel which is much to high especially for a background task. This patch adds a maximum limit of 16 I/O requests that can be submitted in parallel to avoid monopolizing the I/O device. Signed-off-by: Peter Lieven

[Qemu-devel] [PULL 1/5] migration: convert socket server to QIONetListener

2018-03-23 Thread Dr. David Alan Gilbert (git)
From: "Daniel P. Berrange" Instead of creating a QIOChannelSocket directly for the migration server socket, use a QIONetListener. This provides the ability to listen on multiple sockets at the same time, so enables full support for IPv4/IPv6 dual stack. For example, '$QEMU -incoming tcp::9000'

Re: [Qemu-devel] [Qemu-block] [RFC PATCH 0/5] atapi: change unlimited recursion to while loop

2018-03-23 Thread John Snow
On 03/23/2018 04:17 PM, Paolo Bonzini wrote: > On 23/03/2018 21:08, John Snow wrote: >> >> >> On 02/23/2018 10:26 AM, Paolo Bonzini wrote: >>> Real hardware doesn't have an unlimited stack, so the unlimited >>> recursion in the ATAPI code smells a bit. In fact, the call to >>> ide_transfer_start

[Qemu-devel] [PULL 4/5] migration/block: compare only read blocks against the rate limiter

2018-03-23 Thread Dr. David Alan Gilbert (git)
From: Peter Lieven only read_done blocks are in the queued to be flushed to the migration stream. submitted blocks are still in flight. Signed-off-by: Peter Lieven Message-Id: <1520507908-16743-6-git-send-email...@kamp.de> Reviewed-by: Juan Quintela Signed-off-by: Dr. David Alan Gilbert ---

[Qemu-devel] [PULL 5/5] migration: Fix block migration flag case

2018-03-23 Thread Dr. David Alan Gilbert (git)
From: "Dr. David Alan Gilbert" Fix the case where when a migration with a bad protocol is tried, we leave the block migration capability set. (This is a cut down version of my 'migration: Fix block failure cases' where it's other case was fixed by Peter's dd0ee30caeebbd ) Signed-off-by: Dr. Dav

Re: [Qemu-devel] [PATCH v4 1/9] numa: postpone options post-processing till machine_run_board_init()

2018-03-23 Thread Eduardo Habkost
On Mon, Mar 12, 2018 at 02:11:07PM +0100, Igor Mammedov wrote: > in preparation for numa options to being handled via QMP before > machine_run_board_init(), move final numa configuration checks > and processing to machine_run_board_init() so it could take into > account both CLI (via parse_numa_opt

Re: [Qemu-devel] [PATCH v4 2/9] numa: split out NumaOptions parsing into parse_NumaOptions()

2018-03-23 Thread Eduardo Habkost
On Mon, Mar 12, 2018 at 02:11:08PM +0100, Igor Mammedov wrote: > it will allow to reuse parse_NumaOptions() for parsing > configuration commands received via QMP interface > > Signed-off-by: Igor Mammedov > --- > include/sysemu/numa.h | 1 + > numa.c| 48

[Qemu-devel] [PATCH for-2.12] tests: Silence false positive warning on generated test name

2018-03-23 Thread Eric Blake
Running 'make check' on rawhide with gcc 8.0.1 fails: tests/test-visitor-serialization.c: In function 'main': tests/test-visitor-serialization.c:1127:34: error: '/primitives/' directive writing 12 bytes into a region of size between 1 and 128 [-Werror=format-overflow=] The warning is a false po

Re: [Qemu-devel] [PATCH v4 2/9] numa: split out NumaOptions parsing into parse_NumaOptions()

2018-03-23 Thread Eric Blake
On 03/23/2018 03:42 PM, Eduardo Habkost wrote: On Mon, Mar 12, 2018 at 02:11:08PM +0100, Igor Mammedov wrote: it will allow to reuse parse_NumaOptions() for parsing configuration commands received via QMP interface Signed-off-by: Igor Mammedov --- end: +if (err) { +error_propa

Re: [Qemu-devel] [PATCH 2/4] error: Remove NULL checks on error_propagate() calls

2018-03-23 Thread Eric Blake
On 03/22/2018 11:12 AM, Laurent Vivier wrote: Re-run Coccinelle patch scripts/coccinelle/error_propagate_null.cocci Signed-off-by: Laurent Vivier --- io/channel-websock.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) Misses an offender in numa.c, why? https://lists.gnu.org/arc

Re: [Qemu-devel] [PATCH v4 3/9] cli: add -preconfig option

2018-03-23 Thread Eric Blake
On 03/12/2018 08:11 AM, Igor Mammedov wrote: I know you wrote this before softfreeze, but I'm only just now getting a chance to review. ...[1] This option allows pausing QEMU in the new RUN_STATE_PRECONFIG state, allowing the configuration of QEMU from QMP before the machine jumps into board

Re: [Qemu-devel] [PATCH v4 3/9] cli: add -preconfig option

2018-03-23 Thread Eduardo Habkost
On Mon, Mar 12, 2018 at 02:11:09PM +0100, Igor Mammedov wrote: > This option allows pausing QEMU in the new RUN_STATE_PRECONFIG state, > allowing the configuration of QEMU from QMP before the machine jumps > into board initialization code of machine_run_board_init() > > Intent is to allow manageme

Re: [Qemu-devel] [PATCH v4 2/9] numa: split out NumaOptions parsing into parse_NumaOptions()

2018-03-23 Thread Eduardo Habkost
On Fri, Mar 23, 2018 at 03:49:38PM -0500, Eric Blake wrote: > On 03/23/2018 03:42 PM, Eduardo Habkost wrote: > > On Mon, Mar 12, 2018 at 02:11:08PM +0100, Igor Mammedov wrote: > > > it will allow to reuse parse_NumaOptions() for parsing > > > configuration commands received via QMP interface > > >

[Qemu-devel] [Bug 1754372] Re: Set MIPS MSA in ELF Auxiliary Vectors

2018-03-23 Thread philmd
** Tags added: mips -- You received this bug notification because you are a member of qemu- devel-ml, which is subscribed to QEMU. https://bugs.launchpad.net/bugs/1754372 Title: Set MIPS MSA in ELF Auxiliary Vectors Status in QEMU: In Progress Bug description: The MIPS MSA feature is cur

Re: [Qemu-devel] [PATCH v4 5/9] qapi: introduce new cmd option "allowed-in-preconfig"

2018-03-23 Thread Eric Blake
On 03/12/2018 08:11 AM, Igor Mammedov wrote: New option will be used to allow commands, which are prepared/need to run run in preconfig state. Other commands that should be able s/run run in/run, during/ to run in preconfig state, should be ammeded to not expect machine s/ammeded/amended/

[Qemu-devel] [Bug 1663287] Re: Illegal delay slot code causes abort on mips64

2018-03-23 Thread philmd
** Tags added: mips -- You received this bug notification because you are a member of qemu- devel-ml, which is subscribed to QEMU. https://bugs.launchpad.net/bugs/1663287 Title: Illegal delay slot code causes abort on mips64 Status in QEMU: New Bug description: During some randomised tes

Re: [Qemu-devel] [PATCH v4 3/9] cli: add -preconfig option

2018-03-23 Thread Eduardo Habkost
On Mon, Mar 12, 2018 at 02:11:09PM +0100, Igor Mammedov wrote: > This option allows pausing QEMU in the new RUN_STATE_PRECONFIG state, > allowing the configuration of QEMU from QMP before the machine jumps > into board initialization code of machine_run_board_init() > > Intent is to allow manageme

Re: [Qemu-devel] [PATCH v4 4/9] hmp: disable monitor in preconfig state

2018-03-23 Thread Eduardo Habkost
On Mon, Mar 12, 2018 at 02:11:10PM +0100, Igor Mammedov wrote: > Ban it for now, if someone would need it to work early, > one would have to implement checks if HMP command is valid > at preconfig state. > > Signed-off-by: Igor Mammedov > --- > v4: > * v3 was only printing error but not prevent

Re: [Qemu-devel] [PATCH v4 5/9] qapi: introduce new cmd option "allowed-in-preconfig"

2018-03-23 Thread Eduardo Habkost
On Mon, Mar 12, 2018 at 02:11:11PM +0100, Igor Mammedov wrote: > New option will be used to allow commands, which are prepared/need > to run run in preconfig state. Other commands that should be able > to run in preconfig state, should be ammeded to not expect machine > in initialized state or deal

[Qemu-devel] [PATCH v2] target-arm: Check undefined opcodes for SWP in A32 decoder

2018-03-23 Thread Onur Sahin
Thanks for the feedback Peter. Removing the redundant check on bit 23 and adding checks for the "should be" bits as well (bits [11:8]). The following patch should make sure we are not treating architecturally Undefined instructions as a SWP, by verifying the opcodes as per section A8.8.229 of ARMv

Re: [Qemu-devel] [PATCH for-2.12 v2 03/12] qemu-iotests: Test vdi image creation with QMP

2018-03-23 Thread Eric Blake
On 03/21/2018 12:37 PM, Kevin Wolf wrote: Signed-off-by: Kevin Wolf --- tests/qemu-iotests/211 | 246 + tests/qemu-iotests/211.out | 97 ++ tests/qemu-iotests/group | 1 + 3 files changed, 344 insertions(+) create mode 1

Re: [Qemu-devel] [PATCH for-2.12 0/2] i386/hyperv: fully control Hyper-V features in CPUID

2018-03-23 Thread no-reply
Hi, This series seems to have some coding style problems. See output below for more information: Type: series Message-id: 20180323125808.4479-1-rka...@virtuozzo.com Subject: [Qemu-devel] [PATCH for-2.12 0/2] i386/hyperv: fully control Hyper-V features in CPUID === TEST SCRIPT BEGIN === #!/bin/b

Re: [Qemu-devel] [PATCH for-2.12 v2 06/12] qemu-iotests: Test invalid resize on luks

2018-03-23 Thread Eric Blake
On 03/21/2018 12:37 PM, Kevin Wolf wrote: This tests that the .bdrv_truncate implementation for luks doesn't crash for invalid image sizes. Signed-off-by: Kevin Wolf --- tests/qemu-iotests/210 | 37 + tests/qemu-iotests/210.out | 16

Re: [Qemu-devel] [PATCH] monitor: fix expected qmp_capabilities error description regression

2018-03-23 Thread Eric Blake
On 03/23/2018 10:50 AM, Marc-André Lureau wrote: If we are going to remove below chunk, how about do it in prettier way instead of hacking around the error again? Like: diff --git a/monitor.c b/monitor.c index 77f4c41cfa..849fa23bf9 100644 --- a/monitor.c +++ b/monitor.c @@ -1203,8 +1203,14 @@

Re: [Qemu-devel] raw iotest regressions in 2.12.0-rc0

2018-03-23 Thread Eric Blake
On 03/22/2018 08:54 AM, Peter Xu wrote: On Wed, Mar 21, 2018 at 05:58:48PM -0400, John Snow wrote: ./check -v -raw Failures: 109 132 136 148 152 183 ./check -v raw Failures: 055 Failed 5 of 5 tests Maybe these are known, but I wanted to consolidate them for rc0 for something easy to sea

Re: [Qemu-devel] [PATCH v2 0/5] coccinelle: re-run scripts from scripts/coccinelle

2018-03-23 Thread Laurent Vivier
On 23/03/2018 18:47, Eric Blake wrote: > On 03/23/2018 09:31 AM, Laurent Vivier wrote: >> I've re-run some scripts from the coccinelle directory, >> and they have found some problems. >> >> This series fixes them. >> >> v2: only change PATCH 4/4 >>    - keep comments >>    - fix indentation >>    I

Re: [Qemu-devel] [PULL 00/10] target-arm queue

2018-03-23 Thread no-reply
Hi, This series seems to have some coding style problems. See output below for more information: Type: series Message-id: 20180323184958.14252-1-peter.mayd...@linaro.org Subject: [Qemu-devel] [PULL 00/10] target-arm queue === TEST SCRIPT BEGIN === #!/bin/bash BASE=base n=1 total=$(git log --one

[Qemu-devel] [PATCH for 2.13 v2 04/20] linux-user: move sh4 signal.c parts to sh4 directory

2018-03-23 Thread Laurent Vivier
No code change, only move code from signal.c to sh4/signal.c, except adding includes and exporting setup_frame() and setup_rt_frame(). Signed-off-by: Laurent Vivier --- linux-user/sh4/signal.c| 332 + linux-user/sh4/target_signal.h | 5 + linux-u

<    1   2   3   >