[Qemu-devel] [PATCH v2 00/10] globals: Clean up validation and error checking

2016-06-20 Thread Eduardo Habkost
This series includes multiple changes to the way errors are handled by the global property system. Git tree: https://github.com/ehabkost/qemu-hacks.git work/global-error-handling Changes v1 -> v2: * Fix test-qdev-global-props unit test * Remove subprocess code and "nouser" test case *

[Qemu-devel] [Bug 1594394] Re: Using setreuid / setegid crashes x86_64 user-mode target

2016-06-20 Thread Timothy Pearson
Sounds very relevant, yes. Thanks for the link! -- You received this bug notification because you are a member of qemu- devel-ml, which is subscribed to QEMU. https://bugs.launchpad.net/bugs/1594394 Title: Using setreuid / setegid crashes x86_64 user-mode target Status in QEMU: New Bug

Re: [Qemu-devel] [PATCH] build: Use $(CC) for compiling .S files

2016-06-20 Thread Richard Henderson
On 06/20/2016 06:43 AM, Peter Maydell wrote: On 18 June 2016 at 07:47, Richard Henderson wrote: We fail to pass to AS all of the different flags that may be required for a given set of CFLAGS. Rather than figuring out the host-specific mapping, it's better to allow the

Re: [Qemu-devel] [PATCH] Improve the alignment check infrastructure

2016-06-20 Thread Richard Henderson
On 06/20/2016 06:56 AM, Sergey Sorokin wrote: /* Flags stored in the low bits of the TLB virtual address. These are - defined so that fast path ram access is all zeros. */ + * defined so that fast path ram access is all zeros. + * They start after address alignment bits. + */ +#define

[Qemu-devel] [PATCH 2/3] linux-user: Fix wrong type used for argument to rt_sigqueueinfo

2016-06-20 Thread Peter Maydell
The third argument to the rt_sigqueueinfo syscall is a pointer to a siginfo_t, not a pointer to a sigset_t. Fix the error in the arguments to lock_user(), which meant that we would not have detected some faults that we should. Signed-off-by: Peter Maydell ---

Re: [Qemu-devel] [PATCH 4/4] tests: add a m25p80 test

2016-06-20 Thread Peter Maydell
On 17 June 2016 at 09:35, Cédric Le Goater wrote: > This test uses the palmetto platform and the AST2400 SPI controller to > test the m25p80 flash module device model. The flash model is defined > by the platform (n25q256a) and it would be nice to find way to control > it, using a

Re: [Qemu-devel] [PATCH v6 8/9] target-mips: Add nan2008 flavor of <CEIL|CVT|FLOOR|ROUND|TRUNC>.<L|W>.<S|D>

2016-06-20 Thread Maciej W. Rozycki
On Mon, 20 Jun 2016, Aleksandar Markovic wrote: > This patch is about NaN-2008 flavor of Mips instructions CEIL, CVT, > FLOOR, ROUND, TRUNC only (its title is "Add nan2008 flavor..."). > > Legacy-NaN flavors of the same Mips instructions already operate > correctly, and there is nothing to be

Re: [Qemu-devel] [PATCH 11/13] ICH9 LPC: move call of isa_bus_irqs to 'realize' method

2016-06-20 Thread Paolo Bonzini
On 17/06/2016 16:03, Paolo Bonzini wrote: > The modeling here was weird. ICH9 does not need both ->pic and > ->ioapic, it can make do with just a 24-entry GSI array. > > If you change that in the previous patch, this one makes much more > sense. As it is now, it seems like the ISA bus will

[Qemu-devel] [PATCH v2 1/1] cpu: report hyperv feature words through qom

2016-06-20 Thread Denis V. Lunev
From: Evgeny Yakovlev This change adds hyperv feature words report through qom rpc. When VM is configured with hyperv features enabled libvirt will check that required feature words are set in cpuid leaf 4003 through qom request. Currently qemu does not report

Re: [Qemu-devel] [Qemu-block] [PATCH 2/2] qcow2: Fix qcow2_get_cluster_offset()

2016-06-20 Thread Eric Blake
On 06/20/2016 08:26 AM, Max Reitz wrote: > Recently, qcow2_get_cluster_offset() has been changed to work with bytes > instead of sectors. This invalidated some assertions and introduced a > possible integer multiplication overflow. > > This could be reproduced using e.g. > > $ qemu-img create -f

Re: [Qemu-devel] [PATCH 1/2] qemu-io: Use correct range limitations

2016-06-20 Thread Eric Blake
On 06/20/2016 08:26 AM, Max Reitz wrote: > create_iovec() has a comment lamenting the lack of SIZE_T_MAX. Since > there actually is a SIZE_MAX, use it. > > Two places use INT_MAX for checking the upper bound of a sector count > that is used as an argument for a blk_*() function (blk_discard() and

[Qemu-devel] [PATCH 2/3] ich9: clean up ich9_lpc_update_pic/ich9_lpc_update_apic and callers

2016-06-20 Thread Paolo Bonzini
Make ich9_lpc_update_pic take care only of GSIs 0-15, and ich9_lpc_update_apic take care only of GSIs 16-23. Assert that they are called with the correct GSI indices. Signed-off-by: Paolo Bonzini --- hw/isa/lpc_ich9.c | 39 --- 1 file

[Qemu-devel] [PATCH 1/1] block: ignore flush requests when storage is clean

2016-06-20 Thread Denis V. Lunev
From: Evgeny Yakovlev Some guests (win2008 server for example) do a lot of unnecessary flushing when underlying media has not changed. This adds additional overhead on host when calling fsync/fdatasync. This change introduces a dirty flag in BlockDriverState which is

[Qemu-devel] [PATCH] scsi: esp: fix migration

2016-06-20 Thread Paolo Bonzini
Commit 926cde5 ("scsi: esp: make cmdbuf big enough for maximum CDB size", 2016-06-16) changed the size of a migrated field. Split it in two parts, and only migrate the second part in a new vmstate version. Signed-off-by: Paolo Bonzini --- hw/scsi/esp.c | 5

Re: [Qemu-devel] [Bug 1594069] Re: SIMD instructions translated to scalar host instructions

2016-06-20 Thread Peter Maydell
On 20 June 2016 at 15:05, Timothy Pearson wrote: > I mostly filed the bug report since I was seeing multiple different > attempts to implement this, and even a proper patch series on the > mailing list, but no movement at all toward integrating this feature > into

[Qemu-devel] [PATCH 1/6] serial: make tsr_retry unsigned

2016-06-20 Thread Paolo Bonzini
It can never become negative; reflect this in the type of the field and simplify the conditions. Signed-off-by: Paolo Bonzini --- hw/char/serial.c | 12 include/hw/char/serial.h | 2 +- 2 files changed, 9 insertions(+), 5 deletions(-) diff --git

[Qemu-devel] [Bug 1036987] Re: compilation error due to bug in savevm.c

2016-06-20 Thread T. Huth
http://git.qemu.org/?p=qemu.git;a=commitdiff;h=a5b71725c7067f6805eb30 ** Changed in: qemu Status: Fix Committed => Fix Released -- You received this bug notification because you are a member of qemu- devel-ml, which is subscribed to QEMU. https://bugs.launchpad.net/bugs/1036987 Title:

[Qemu-devel] [PATCH 6/6] serial: remove watch on reset

2016-06-20 Thread Paolo Bonzini
Otherwise, this can cause serial_xmit to be entered with LSR.TEMT=0, which is invalid and causes an assertion failure. Reported-by: Bret Ketchum Signed-off-by: Paolo Bonzini --- hw/char/serial.c | 16 1 file changed, 12 insertions(+),

[Qemu-devel] [PULL 4/7] coccinelle: Remove unnecessary variables for function return value

2016-06-20 Thread Markus Armbruster
From: Eduardo Habkost Use Coccinelle script to replace 'ret = E; return ret' with 'return E'. The script will do the substitution only when the function return type and variable type are the same. Manual fixups: * audio/audio.c: coding style of "read (...)" and "write

Re: [Qemu-devel] [PATCH v2] Change net/socket.c to use socket_*() functions

2016-06-20 Thread Peter Maydell
On 20 June 2016 at 15:55, Paolo Bonzini wrote: > > > On 18/06/2016 09:54, Ashijeet Acharya wrote: >> Use socket_*() functions from include/qemu/sockets.h instead of >> listen()/bind()/ connect()/parse_host_port(). socket_*() fucntions are >> QAPI based and this patch performs

[Qemu-devel] [PATCH 2/6] serial: reinstate watch after migration

2016-06-20 Thread Paolo Bonzini
Otherwise, a serial port can get stuck if it is migrated while flow control is in effect. Signed-off-by: Paolo Bonzini --- hw/char/serial.c | 16 ++-- include/hw/char/serial.h | 1 + 2 files changed, 15 insertions(+), 2 deletions(-) diff --git

[Qemu-devel] [PULL 7/7] log: Fix qemu_set_log_filename() error handling

2016-06-20 Thread Markus Armbruster
When qemu_set_log_filename() detects an invalid file name, it reports an error, closes the log file (if any), and starts logging to stderr (unless daemonized or nothing is being logged). This is wrong. Asking for an invalid log file on the command line should be fatal. Asking for one in the

[Qemu-devel] [Bug 984476] Re: "segmentaion" error when DMAing

2016-06-20 Thread T. Huth
http://git.qemu.org/?p=qemu.git;a=commitdiff;h=362f5fb5643a9cfcf4b5127f ** Changed in: qemu Status: Fix Committed => Fix Released -- You received this bug notification because you are a member of qemu- devel-ml, which is subscribed to QEMU. https://bugs.launchpad.net/bugs/984476 Title:

[Qemu-devel] [PATCH 4/6] serial: simplify tsr_retry reset

2016-06-20 Thread Paolo Bonzini
Move common code outside the if, and reset tsr_retry even in loopback mode. Right now it cannot become non-zero, but it will be possible as soon as we start respecting the baud rate. Signed-off-by: Paolo Bonzini --- hw/char/serial.c | 4 +--- 1 file changed, 1 insertion(+),

[Qemu-devel] [PULL 0/7] Error reporting patches for 2016-06-20

2016-06-20 Thread Markus Armbruster
The following changes since commit 5edbd4e30426d3a0d712510b2509a521e35192b1: Merge remote-tracking branch 'remotes/otubo/tags/pull-seccomp-20160620' into staging (2016-06-20 12:53:35 +0100) are available in the git repository at: git://repo.or.cz/qemu/armbru.git tags/pull-error-2016-06-20

[Qemu-devel] [PULL 2/7] error: Remove NULL checks on error_propagate() calls

2016-06-20 Thread Markus Armbruster
From: Eduardo Habkost error_propagate() already ignores local_err==NULL, so there's no need to check it before calling. Coccinelle patch used to perform the changes added to scripts/coccinelle/error_propagate_null.cocci. Reviewed-by: Eric Blake

[Qemu-devel] [PATCH 0/6] serial: flow control fixes

2016-06-20 Thread Paolo Bonzini
The main fixes here are in patch 2 and patch 6: watches are lost after migration, and not removed on reset. The rest are cleanups; patch 5 fixes the qemu_chr_fe_add_watch API, which botches its return value pretty badly. Paolo Paolo Bonzini (6): serial: make tsr_retry unsigned serial:

[Qemu-devel] analysis of LTP test failures under QEMU linux-user

2016-06-20 Thread Peter Maydell
I went through and quickly analysed all our LTP failures when running under linux-user, which I figured might be of interest to the list... This is with current master plus the following patches (all on list): linux-user: Avoid possible misalignment in host_to_target_siginfo() linux-user: Use

Re: [Qemu-devel] [PATCH] i386: pci-assign: Fix MSI-X table size

2016-06-20 Thread Paolo Bonzini
On 18/06/2016 22:42, Ido Yariv wrote: > The current code creates a whole page mmio region for the MSI-X table > size. > > However, the page containing the MSI-X table may contain other registers > not related to MSI-X. Creating an mmio region for the whole page masks > such registers and may

Re: [Qemu-devel] [RFC v3 PATCH 14/14] target-i386: Generate fences for x86

2016-06-20 Thread Pranith Kumar
On Sat, Jun 18, 2016 at 1:48 AM, Richard Henderson wrote: > On 06/17/2016 09:03 PM, Pranith Kumar wrote: >> >> case 0xe8 ... 0xef: /* lfence */ >> +tcg_gen_mb(TCG_MO_LD_LD | TCG_BAR_SC); >> +break; >> case 0xf0 ... 0xf7: /* mfence */ >>

[Qemu-devel] [Bug 1585008] Re: Windows 7 guests hang on bootup when qxl video is used

2016-06-20 Thread Serge Hallyn
*** This bug is a duplicate of bug 1591724 *** https://bugs.launchpad.net/bugs/1591724 Thanks - so it's fixed upstream and in ubuntu yakkety. I'll mark it as a dup of bug 1591724. ** Changed in: qemu (Ubuntu) Status: Confirmed => Fix Released ** This bug has been marked a duplicate

[Qemu-devel] [PATCH 3/3] linux-user: Support F_GETPIPE_SZ and F_SETPIPE_SZ fcntls

2016-06-20 Thread Peter Maydell
Support the F_GETPIPE_SZ and F_SETPIPE_SZ fcntl operations. Signed-off-by: Peter Maydell --- linux-user/strace.c | 7 +++ linux-user/syscall.c | 6 ++ linux-user/syscall_defs.h | 2 ++ 3 files changed, 15 insertions(+) diff --git

[Qemu-devel] [PATCH 1/3] linux-user: Check sigsetsize argument to syscalls

2016-06-20 Thread Peter Maydell
Many syscalls which take a sigset_t argument also take an argument giving the size of the sigset_t. The kernel insists that this matches its idea of the type size and fails EINVAL if it is not. Implement this logic in QEMU. (This mostly just means some LTP test cases which check error cases now

[Qemu-devel] [PULL 5/7] log: Plug memory leak on multiple -dfilter

2016-06-20 Thread Markus Armbruster
-dfilter overwrites any previous filter. The overwritten filter is leaked. Leaks since the beginning (commit 3514552, v2.6.0). Free it properly. Signed-off-by: Markus Armbruster Message-Id: <1466011636-6112-2-git-send-email-arm...@redhat.com> Reviewed-by: Eric Blake

[Qemu-devel] [PATCH 0/3] linux-user: three minor fixes

2016-06-20 Thread Peter Maydell
This patchset fixes a couple of minor bugs in linux-user which were manifesting as LTP test failures: * syscalls which take a sigsetsize argument should check it matches the target's sigset_t size, or fail EINVAL * a typo meant we weren't locking enough data for the argument to

[Qemu-devel] [PATCH 0/3] ich9: clean up handling of output interrupt pins

2016-06-20 Thread Paolo Bonzini
Currently the southbridge in the q35 machine types gets 40 different qemu_irqs. The 16 lower GSIs (connected to both 8259 and IOAPIC) and the 24 input pins of the IOAPIC (the higher 8 of which correspond to the 8 higher GSIs). However, there's no reason to use the 16 first input pins of the

[Qemu-devel] [PATCH 3/2] MAINTAINERS: Remove Blue Swirl leftovers

2016-06-20 Thread Markus Armbruster
Blue hasn't been active in the QEMU project for a long time. Drop his last MAINTAINERS entries. As per Paolo's recommendation, downgrade status of "BSD user" from Maintained to Orphan since the FreeBSD guys effectively forked it, and "SPARC target" from Maintained to Odd Fixes, since we still

[Qemu-devel] [Bug 1594394] Re: Using setreuid / setegid crashes x86_64 user-mode target

2016-06-20 Thread Peter Maydell
https://patches.linaro.org/patch/63313/ may be relevant here. -- You received this bug notification because you are a member of qemu- devel-ml, which is subscribed to QEMU. https://bugs.launchpad.net/bugs/1594394 Title: Using setreuid / setegid crashes x86_64 user-mode target Status in QEMU:

Re: [Qemu-devel] [PATCH v2] Change net/socket.c to use socket_*() functions

2016-06-20 Thread Paolo Bonzini
On 18/06/2016 09:54, Ashijeet Acharya wrote: > Use socket_*() functions from include/qemu/sockets.h instead of > listen()/bind()/ connect()/parse_host_port(). socket_*() fucntions are > QAPI based and this patch performs this api conversion since everything > will be using QAPI based sockets in

Re: [Qemu-devel] [PATCH RFC 6/7] hw/acpi: extend acpi pci hotplug support for pci express

2016-06-20 Thread Igor Mammedov
On Tue, 31 May 2016 20:48:37 +0300 Marcel Apfelbaum wrote: subj doesn't match patch, it does opposite i.e. makes sure that pcie isn't counted in when building acpi hotplug aml > Emit acpi code for pci hotplug on all PC machines: > - if legacy pci hotpug is enabled

[Qemu-devel] [PATCH 3/3] ich9: unify pic and ioapic IRQ vectors

2016-06-20 Thread Paolo Bonzini
ich9->pic and ich9->ioapic differ for the first 16 GSIs (because ich9->pic is wired to 8259+IOAPIC but ich9->ioapic is wired to IOAPIC only). However, ich9->ioapic is never used for the first 16 GSIs, so the two vectors can be merged. Signed-off-by: Paolo Bonzini ---

[Qemu-devel] [Bug 1594069] Re: SIMD instructions translated to scalar host instructions

2016-06-20 Thread Timothy Pearson
I mostly filed the bug report since I was seeing multiple different attempts to implement this, and even a proper patch series on the mailing list, but no movement at all toward integrating this feature into mainline qemu. What would be needed to e.g. make the patch series on the mailing list

[Qemu-devel] [PATCH 3/6] serial: separate serial_xmit and serial_watch_cb

2016-06-20 Thread Paolo Bonzini
serial_xmit starts transmission of whatever is in the FIFO or THR; serial_watch_cb is a wrapper around it. Signed-off-by: Paolo Bonzini --- hw/char/serial.c | 21 + 1 file changed, 13 insertions(+), 8 deletions(-) diff --git a/hw/char/serial.c

[Qemu-devel] [PATCH 2/2] qcow2: Fix qcow2_get_cluster_offset()

2016-06-20 Thread Max Reitz
Recently, qcow2_get_cluster_offset() has been changed to work with bytes instead of sectors. This invalidated some assertions and introduced a possible integer multiplication overflow. This could be reproduced using e.g. $ qemu-img create -f qcow2 -o cluster_size=1M blub.qcow2 8G Formatting

[Qemu-devel] [PATCH 5/6] char: change qemu_chr_fe_add_watch to return unsigned

2016-06-20 Thread Paolo Bonzini
g_source_attach can return any value between 1 and UINT_MAX if you let QEMU run long enough. However, qemu_chr_fe_add_watch can also return a negative errno value when the device is disconnected or does not support chr_add_watch. Change it to return zero to avoid overloading these values. Fix

[Qemu-devel] [PULL 19/20] mirror: follow AioContext change gracefully

2016-06-20 Thread Stefan Hajnoczi
Add block_job_pause_point() calls to mark quiescent points and make sure to complete in-flight requests when switching AioContexts. This patch solves undefined behavior in the mirror block job when the BDS AioContext is changed by dataplane. Signed-off-by: Stefan Hajnoczi

[Qemu-devel] [PULL 04/20] libqos: drop duplicated virtio_ring.h bit definitions

2016-06-20 Thread Stefan Hajnoczi
Note that virtio_ring.h defines feature bits using their bit number: #define VIRTIO_RING_F_INDIRECT_DESC 28 On the other hand libqos virtio.h uses the bit mask: #define QVIRTIO_F_RING_INDIRECT_DESC0x1000 The patch makes the necessary adjustments. I have used "1u << BITMASK"

[Qemu-devel] [PATCH 1/3] ich9: call ich9_lpc_update_pic for disabled pirqs

2016-06-20 Thread Paolo Bonzini
An asserted pirq can be disabled and the corresponding GSIs should then go down to 0. However, because of the conditional in ich9_lpc_update_by_pirq, the legacy 8259 pin could remain stuck to 1. Signed-off-by: Paolo Bonzini --- hw/isa/lpc_ich9.c | 3 --- 1 file changed, 3

[Qemu-devel] [PULL 16/20] blockjob: add block_job_get_aio_context()

2016-06-20 Thread Stefan Hajnoczi
Add a helper function to document why block jobs sometimes run in the QEMU main loop and to avoid code duplication in a following patch. Signed-off-by: Stefan Hajnoczi Reviewed-by: Paolo Bonzini Reviewed-by: Fam Zheng Message-id:

[Qemu-devel] [PULL 07/20] libqos: drop duplicated virtio_scsi.h definitions

2016-06-20 Thread Stefan Hajnoczi
Signed-off-by: Stefan Hajnoczi Message-id: 1462798061-30382-8-git-send-email-stefa...@redhat.com --- tests/virtio-scsi-test.c | 45 +++-- 1 file changed, 15 insertions(+), 30 deletions(-) diff --git a/tests/virtio-scsi-test.c

[Qemu-devel] [PATCH 1/2] qemu-io: Use correct range limitations

2016-06-20 Thread Max Reitz
create_iovec() has a comment lamenting the lack of SIZE_T_MAX. Since there actually is a SIZE_MAX, use it. Two places use INT_MAX for checking the upper bound of a sector count that is used as an argument for a blk_*() function (blk_discard() and blk_write_compressed(), respectively).

Re: [Qemu-devel] [PATCH RFC 7/7] hw/ich9: enable pci acpi hotplug

2016-06-20 Thread Igor Mammedov
On Tue, 31 May 2016 20:48:38 +0300 Marcel Apfelbaum wrote: > Re-use the pci acpi hotplug code and enable it only for > the new machines using the 'acpi-pci-hotplug-with-bridge-support' > compat property. > > Signed-off-by: Marcel Apfelbaum > --- >

[Qemu-devel] [PULL 14/20] blockjob: rename block_job_is_paused()

2016-06-20 Thread Stefan Hajnoczi
The block_job_is_paused() function name is not great because callers only use it to determine whether pausing has been requested. Rename it to highlight those semantics and remove it from the public header file as there are no external callers. Signed-off-by: Stefan Hajnoczi

Re: [Qemu-devel] [RFC 0/7] Safe watch and breakpoint manipulation

2016-06-20 Thread Paolo Bonzini
On 20/06/2016 15:55, Sergey Fedorov wrote: >> > I'm not sure why you say that arrays are more amenable than QTAILQ >> > (though indeed include/qemu/rcu_queue.h only includes QLIST for now), >> > but I feel bad asking you to redo all the work... > Is there any realistic way to manage *doubly*

[Qemu-devel] [Bug 1594394] Re: Using setreuid / setegid crashes x86_64 user-mode target

2016-06-20 Thread Peter Maydell
Whoops, I meant http://patchwork.ozlabs.org/patch/590640/. -- You received this bug notification because you are a member of qemu- devel-ml, which is subscribed to QEMU. https://bugs.launchpad.net/bugs/1594394 Title: Using setreuid / setegid crashes x86_64 user-mode target Status in QEMU:

[Qemu-devel] [PULL 18/20] blockjob: add AioContext attached callback

2016-06-20 Thread Stefan Hajnoczi
Block jobs that use additional BDSes or event loop resources need a callback to get their affairs in order when the AioContext is switched. Simple block jobs don't need an attach callback, they automatically work thanks to the generic attach/detach notifiers that this patch adds. Signed-off-by:

[Qemu-devel] [PULL 08/20] libqos: drop duplicated virtio_pci.h definitions

2016-06-20 Thread Stefan Hajnoczi
Signed-off-by: Stefan Hajnoczi Message-id: 1462798061-30382-9-git-send-email-stefa...@redhat.com --- tests/libqos/virtio-pci.c | 42 ++ tests/libqos/virtio-pci.h | 17 - tests/virtio-blk-test.c | 11 ++-

Re: [Qemu-devel] Any topics for today's MTTCG sync-up call?

2016-06-20 Thread Alex Bennée
alvise rigo writes: > Hi Alex, > > I'm looking into the worries that Sergey issued in his review of the > last LL/SC series. The target is to reduce the TLB flushes by using an > exclusive history of dynamic length. I don't have anything ready yet > though. Are

[Qemu-devel] [PATCH 0/2] qcow2: Fix qcow2_get_cluster_offset()

2016-06-20 Thread Max Reitz
Patch 2 fixes a wrong assertion in qcow2_get_cluster_offet(). Patch 1 fixes wrong range limitations I encountered in qemu-io while trying to break that wrong assertion. Not CC-ing qemu-stable because these issues were introduced after 2.6.0. Max Reitz (2): qemu-io: Use correct range

[Qemu-devel] [PULL 17/20] block: use safe iteration over AioContext notifiers

2016-06-20 Thread Stefan Hajnoczi
It's possible that an AioContext notifier user was close to finishing when .detach_aio_context() or .attached_aio_context() is called. In that case they may call bdrv_remove_aio_context_notifier() during the callback. Use safe iteration to avoid crashing when the notifier list is modified during

Re: [Qemu-devel] [PATCH 1/5] BIT_RANGE convenience macro

2016-06-20 Thread Dr. David Alan Gilbert
* Peter Maydell (peter.mayd...@linaro.org) wrote: > On 16 June 2016 at 18:12, Dr. David Alan Gilbert (git) > wrote: > > From: "Dr. David Alan Gilbert" > > > > e.g. BIT_RANGE(15, 0) gives 0xff00 > > > > Suggested by: Paolo Bonzini >

[Qemu-devel] [PULL 06/20] libqos: drop duplicated virtio_blk.h definitions

2016-06-20 Thread Stefan Hajnoczi
Signed-off-by: Stefan Hajnoczi Message-id: 1462798061-30382-7-git-send-email-stefa...@redhat.com --- tests/virtio-blk-test.c | 50 - 1 file changed, 16 insertions(+), 34 deletions(-) diff --git a/tests/virtio-blk-test.c

Re: [Qemu-devel] Any topics for today's MTTCG sync-up call?

2016-06-20 Thread alvise rigo
On Mon, Jun 20, 2016 at 4:12 PM, Alex Bennée wrote: > > alvise rigo writes: > > > Hi Alex, > > > > I'm looking into the worries that Sergey issued in his review of the > > last LL/SC series. The target is to reduce the TLB flushes by using

[Qemu-devel] [PULL 12/20] block: process before_write_notifiers in bdrv_co_discard

2016-06-20 Thread Stefan Hajnoczi
From: "Denis V. Lunev" This is mandatory for correct backup creation. In the other case the content under this area would be lost. Dirty bits are set exactly like in bdrv_aligned_pwritev, i.e. they are set even if notifier has returned a error. Signed-off-by: Denis V. Lunev

[Qemu-devel] [PULL 15/20] blockjob: add pause points

2016-06-20 Thread Stefan Hajnoczi
Block jobs are coroutines that usually perform I/O but sometimes also sleep or yield. Currently only sleeping or yielded block jobs can be paused. This means jobs that do not sleep or yield (using block_job_yield()) are unaffected by block_job_pause(). Add block_job_pause_point() so that block

[Qemu-devel] [PULL 05/20] libqos: drop duplicated virtio_vring.h structs

2016-06-20 Thread Stefan Hajnoczi
The descriptor element, used, and avail vring structs are defined in virtio_ring.h. There is no need to duplicate them in libqos virtio. Signed-off-by: Stefan Hajnoczi Message-id: 1462798061-30382-6-git-send-email-stefa...@redhat.com --- tests/libqos/virtio.c | 10

[Qemu-devel] [PULL 20/20] backup: follow AioContext change gracefully

2016-06-20 Thread Stefan Hajnoczi
Move s->target to the new AioContext when there is an AioContext change. The backup_run() coroutine does not use asynchronous I/O so there is no need to wait for in-flight requests in a BlockJobDriver->pause() callback. Guest writes are intercepted by the backup job. Treat them as guest

Re: [Qemu-devel] [PATCH 1/5] BIT_RANGE convenience macro

2016-06-20 Thread Peter Maydell
On 20 June 2016 at 15:11, Dr. David Alan Gilbert wrote: > * Peter Maydell (peter.mayd...@linaro.org) wrote: >> I prefer a "start, length" macro to "position, position", >> because this matches what we already have for the deposit >> and extract functions in this header. > > I

[Qemu-devel] [PULL 13/20] blockjob: move iostatus reset out of block_job_enter()

2016-06-20 Thread Stefan Hajnoczi
The QMP block-job-resume command and cancellation may want to reset the job's iostatus. The next patches add a user who does not want to reset iostatus so move it up to block_job_enter() callers. Signed-off-by: Stefan Hajnoczi Reviewed-by: Fam Zheng

[Qemu-devel] [Bug 1594394] [NEW] Using setreuid / setegid crashes x86_64 user-mode target

2016-06-20 Thread Timothy Pearson
Public bug reported: When setreuid() or setegid() are called from x86_64 target code in user mode, qemu crashes inside the NPTL signal handlers. x86 targets do not directly use a syscall to handle setreuid() / setegid(); instead the x86 NPTL implementation sets up a temporary data region in

[Qemu-devel] [PULL 10/20] block: fixed BdrvTrackedRequest filling in bdrv_co_discard

2016-06-20 Thread Stefan Hajnoczi
From: "Denis V. Lunev" The request area is specified in bytes, not in sectors. Signed-off-by: Denis V. Lunev Reviewed-by: Vladimir Sementsov-Ogievskiy Reviewed-by: Fam Zheng Reviewed-by: Eric Blake

[Qemu-devel] [PULL 02/20] libqos: drop duplicated PCI vendor ID definition

2016-06-20 Thread Stefan Hajnoczi
Signed-off-by: Stefan Hajnoczi Message-id: 1462798061-30382-3-git-send-email-stefa...@redhat.com --- tests/libqos/virtio-pci.c | 3 ++- tests/libqos/virtio.h | 2 -- 2 files changed, 2 insertions(+), 3 deletions(-) diff --git a/tests/libqos/virtio-pci.c

[Qemu-devel] [PULL 11/20] block: fix race in bdrv_co_discard with drive-mirror

2016-06-20 Thread Stefan Hajnoczi
From: "Denis V. Lunev" Actually we must set dirty bitmap dirty after we have written all our zeroes for correct processing in drive mirror code. In the other case we can face not zeroes in this area in mirror_iteration. Signed-off-by: Denis V. Lunev

[Qemu-devel] [PULL 09/20] libqos: add qvirtqueue_cleanup()

2016-06-20 Thread Stefan Hajnoczi
qvirtqueue_setup() allocates the vring and virtqueue state. So far there has been no function to free it. Callers have been using guest_free() for the vring but forgot to free the QVirtQueue state. This patch solves the memory leak by introducing qvirtqueue_cleanup(). Signed-off-by: Stefan

[Qemu-devel] [PULL 03/20] libqos: drop duplicated virtio_config.h definitions

2016-06-20 Thread Stefan Hajnoczi
Note that VIRTIO_F_ANY_LAYOUT and VIRTIO_F_NOTIFY_ON_EMPTY are bit numbers in virtio_config.h but bit masks in qtest virtio.h. Therefore it's necessary to change users from X to (1u << X). Signed-off-by: Stefan Hajnoczi Message-id:

[Qemu-devel] [PULL 01/20] libqos: use virtio_ids.h for device ID definitions

2016-06-20 Thread Stefan Hajnoczi
Avoid redefining device IDs. Use the standard Linux headers that are already in the source tree. Signed-off-by: Stefan Hajnoczi Message-id: 1462798061-30382-2-git-send-email-stefa...@redhat.com --- tests/libqos/virtio.h| 9 - tests/virtio-blk-test.c | 7

[Qemu-devel] [PULL 00/20] Block patches

2016-06-20 Thread Stefan Hajnoczi
The following changes since commit 482b61844ae7c6df39df0b48ac90ffbc87bed7d2: Merge remote-tracking branch 'remotes/pmaydell/tags/pull-target-arm-20160617' into staging (2016-06-17 16:16:37 +0100) are available in the git repository at: git://github.com/stefanha/qemu.git

Re: [Qemu-devel] PPC e500spin pir improperly initialized

2016-06-20 Thread Thomas Huth
On 18.06.2016 02:50, alar...@ddci.com wrote: > Note change of subject from "Determining interest in PPC e500spin, > yield". > > Thomas Huth wrote on 06/16/2016 01:47:05 AM: > Aaron Larson wrote on 15.06.2016 22:12 > > in ppce500_spin.c > > AL> @@ -104,6 +108,16 @@ > AL> > AL>

Re: [Qemu-devel] [PATCH 1/2] hw/misc: Add a model for the ASPEED System Control Unit

2016-06-20 Thread Peter Maydell
On 20 June 2016 at 04:44, Andrew Jeffery wrote: > On Fri, 2016-06-17 at 15:22 +0100, Peter Maydell wrote: >> +static Property aspeed_scu_properties[] = { >> +DEFINE_PROP_ARRAY("reset", AspeedSCUState, num_resets, reset, >> + qdev_prop_uint32, uint32_t),

[Qemu-devel] [PATCH] Improve the alignment check infrastructure

2016-06-20 Thread Sergey Sorokin
Some architectures (e.g. ARMv8) need the address which is aligned to a size more than the size of the memory access. It's enougth the current costless alignment check implementation in QEMU, but we need to support the alignment size specifying. Signed-off-by: Sergey Sorokin

Re: [Qemu-devel] [Qemu-ppc] [PATCH 01/10] ppc: Fix rfi/rfid/hrfi/... emulation

2016-06-20 Thread Alexander Graf
On 06/20/2016 11:32 AM, Benjamin Herrenschmidt wrote: On Mon, 2016-06-20 at 18:02 +1000, Benjamin Herrenschmidt wrote: On Mon, 2016-06-20 at 17:08 +1000, Benjamin Herrenschmidt wrote: That fixed, it dies elsewhere in something related to page faults, still digging. Next problem: Darwin

Re: [Qemu-devel] [RFC 0/7] Safe watch and breakpoint manipulation

2016-06-20 Thread Sergey Fedorov
On 17/06/16 20:01, Paolo Bonzini wrote: > > On 17/06/2016 18:33, Alex Bennée wrote: >> First we move the break/watchpoints into an array which is more >> amenable to RCU control that the QLIST. We then control the life time >> of references to break/watchpoint data by removing long held >>

[Qemu-devel] [PATCH v2] vmxnet3: Fix reading/writing guest memory specially when behind an IOMMU

2016-06-20 Thread KarimAllah Ahmed
When a PCI device lives behind an IOMMU, it should use 'pci_dma_*' family of functions when any transfer from/to guest memory is required while 'cpu_physical_memory_*' family of functions completely bypass any MMU/IOMMU in the system. vmxnet3 in some places was using 'cpu_physical_memory_*'

Re: [Qemu-devel] [PATCH 05/10] qdev: GlobalProperty.errp field

2016-06-20 Thread Eduardo Habkost
On Mon, Jun 20, 2016 at 10:14:55AM +0200, Markus Armbruster wrote: > Eduardo Habkost writes: [...] > > diff --git a/include/hw/qdev-core.h b/include/hw/qdev-core.h > > index 24aa0a7..16e7cc0 100644 > > --- a/include/hw/qdev-core.h > > +++ b/include/hw/qdev-core.h > > @@

Re: [Qemu-devel] [PATCH 00/10] globals: Clean up validation and error checking

2016-06-20 Thread Eduardo Habkost
On Mon, Jun 20, 2016 at 03:11:00PM +0200, Igor Mammedov wrote: > On Wed, 15 Jun 2016 17:32:43 -0300 > Eduardo Habkost wrote: > > > This series includes multiple changes to the way errors are > > handled by the global property system. > Could you fix "make check", > by the

Re: [Qemu-devel] [PATCH 08/19] block: Make path_combine() return the path

2016-06-20 Thread Alberto Garcia
On Tue 26 Apr 2016 11:32:07 PM CEST, Max Reitz wrote: > Besides being safe for arbitrary path lengths, after some follow-up > patches all callers will want a freshly allocated buffer anyway. > > In the meantime, path_combine_deprecated() is added which has the same > interface as path_combine()

Re: [Qemu-devel] [PATCH] build: Use $(CC) for compiling .S files

2016-06-20 Thread Peter Maydell
On 18 June 2016 at 07:47, Richard Henderson wrote: > We fail to pass to AS all of the different flags that > may be required for a given set of CFLAGS. Rather than > figuring out the host-specific mapping, it's better to > allow the compiler driver to do that. > > This fixes

Re: [Qemu-devel] [PATCH 04/10] qdev: Use error_prepend() for errors applying globals

2016-06-20 Thread Eduardo Habkost
On Mon, Jun 20, 2016 at 10:02:38AM +0200, Markus Armbruster wrote: > Eduardo Habkost writes: > > > The same Error* will be used in an error_propagate() call in the > > future, so prepend a "can't apply global" prefix to it. > > What future? A future patch? > > >

Re: [Qemu-devel] [PATCH 10/10] machine: Skip global registration for non-existing classes

2016-06-20 Thread Eduardo Habkost
On Sun, Jun 19, 2016 at 07:50:56PM +0300, Marcel Apfelbaum wrote: > On 06/19/2016 07:39 PM, Marcel Apfelbaum wrote: > > On 06/15/2016 11:32 PM, Eduardo Habkost wrote: > > > MachineClass::compat_props may point to class names that are not > > > compiled into the QEMU binary. Skip registering those

Re: [Qemu-devel] [PATCH 4/7] This patch adds initial user-virtualization support for the DRM (type 'd') IOCTLs in linux. With it and a corresponding architecture chroot (say aarch64), I am able to suc

2016-06-20 Thread Peter Maydell
On 19 June 2016 at 01:11, Timothy Pearson wrote: > 1. It will only work with open drivers as their IOCTLs are documented. > 2. i965+ is only supported. That is any haswell, ivybridge, etc. GPU > will work. > 3. X doesn't start yet, though this patch eliminates all

Re: [Qemu-devel] [PATCH v3 0/7] virtio-blk: multiqueue support

2016-06-20 Thread Roman Penyaev
Hi, Stefan. On Mon, Jun 20, 2016 at 12:36 PM, Stefan Hajnoczi wrote: > On Tue, Jun 07, 2016 at 05:28:24PM +0100, Stefan Hajnoczi wrote: >> v3: >> * Drop Patch 1 to batch guest notify for non-dataplane >> >>The Linux AIO completion BH and the virtio-blk batch notify BH

Re: [Qemu-devel] [PATCH 2/7] QEMU does not currently support host pages that are larger than guest pages, likely due to glibc using fixed mmap requests.

2016-06-20 Thread Peter Maydell
On 19 June 2016 at 19:24, Richard Henderson wrote: > On 06/19/2016 02:46 AM, Peter Maydell wrote: >> This is supposed to work -- for instance the linux-user/mmap.c >> code has support for host pages and target pages not being the same. >> In particular for ARM guests

Re: [Qemu-devel] [PATCH v6 02/22] qapi: Add lock-mode in blockdev-add options

2016-06-20 Thread Kevin Wolf
Am 18.06.2016 um 13:16 hat Fam Zheng geschrieben: > On Fri, 06/17 11:17, Kevin Wolf wrote: > > Am 03.06.2016 um 10:48 hat Fam Zheng geschrieben: > > > To allow overriding the default locking behavior when opening the image. > > > > > > Signed-off-by: Fam Zheng > > > --- > > >

Re: [Qemu-devel] [PATCH 1/7] Add initial x86_64 signal handlers

2016-06-20 Thread Peter Maydell
On 19 June 2016 at 01:11, Timothy Pearson wrote: > Note that x86_64 systems only offer the _rt signal handler variants, > so the legacy signal handlers remain unimplemented on this platform. > > Signed-off-by: Timothy Pearson > ---

Re: [Qemu-devel] [PATCH 04/19] block: Add bdrv_default_refresh_format_filename

2016-06-20 Thread Alberto Garcia
On Tue 26 Apr 2016 11:32:03 PM CEST, Max Reitz wrote: > Split off the default code for format BDS from bdrv_refresh_filename() > into an own function, first because it is nicer this way, and second > because this will allow block drivers to reuse this function in their > own specific

Re: [Qemu-devel] [PATCH 05/19] block: Add bdrv_default_refresh_protocol_filename

2016-06-20 Thread Alberto Garcia
On Tue 26 Apr 2016 11:32:04 PM CEST, Max Reitz wrote: > Split off the default code for protocol BDS from bdrv_refresh_filename() > into an own function, just as it has been done for format BDS. > > Signed-off-by: Max Reitz Reviewed-by: Alberto Garcia Berto

[Qemu-devel] [Bug 1585008] Re: Windows 7 guests hang on bootup when qxl video is used

2016-06-20 Thread Laszlo Ersek (Red Hat)
This is a dupe of LP#1581936 and LP#1591724. The issue is fixed by upstream QEMU commit 94ef4f337fb6. -- You received this bug notification because you are a member of qemu- devel-ml, which is subscribed to QEMU. https://bugs.launchpad.net/bugs/1585008 Title: Windows 7 guests hang on bootup

Re: [Qemu-devel] [PATCH 00/10] globals: Clean up validation and error checking

2016-06-20 Thread Igor Mammedov
On Wed, 15 Jun 2016 17:32:43 -0300 Eduardo Habkost wrote: > This series includes multiple changes to the way errors are > handled by the global property system. Could you fix "make check", by the end of series it breaks at compile time. > > The series is based on my

Re: [Qemu-devel] [RFC 1/8] cpus: pass CPUState to run_on_cpu helpers

2016-06-20 Thread Sergey Fedorov
On 20/06/16 16:02, Alex Bennée wrote: > Sergey Fedorov writes: > >> > From: Alex Bennée >> > >> > CPUState is a fairly common pointer to pass to these helpers. This means >> > if you need other arguments for the async_run_on_cpu case you end up

Re: [Qemu-devel] [RFC 1/8] cpus: pass CPUState to run_on_cpu helpers

2016-06-20 Thread Alex Bennée
Sergey Fedorov writes: > From: Alex Bennée > > CPUState is a fairly common pointer to pass to these helpers. This means > if you need other arguments for the async_run_on_cpu case you end up > having to do a g_malloc to stuff additional data

<    1   2   3   4   5   >