Re: [Qemu-devel] [RISU PATCH 04/10] risu: move optional args to each architecture

2017-11-09 Thread Richard Henderson
On 11/07/2017 04:05 PM, Alex Bennée wrote: > +if (arch_long_opts) { > +struct option *dptr, *sptr; > +size_t osize = sizeof(default_longopts); > +lopts = malloc(osize); > +/* Copy default opts */ > +memcpy(lopts, default_longopts, osize); > +dptr

Re: [Qemu-devel] [RISU PATCH 07/10] risugen: add --sve support

2017-11-09 Thread Richard Henderson
On 11/07/2017 04:05 PM, Alex Bennée wrote: > @@ -483,6 +521,10 @@ sub write_random_aarch64_regdata($) > write_random_aarch64_fpdata(); > } > > +if ($sve_enabled) { > +write_random_aarch64_svedata(); > +} Should write either sve or fpdata, but not both, since the reg

Re: [Qemu-devel] [PATCH 1/2] nbd/server: Implement sparse reads atop structured reply

2017-11-09 Thread Vladimir Sementsov-Ogievskiy
07.11.2017 06:09, Eric Blake wrote: The reason that NBD added structured reply in the first place was to allow for efficient reads of sparse files, by allowing the reply to include chunks to quickly communicate holes to the client without sending lots of zeroes over the wire. Time to implement t

Re: [Qemu-devel] [PATCH v4 40/45] hw/watchdog: Replace fprintf(stderr, "*\n" with error_report()

2017-11-09 Thread Richard W.M. Jones
On Wed, Nov 08, 2017 at 08:43:45PM -0300, Philippe Mathieu-Daudé wrote: > > @@ -126,7 +125,7 @@ void watchdog_perform_action(void) > > > > case WATCHDOG_ACTION_DEBUG: > > qapi_event_send_watchdog(WATCHDOG_ACTION_DEBUG, &error_abort); > > -fprintf(stderr, "watchdog: timer fir

Re: [Qemu-devel] [PATCH 2/2] nbd/server: Optimize final chunk of sparse read

2017-11-09 Thread Vladimir Sementsov-Ogievskiy
07.11.2017 06:09, Eric Blake wrote: If we are careful to handle 0-length read requests correctly, we can optimize our sparse read to send the NBD_REPLY_FLAG_DONE bit on our last OFFSET_DATA or OFFSET_HOLE chunk rather than needing a separate chunk. Signed-off-by: Eric Blake Reviewed-by: Vladi

Re: [Qemu-devel] [PATCH v2 1/7] nbd-client: Fix error message typos

2017-11-09 Thread Vladimir Sementsov-Ogievskiy
09.11.2017 00:56, Eric Blake wrote: Provide missing spaces that are required when using string concatenation to break error messages across source lines. Signed-off-by: Eric Blake Reviewed-by: Vladimir Sementsov-Ogievskiy --- block/nbd-client.c | 6 +++--- 1 file changed, 3 insertions(

Re: [Qemu-devel] [PATCH v2 2/7] nbd-client: Refuse read-only client with BDRV_O_RDWR

2017-11-09 Thread Vladimir Sementsov-Ogievskiy
09.11.2017 00:56, Eric Blake wrote: The NBD spec says that clients should not try to write/trim to an export advertised as read-only by the server. But we failed to check that, and would allow the block layer to use NBD with BDRV_O_RDWR even when the server is read-only, which meant we were depe

Re: [Qemu-devel] [PATCH v2 2.5/7] fixup! nbd-client: Refuse read-only client with BDRV_O_RDWR

2017-11-09 Thread Vladimir Sementsov-Ogievskiy
09.11.2017 01:23, Eric Blake wrote: ... Fix several iotests to comply with the new behavior (since qemu-nbd of an internal snapshot, as well as nbd-server-add over QMP, default to a read-only export, we must tell blockdev-add/qemu-io to set up a read-only client). Signed-off-by: Eric Blake R

Re: [Qemu-devel] [PATCH v2 3/7] nbd/client: Nicer trace of structured reply

2017-11-09 Thread Vladimir Sementsov-Ogievskiy
09.11.2017 00:56, Eric Blake wrote: It's useful to know which structured reply chunk is being processed. Signed-off-by: Eric Blake Reviewed-by: Vladimir Sementsov-Ogievskiy -- Best regards, Vladimir

Re: [Qemu-devel] [PATCH v2 4/7] nbd: Fix struct name for structured reads

2017-11-09 Thread Vladimir Sementsov-Ogievskiy
09.11.2017 00:57, Eric Blake wrote: A closer read of the NBD spec shows that a structured reply chunk for a hole is not quite identical to the prefix of a data chunk, because the hole has to also send a 32-bit size field. Although we do not yet send holes, we should fix the misleading informatio

Re: [Qemu-devel] [PATCH v2 5/7] nbd-client: Short-circuit 0-length operations

2017-11-09 Thread Vladimir Sementsov-Ogievskiy
09.11.2017 00:57, Eric Blake wrote: The NBD spec was recently clarified to state that clients should not send 0-length requests to the server, as the server behavior is undefined [1]. We know that qemu-nbd's behavior is a successful no-op (once it has filtered for read-only exports), but other N

Re: [Qemu-devel] [PATCH v3] xen-disk: use an IOThread per instance

2017-11-09 Thread Paul Durrant
> -Original Message- > From: Stefan Hajnoczi [mailto:stefa...@gmail.com] > Sent: 08 November 2017 17:42 > To: Paul Durrant > Cc: qemu-devel@nongnu.org; xen-de...@lists.xenproject.org; Anthony > Perard ; Kevin Wolf ; > Stefano Stabellini ; Max Reitz > Subject: Re: [Qemu-devel] [PATCH v3] x

Re: [Qemu-devel] [PATCH v6] x86: use lock+addl for smp_mb()

2017-11-09 Thread Peter Zijlstra
On Fri, Oct 27, 2017 at 07:14:31PM +0300, Michael S. Tsirkin wrote: > The one difference between lock+add and mfence is that lock+addl does > not affect clflush, previous patches converted all uses of clflush to > call mb(), such that changes to smp_mb won't affect it. > > Update mb/rmb/wmb on 32

Re: [Qemu-devel] [PATCH v2 6/7] nbd-client: Stricter enforcing of structured reply spec

2017-11-09 Thread Vladimir Sementsov-Ogievskiy
09.11.2017 00:57, Eric Blake wrote: Ensure that the server is not sending unexpected chunk lengths for either the NONE or the OFFSET_DATA chunk, nor unexpected hole length for OFFSET_HOLE. This will flag any server that responds to a zero-length read with an OFFSET_DATA as broken, or OFFSET_HO

Re: [Qemu-devel] [qemu-s390x] [PATCH] target/s390x: Finish implementing RISBGN

2017-11-09 Thread Cornelia Huck
On Tue, 7 Nov 2017 15:55:46 +0100 Richard Henderson wrote: > We added the entry to insn-data.def, but failed to update op_risbg > to match. No need to special-case the imask inversion, since that > is already ~0 for RISBG (and now RISBGN). > > Fixes: 375ee58bedcda359011fe7fa99e0647f66f9ffa0 >

Re: [Qemu-devel] [PATCH v2 7/7] nbd/server: Fix structured read of length 0

2017-11-09 Thread Vladimir Sementsov-Ogievskiy
09.11.2017 00:57, Eric Blake wrote: The NBD spec was recently clarified to state that a read of length 0 should not be attempted by a compliant client; but that a server must still handle it correctly in an unspecified manner (that is, either a successful no-op or an error reply, but not a crash)

Re: [Qemu-devel] [PATCH] Makefile: simpler/faster "make help"

2017-11-09 Thread Paolo Bonzini
On 09/11/2017 07:40, Fam Zheng wrote: > On Wed, 11/08 00:20, Philippe Mathieu-Daudé wrote: >> Using obscure black magic introduced in eaa2ddbb767 :) > > That is a pretty boring one compared to the rest of our build system. > >> >> In an out-of-tree directory, running "../configure && make help" w

Re: [Qemu-devel] [Qemu-block] segfault in parallel blockjobs (iotest 30)

2017-11-09 Thread Alberto Garcia
On Thu 09 Nov 2017 07:05:26 AM CET, Fam Zheng wrote: >> > I can fix the crash by adding block_job_pause_point(&s->common) at >> > the end of stream_run() (where the 'out' label is). >> > >> > I'm thinking that perhaps we should add the pause point directly to >> > block_job_defer_to_main_loop(),

[Qemu-devel] [PATCH] coroutine: simplify co_aio_sleep_ns() prototype

2017-11-09 Thread Stefan Hajnoczi
The AioContext pointer argument to co_aio_sleep_ns() is only used for the sleep timer. It does not affect where the caller coroutine is resumed. Due to changes to coroutine and AIO APIs it is now possible to drop the AioContext pointer argument. This is safe to do since no caller has specific re

Re: [Qemu-devel] [PATCH] virtio-gpu: fix bug in host memory calculation.

2017-11-09 Thread Marc-André Lureau
Hi - Original Message - > The old code treats bits as bytes when calculating host memory usage. > Change it to be consistent with allocation logic in pixman library. > Good catch > Signed-off-by: Tao Wu > --- > hw/display/virtio-gpu.c | 13 +++-- > 1 file changed, 11 insertion

Re: [Qemu-devel] [PATCH] ui: fix dcl unregister

2017-11-09 Thread Marc-André Lureau
Hi On Thu, Nov 9, 2017 at 8:37 AM, Gerd Hoffmann wrote: > register checks for dcl->ds being NULL, to avoid registering > the same dcl twice. > > Therefore dcl->ds must be cleared on unregister, otherwise > un-registering and re-registering doesn't work. > > Fixes: https://bugzilla.redhat.com/show

Re: [Qemu-devel] [PATCH 1/3] trace: Simplify find_debugfs()

2017-11-09 Thread Stefan Hajnoczi
On Wed, Nov 08, 2017 at 12:31:34AM +0900, Namhyung Kim wrote: > The return vale of find_debugfs() is 1 if it could find a mount point of > debugfs. It can be saved in the while loop instead of checking it again. > > Signed-off-by: Namhyung Kim > --- > trace/ftrace.c | 7 +++ > 1 file change

[Qemu-devel] [Bug 1726910] Re: UI request: add a function key toolbar (f1-f12)

2017-11-09 Thread Daniel Berrange
Adding a toolbar with function keys consumes alot of screen real estate for something that is going to be rarely used in practice. The more usual approach to this problem is for the application to grab the keyboard and block all local window system accelerators, so that Fn goes straight to the gue

Re: [Qemu-devel] [PATCH] slirp: don't zero ti_i since we access it later.

2017-11-09 Thread Marc-André Lureau
Hi Adding Guillaume in CC, who wrote that line in commit 98c63057d2144 On Wed, Nov 8, 2017 at 11:53 PM, Tao Wu via Qemu-devel wrote: > The current code looks buggy, we zero ti_i while we access > ti_dst/ti_src later. Could you described the symptoms and why you fixed it that way? thanks > > S

[Qemu-devel] [PATCH v2] ui: fix dcl unregister

2017-11-09 Thread Gerd Hoffmann
register checks for dcl->ds being NULL, to avoid registering the same dcl twice. Therefore dcl->ds must be cleared on unregister, otherwise un-registering and re-registering doesn't work. Fixes: https://bugzilla.redhat.com/show_bug.cgi?id=1510809 Signed-off-by: Gerd Hoffmann Reviewed-by: Marc-An

Re: [Qemu-devel] [PATCH V3] hw/pci-host: Fix x86 Host Bridges 64bit PCI hole

2017-11-09 Thread Laszlo Ersek
On 11/08/17 15:48, Marcel Apfelbaum wrote: > Currently there is no MMIO range over 4G > reserved for PCI hotplug. Since the 32bit PCI hole > depends on the number of cold-plugged PCI devices > and other factors, it is very possible is too small > to hotplug PCI devices with large BARs. > > Fix it

Re: [Qemu-devel] [PATCH] configure: Deal with OpenBSD/i386 emulation linker

2017-11-09 Thread Peter Maydell
On 7 November 2017 at 23:51, Brad Smith wrote: > On Mon, Nov 06, 2017 at 11:37:45AM +, Peter Maydell wrote: >> On 6 November 2017 at 00:53, Brad Smith wrote: >> > OpenBSD/i386 uses elf_i386_obsd for the emulation linker. >> > >> > Signed-off-by: Brad Smith >> > >> > >> > diff --git a/configu

Re: [Qemu-devel] [PATCH v2 1/1] Makefile: Capstone: Add support for cross compile ranlib

2017-11-09 Thread Peter Maydell
On 8 November 2017 at 15:10, Alistair Francis wrote: > When cross compiling QEMU for Windows we need to specify the cross > version of ranlib to avoid build errors when building capstone. This > patch ensures we use the same cross prefix on ranlib as other toolchain > components. > > This patch fi

Re: [Qemu-devel] [PATCH 1/4] linux-user/s390x: Mask si_addr for SIGSEGV

2017-11-09 Thread Peter Maydell
On 8 November 2017 at 21:18, Richard Henderson wrote: > On 11/06/2017 07:33 PM, Peter Maydell wrote: >> For s390x, the address passed to a signal handler in the >> siginfo_t si_addr field is masked (in the kernel this is done in >> do_sigbus() and do_sigsegv() in arch/s390/mm/fault.c). Implement >

Re: [Qemu-devel] [Qemu-block] [PATCH v4 0/4] Don't write headers if BDS is INACTIVE

2017-11-09 Thread Stefan Hajnoczi
On Tue, Nov 07, 2017 at 08:10:32AM -0500, Jeff Cody wrote: > Changes from v3->v4: > > Patch 3: Add migrate_del_blocker and error_free (Thanks Stefan) > > > git-backport-diff -r qemu/master.. -u ba11b69 > > 001/4:[] [--] 'block/vhdx.c: Don't blindly update the header' > 002/4:[] [--] 'bl

Re: [Qemu-devel] [PATCH v3] xen-disk: use an IOThread per instance

2017-11-09 Thread Stefan Hajnoczi
On Thu, Nov 09, 2017 at 09:30:45AM +, Paul Durrant wrote: > > -Original Message- > > From: Stefan Hajnoczi [mailto:stefa...@gmail.com] > > Sent: 08 November 2017 17:42 > > To: Paul Durrant > > Cc: qemu-devel@nongnu.org; xen-de...@lists.xenproject.org; Anthony > > Perard ; Kevin Wolf ;

Re: [Qemu-devel] [PATCH] block: Fix error path in bdrv_backing_update_filename()

2017-11-09 Thread Stefan Hajnoczi
On Mon, Nov 06, 2017 at 05:55:00PM +0100, Kevin Wolf wrote: > error_setg_errno() takes a positive errno code. > > Signed-off-by: Kevin Wolf > --- > block.c | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) Reviewed-by: Stefan Hajnoczi signature.asc Description: PGP signature

[Qemu-devel] 答复: Re: [PATCH v2] qga: replace GetIfEntry

2017-11-09 Thread lu.zhipeng
i think the code is better if (OSver.dwMajorVersion >= 6) { MIB_IF_ROW2 aMib_ifrow; typedef NETIOAPI_API (WINAPI *getifentry2_t)(PMIB_IF_ROW2 Row); memset(&aMib_ifrow, 0, sizeof(aMib_ifrow)); aMib_ifrow.InterfaceIndex = nicId; HMODULE module = GetModuleHandle("iphlp

Re: [Qemu-devel] [Qemu-block] question: I found a qemu crash when attach virtio-scsi disk

2017-11-09 Thread Stefan Hajnoczi
On Tue, Nov 07, 2017 at 11:39:44AM +0100, Paolo Bonzini wrote: > On 07/11/2017 02:59, Fam Zheng wrote: > > On Mon, 11/06 17:33, Paolo Bonzini wrote: > >> On 06/11/2017 17:11, Kevin Wolf wrote: > >>> Am 03.11.2017 um 11:26 hat Stefan Hajnoczi geschrieben: > On Wed, Nov 01, 2017 at 06:42:33AM +0

Re: [Qemu-devel] [Qemu-block] question: I found a qemu crash when attach virtio-scsi disk

2017-11-09 Thread Paolo Bonzini
On 09/11/2017 12:33, Stefan Hajnoczi wrote: >>> Can main thread somehow call aio_context_acquire(vs->ctx) (and release) >>> around >>> qdev_set_parent_bus()? virtio_scsi_device_find() takes the lock. >> No, the context is not set yet. But the locking is easy to add, >> separately from the bug tha

Re: [Qemu-devel] [Qemu-ppc] [PATCH v2 2/4] tests: adding 'set_indicator' RTAS call

2017-11-09 Thread Daniel Henrique Barboza
Hi Laurent, On 11/06/2017 02:54 PM, Laurent Vivier wrote: On 31/10/2017 21:43, Daniel Henrique Barboza wrote: 'set_indicator' is a RTAS hypercall that is used to change the state of both physical and logical devices DRCs by setting allocation-state, isolation-state and dr-indicator. This patch

[Qemu-devel] [PATCH] highbank: validate register offset before access

2017-11-09 Thread P J P
From: Prasad J Pandit An 'offset' parameter sent to highbank register r/w functions could be greater than number(NUM_REGS=0x200) of hb registers, leading to an OOB access issue. Add check to avoid it. Reported-by: Moguofang (Dennis mo) Signed-off-by: Prasad J Pandit --- hw/arm/highbank.c | 7

Re: [Qemu-devel] [Qemu-ppc] [PATCH v2 1/4] tests: adding 'check_exception' RTAS implementation

2017-11-09 Thread Daniel Henrique Barboza
Hi Laurent, On 11/06/2017 01:12 PM, Laurent Vivier wrote: On 31/10/2017 21:43, Daniel Henrique Barboza wrote: In the sPAPR guest, events such as device hotplug/unplug are retrieved by the check_exception RTAS call after the guest receives an IRQ pulse. For both hotplug and unplug operations, gu

[Qemu-devel] [Qemu devel PATCH] MAINTAINERS: Add entries for Smartfusion2

2017-11-09 Thread Subbaraya Sundeep
add voluntarily myself as maintainer for Smartfusion2 Signed-off-by: Subbaraya Sundeep --- MAINTAINERS | 17 + 1 file changed, 17 insertions(+) diff --git a/MAINTAINERS b/MAINTAINERS index 0cd4d02..dae08bd 100644 --- a/MAINTAINERS +++ b/MAINTAINERS @@ -564,6 +564,23 @@ M: Alista

Re: [Qemu-devel] [PATCH v2] tpm_emulator: Add a caching layer for the TPM Established flag

2017-11-09 Thread Marc-André Lureau
Hi On Wed, Nov 8, 2017 at 9:37 PM, Stefan Berger wrote: > Add a caching layer for the TPM established flag so that we don't > need to go to the emulator every time the flag is read by accessing > the REG_ACCESS register. > > Signed-off-by: Stefan Berger > > v1->v2: > - move the caching to the b

Re: [Qemu-devel] [RISU PATCH 07/10] risugen: add --sve support

2017-11-09 Thread Dave Martin
On Tue, Nov 07, 2017 at 03:05:55PM +, Alex Bennée wrote: > This is similar to the approach used by the FP/simd data in so far as > we generate a block of random data and then load into it. As there are > no post-index SVE operations we need to emit an additional incp > instruction to generate o

Re: [Qemu-devel] [Qemu-ppc] [PATCH v2 3/4] tests: ibm, configure-connector RTAS call implementation

2017-11-09 Thread Daniel Henrique Barboza
On 11/06/2017 03:46 PM, Laurent Vivier wrote: On 31/10/2017 21:43, Daniel Henrique Barboza wrote: 'ibm,configure-connector' hypercall is used by the guest OS to start the configuration of a given device, where the machine configures the said device and all its sub-devices, giving back FDTs to

Re: [Qemu-devel] [PATCH v2 0/5] tpm: Match frontend and backend buffer sizes (not 2.11)

2017-11-09 Thread Marc-André Lureau
Hi - Original Message - > This patch series does away with the hard coded buffer size in the TIS > frontend and instead retrieves the buffer size from the device that's > being used. So it gets it from the host device or the external emulator. > In case the frontend (CRB) cannot support th

[Qemu-devel] [PATCH V2] hw/pcie-pci-bridge: restrict to X86 and ARM

2017-11-09 Thread Marcel Apfelbaum
The PCIE-PCI bridge is specific to "pure" PCIe systems (on QEMU we have X86 and ARM), it does not make sense to have if in other archs. Reported-by: Thomas Huth Signed-off-by: Marcel Apfelbaum --- V1 -> V2: Addressed Thomas and Cornelia comments: - Conditioned the pcie-pci-bridge compilation

[Qemu-devel] NBD BLOCK_STATUS

2017-11-09 Thread Vladimir Sementsov-Ogievskiy
Hi! Interesting fact: list/set_meta_context options are per-export, so, in the server we should keep context selection per client per export. And it is possible for client to set contexts for one export and than proceed to transmission phase with another one. This is not really touched in spe

[Qemu-devel] [PATCH V3] hw/pcie-pci-bridge: restrict to X86 and ARM

2017-11-09 Thread Marcel Apfelbaum
The PCIE-PCI bridge is specific to "pure" PCIe systems (on QEMU we have X86 and ARM), it does not make sense to have it in other archs. Reported-by: Thomas Huth Signed-off-by: Marcel Apfelbaum --- V2 -> V3: - Another tweak in subject s/if/it (Cornelia) V1 -> V2: Addressed Thomas and Corneli

Re: [Qemu-devel] [PATCH V2] hw/pcie-pci-bridge: restrict to X86 and ARM

2017-11-09 Thread Thomas Huth
On 09.11.2017 13:43, Marcel Apfelbaum wrote: > The PCIE-PCI bridge is specific to "pure" PCIe systems > (on QEMU we have X86 and ARM), it does not make sense to > have if in other archs. > > Reported-by: Thomas Huth > Signed-off-by: Marcel Apfelbaum > --- > > V1 -> V2: > Addressed Thomas and C

Re: [Qemu-devel] [PATCH V2] hw/pcie-pci-bridge: restrict to X86 and ARM

2017-11-09 Thread Marcel Apfelbaum
On 09/11/2017 14:46, Thomas Huth wrote: On 09.11.2017 13:43, Marcel Apfelbaum wrote: The PCIE-PCI bridge is specific to "pure" PCIe systems (on QEMU we have X86 and ARM), it does not make sense to have if in other archs. Reported-by: Thomas Huth Signed-off-by: Marcel Apfelbaum --- V1 -> V2:

Re: [Qemu-devel] [PATCH] numa: fixup parsed NumaNodeOptions earlier

2017-11-09 Thread Markus Armbruster
Igor Mammedov writes: > On Thu, 12 Oct 2017 12:43:46 -0300 > Eduardo Habkost wrote: > >> On Thu, Oct 12, 2017 at 11:39:58AM +0200, Igor Mammedov wrote: >> > numa 'mem' option with suffix or without one is possible >> > only on CLI/HMP. Instead of fixing up special suffix less >> > CLI case deep

[Qemu-devel] [PATCH V4] hw/pcie-pci-bridge: restrict to X86 and ARM

2017-11-09 Thread Marcel Apfelbaum
The PCIE-PCI bridge is specific to "pure" PCIe systems (on QEMU we have X86 and ARM), it does not make sense to have it in other archs. Reported-by: Thomas Huth Signed-off-by: Marcel Apfelbaum --- V3 -> V4: - Move the config line to pci.mak (Thomas) V2 -> V3: - Another tweak in subject s/if

Re: [Qemu-devel] [PATCH V4] hw/pcie-pci-bridge: restrict to X86 and ARM

2017-11-09 Thread no-reply
Hi, This series failed automatic build test. Please find the testing commands and their output below. If you have docker installed, you can probably reproduce it locally. Subject: [Qemu-devel] [PATCH V4] hw/pcie-pci-bridge: restrict to X86 and ARM Type: series Message-id: 20171109125826.120228-1-

Re: [Qemu-devel] [PATCH V3] hw/pcie-pci-bridge: restrict to X86 and ARM

2017-11-09 Thread no-reply
Hi, This series failed automatic build test. Please find the testing commands and their output below. If you have docker installed, you can probably reproduce it locally. Subject: [Qemu-devel] [PATCH V3] hw/pcie-pci-bridge: restrict to X86 and ARM Type: series Message-id: 20171109124556.117858-1-

[Qemu-devel] [PATCH for-2.12 v2 00/12] spapr: introduce an IRQ allocator at the machine level

2017-11-09 Thread Cédric Le Goater
Hello, Currently, the ICSState 'ics' object of the sPAPR machine acts as the global interrupt source handler and also as the IRQ number allocator for the machine. Some IRQ numbers are allocated very early in the machine initialization sequence to populate the device tree, and this is a problem to

[Qemu-devel] [PATCH for-2.12 v2 01/12] spapr: add pseries 2.12 machine type

2017-11-09 Thread Cédric Le Goater
Signed-off-by: Cédric Le Goater --- hw/ppc/spapr.c | 16 +++- 1 file changed, 15 insertions(+), 1 deletion(-) diff --git a/hw/ppc/spapr.c b/hw/ppc/spapr.c index d682f013d422..a2dcbee07214 100644 --- a/hw/ppc/spapr.c +++ b/hw/ppc/spapr.c @@ -3687,6 +3687,20 @@ static const TypeInfo sp

[Qemu-devel] [PATCH for-2.12 v2 03/12] spapr: introduce new XICSFabric operations for an IRQ allocator

2017-11-09 Thread Cédric Le Goater
Currently, the ICSState 'ics' object of the sPAPR machine acts as the global interrupt source handler and also as the IRQ number allocator for the machine. Some IRQ numbers are allocated very early in the machine initialization sequence to populate the device tree, and this is a problem to introduc

[Qemu-devel] [PATCH for-2.12 v2 02/12] ppc/xics: remove useless if condition

2017-11-09 Thread Cédric Le Goater
The previous code section uses a 'first < 0' test and returns. Therefore, there is no need to test the 'first' variable against '>= 0' afterwards. Signed-off-by: Cédric Le Goater --- hw/intc/xics_spapr.c | 6 ++ 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/hw/intc/xics_spapr

[Qemu-devel] [PATCH for-2.12 v2 04/12] spapr: move current IRQ allocation under the machine

2017-11-09 Thread Cédric Le Goater
Use the new XICSFabric operations to handle the IRQ number allocation directly under the machine. These changes only move code and adapt it to take into account the new API which uses IRQ numbers. On PowerNV, only provide a basic irq_test() operation. For the moment, there is no need for more. Si

[Qemu-devel] [PATCH for-2.12 v2 05/12] spapr: introduce an IRQ allocator using a bitmap

2017-11-09 Thread Cédric Le Goater
On the sPAPR platform, these IRQ operations are simply backed by a bitmap 'irq_map' in the machine. Older pseries machines do not have a bitmap acting as a IRQ number allocator but use the ICSIRQState array for this purpose. This difference between machine versions needs to be taken into account

[Qemu-devel] [PATCH for-2.12 v2 07/12] spapr: introduce an 'irq_base' number

2017-11-09 Thread Cédric Le Goater
'irq_base' is a base IRQ number which lets us allocate only the subset of the IRQ numbers used on the sPAPR platform. It is sync with the ICSState 'offset' attribute and this is slightly redundant. We could also choose to waste some extra bytes (512) and allocate the whole number space. To be discu

[Qemu-devel] [PATCH for-2.12 v2 06/12] spapr: store a reference IRQ bitmap

2017-11-09 Thread Cédric Le Goater
To save some state when the guest is migrated, we capture the IRQ bitmap after all devices have been reseted and store it as a reference for the machine. Signed-off-by: Cédric Le Goater --- hw/ppc/spapr.c | 5 - include/hw/ppc/spapr.h | 1 + 2 files changed, 5 insertions(+), 1 deleti

[Qemu-devel] [PATCH for-2.12 v2 08/12] spapr: remove the use of ics_valid_irq()

2017-11-09 Thread Cédric Le Goater
ics_valid_irq() can be replaced by a simple check on the 'srcno' number. It also removes a dependency on the ICSState object of the sPAPR machine. Signed-off-by: Cédric Le Goater --- hw/ppc/spapr.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/hw/ppc/spapr.c b/hw/ppc/spap

[Qemu-devel] [PATCH for-2.12 v2 09/12] spapr: introduce a XICSFabric irq_is_lsi() operation

2017-11-09 Thread Cédric Le Goater
It will be used later on to distinguish the allocation of an LSI interrupt from an MSI and also to reduce the use of the ICSIRQState array of the ICSState object, which is on our way to introduce XIVE. The 'irq' parameter continues to refer to the global IRQ number space. On PowerNV, only the PSI

[Qemu-devel] [PATCH for-2.12 v2 10/12] spapr: split the IRQ number space for LSI interrupts

2017-11-09 Thread Cédric Le Goater
The nature of an interrupt, MSI or LSI, is stored under the flag attribute of the ICSIRQState array. To reduce the use of this array and consequently of the ICSState object (needed to introduce for the new XIVE model), we choose to split the IRQ number space of the machine in two: first the LSIs an

Re: [Qemu-devel] [PATCH] hw/arm/aspeed: Unlock SCU when running kernel

2017-11-09 Thread Cédric Le Goater
On 11/08/2017 04:24 AM, Joel Stanley wrote: > The ASPEED hardware contains a lock register for the SCU that disables > any writes to the SCU when it is locked. The machine comes up with the > lock enabled, but on all known hardware u-boot will unlock it and leave > it unlocked when loading the kern

[Qemu-devel] [PATCH for-2.12 v2 11/12] sparp: merge ics_set_irq_type() in irq_alloc_block() operation

2017-11-09 Thread Cédric Le Goater
Setting the XICS_FLAGS_IRQ_LSI (or XICS_FLAGS_IRQ_MSI) for older pseries machines can now be done directly under the irq_alloc_block() operation. For compatibility with older machines, we use the machine class flag 'has_irq_bitmap'. Signed-off-by: Cédric Le Goater --- hw/intc/xics.c| 8

[Qemu-devel] [PATCH for-2.12 v2 12/12] spapr: use sPAPRMachineState in spapr_ics_ prototypes

2017-11-09 Thread Cédric Le Goater
The routines manipulating the IRQ numbers for the sPAPR machine do not have any relation with the ICSState anymore. So use a sPAPRMachineState parameter in their prototype and prefix them with spapr_irq_. Signed-off-by: Cédric Le Goater --- hw/intc/xics_spapr.c | 30

Re: [Qemu-devel] [PATCH v2 0/2] e1000e: Reimplement e1000 as a variant of e1000e

2017-11-09 Thread Daniel P. Berrange
FWIW, it is generally recommended that new versions of patch series be posted as a new top level thread, not in-reply-to the previous version. That way the new posting gets attention near top of a dev's email inbox, as opposed to hidden away as a reply to a weeks old msg at the back of the inbox.

Re: [Qemu-devel] [Qemu-block] RFC: use case for adding QMP, block jobs & multiple exports to qemu-nbd ?

2017-11-09 Thread Markus Armbruster
Max Reitz writes: > On 2017-11-02 13:02, Daniel P. Berrange wrote: > [...] >> One alternative approach to doing this would be to suggest that we should >> instead just spawn qemu-system-x86_64 with '--machine none' and use that >> as a replacement for qemu-nbd, since it already has a built-in NBD

Re: [Qemu-devel] [PATCH v2 0/5] tpm: Match frontend and backend buffer sizes (not 2.11)

2017-11-09 Thread Stefan Berger
On 11/09/2017 07:42 AM, Marc-André Lureau wrote: Reviewed-by: Marc-André Lureau Thanks! I added it to the tpm-next branch. https://github.com/stefanberger/qemu-tpm/commits/tpm-next Stefan

Re: [Qemu-devel] [PATCH v2] tpm_emulator: Add a caching layer for the TPM Established flag

2017-11-09 Thread Stefan Berger
On 11/09/2017 07:07 AM, Marc-André Lureau wrote: Hi On Wed, Nov 8, 2017 at 9:37 PM, Stefan Berger wrote: Add a caching layer for the TPM established flag so that we don't need to go to the emulator every time the flag is read by accessing the REG_ACCESS register. Signed-off-by: Stefan Berger

Re: [Qemu-devel] [PATCH V4] hw/pcie-pci-bridge: restrict to X86 and ARM

2017-11-09 Thread Thomas Huth
On 09.11.2017 14:04, no-re...@patchew.org wrote: > Hi, > > This series failed automatic build test. Please find the testing commands and > their output below. If you have docker installed, you can probably reproduce > it > locally. [...] > CC aarch64-softmmu/hw/scsi/virtio-scsi.o > CC

Re: [Qemu-devel] [PATCH 1/5] iotests: Make 030 less flaky

2017-11-09 Thread Eric Blake
On 11/08/2017 07:38 PM, Max Reitz wrote: > This patch fixes two race conditions in 030: > > 1. The first is in TestENSPC.test_enospc(). After resuming the job, s/ENSPC/ENOSPC/ >querying it to confirm it is no longer paused may fail because in the >meantime it might have completed alread

Re: [Qemu-devel] [PATCH 2/5] iotests: Add missing 'blkdebug::' in 040

2017-11-09 Thread Eric Blake
On 11/08/2017 07:38 PM, Max Reitz wrote: > 040 tries to invoke pause_drive() on a drive that does not use blkdebug. > Good idea, but let's use blkdebug to make it actually work. > > Signed-off-by: Max Reitz > --- > tests/qemu-iotests/040 | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) >

Re: [Qemu-devel] [PATCH 3/5] iotests: Make 055 less flaky

2017-11-09 Thread Eric Blake
On 11/08/2017 07:38 PM, Max Reitz wrote: > First of all, test 055 does a valiant job of invoking pause_drive() > sometimes, but that is worth nothing without blkdebug. So the first > thing to do is to sprinkle a couple of "blkdebug::" in there -- with the > exception of the transaction tests, beca

Re: [Qemu-devel] [PATCH V4] hw/pcie-pci-bridge: restrict to X86 and ARM

2017-11-09 Thread Marcel Apfelbaum
On 09/11/2017 15:04, no-re...@patchew.org wrote: Hi, This series failed automatic build test. Please find the testing commands and their output below. If you have docker installed, you can probably reproduce it locally. Subject: [Qemu-devel] [PATCH V4] hw/pcie-pci-bridge: restrict to X86 and AR

Re: [Qemu-devel] [PATCH V4] hw/pcie-pci-bridge: restrict to X86 and ARM

2017-11-09 Thread Marcel Apfelbaum
On 09/11/2017 16:03, Thomas Huth wrote: On 09.11.2017 14:04, no-re...@patchew.org wrote: Hi, This series failed automatic build test. Please find the testing commands and their output below. If you have docker installed, you can probably reproduce it locally. [...] CC aarch64-softmmu/

Re: [Qemu-devel] [PATCH 4/5] iotests: Make 083 less flaky

2017-11-09 Thread Eric Blake
On 11/08/2017 07:38 PM, Max Reitz wrote: > 083 has (at least) two issues: I think I hit one of them intermittently yesterday; thanks for diagnosing these (and like you say, there may be more lurking, but we'll whack them separately if we can reproduce and identify them). > > 1. By launching the

Re: [Qemu-devel] QMP event missed during startup

2017-11-09 Thread Markus Armbruster
"Dr. David Alan Gilbert" writes: > * Ross Lagerwall (ross.lagerw...@citrix.com) wrote: >> Hi, >> >> I have found an issue where QEMU emits the RESUME event during startup when >> it starts VM execution, but it is not possible to receive this event. >> >> To repro this, run: >> qemu-system-i386

Re: [Qemu-devel] [PATCH 5/5] iotests: Make 136 less flaky

2017-11-09 Thread Eric Blake
On 11/08/2017 07:38 PM, Max Reitz wrote: > 136 executes some AIO requests without a final aio_flush; then it > advances the virtual clock and thus expects the last access time of the > device to be less than the current time when queried (i.e. idle_time_ns > to be greater than 0). However, without

[Qemu-devel] [PATCH] blockdev-backup: enable non-root nodes for backup

2017-11-09 Thread Vladimir Sementsov-Ogievskiy
This is needed to implement image-fleecing scheme, when we create a temporary node, mark our active node to be backing for the temp, and start backup(sync=none) from active node to the temp node. Temp node then represents a kind of snapshot and may be used for external backup through NBD. Signed-o

Re: [Qemu-devel] [PATCH v2] coroutine: Fix documentation of co_aio_sleep_ns()

2017-11-09 Thread Eric Blake
On 11/08/2017 10:55 AM, Eric Blake wrote: > co_sleep_ns() was removed in commit 0b9caf9b, leaving behind a > stale comment. Update the documentation to match the current > usage of this function. > > Suggested-by: Paolo Bonzini > Signed-off-by: Eric Blake > > --- > v2: instead of just blindly

Re: [Qemu-devel] [PATCH V3] hw/pci-host: Fix x86 Host Bridges 64bit PCI hole

2017-11-09 Thread Marcel Apfelbaum
On 09/11/2017 13:02, Laszlo Ersek wrote: On 11/08/17 15:48, Marcel Apfelbaum wrote: Currently there is no MMIO range over 4G reserved for PCI hotplug. Since the 32bit PCI hole depends on the number of cold-plugged PCI devices and other factors, it is very possible is too small to hotplug PCI dev

Re: [Qemu-devel] [PATCH V4] hw/pcie-pci-bridge: restrict to X86 and ARM

2017-11-09 Thread Philippe Mathieu-Daudé
Hi Marcel, On 11/09/2017 11:10 AM, Marcel Apfelbaum wrote: > On 09/11/2017 16:03, Thomas Huth wrote: >> On 09.11.2017 14:04, no-re...@patchew.org wrote: >>> Hi, >>> >>> This series failed automatic build test. Please find the testing >>> commands and >>> their output below. If you have docker inst

Re: [Qemu-devel] [PATCH 1/3] trace: Simplify find_debugfs()

2017-11-09 Thread Namhyung Kim
Hello, On Thu, Nov 9, 2017 at 7:42 PM, Stefan Hajnoczi wrote: > On Wed, Nov 08, 2017 at 12:31:34AM +0900, Namhyung Kim wrote: >> The return vale of find_debugfs() is 1 if it could find a mount point of >> debugfs. It can be saved in the while loop instead of checking it again. >> >> Signed-off-b

Re: [Qemu-devel] [PATCH V4] hw/pcie-pci-bridge: restrict to X86 and ARM

2017-11-09 Thread Fam Zheng
On Thu, 11/09 16:08, Marcel Apfelbaum wrote: > > make[1]: *** No rule to make target `../hw/pci-bridge/pcie_pci_bridge.o', > > needed by `qemu-system-aarch64'. Stop. > > make[1]: *** Waiting for unfinished > > jobs/tmp/qemu-test/src/target/arm/translate-a64.c: In function > > 'handle_shri_w

Re: [Qemu-devel] [PATCH v4 04/45] tests: Replace fprintf(stderr, "*\n" with error_report()

2017-11-09 Thread Eric Blake
On 11/08/2017 04:56 PM, Alistair Francis wrote: > Replace a large number of the fprintf(stderr, "*\n" calls with > error_report(). The functions were renamed with these commands and then > compiler issues where manually fixed. s/where/were/ > > Some of the error_report()'s were manually kept as

Re: [Qemu-devel] [PATCH] smbios: support setting OEM strings table

2017-11-09 Thread Daniel P. Berrange
Ping, any thoughts on this ? (not expecting it in this 2.11 release of course) On Sat, Oct 28, 2017 at 09:51:36PM +0100, Daniel P. Berrange wrote: > The cloud-init program currently allows fetching of its data by repurposing of > the 'system' type 'serial' field. This is a clear abuse of the seria

[Qemu-devel] [Bug 1721221] Re: PCI-E passthrough of Nvidia GTX GFX card to Win 10 guest fails with "kvm_set_phys_mem: error registering slot: Invalid argument"

2017-11-09 Thread David Hildenbrand
** Changed in: qemu Status: Confirmed => Fix Committed -- You received this bug notification because you are a member of qemu- devel-ml, which is subscribed to QEMU. https://bugs.launchpad.net/bugs/1721221 Title: PCI-E passthrough of Nvidia GTX GFX card to Win 10 guest fails with "kvm

[Qemu-devel] [Bug 1731277] [NEW] Provide target specific qemu man pages

2017-11-09 Thread David Hildenbrand
Public bug reported: Right now, all qemu target binaries (qemu-system-...) share the same man page. The current man page is primarily focused on x86, and therefore the information given is entirely wrong for e.g. arm, powerpc or s390x. NAME qemu-doc - QEMU Emulator User Documentation SYN

[Qemu-devel] [PATCH RFC 0/3] TCG: do copy propagation through memory locations

2017-11-09 Thread Kirill Batuzov
This patch series is based on native-vector-registers-3: git://github.com/rth7680/qemu.git native-vector-registers-3 Particular goal of this change was to retain values of guest vector registers on host vector registers between different guest instructions. Relation between memory locations and

[Qemu-devel] [PATCH RFC 2/3] tcg/optimize: do copy propagation for memory locations

2017-11-09 Thread Kirill Batuzov
During copy propagation phase, keep track of memory locations that store value of a known live variable. Only memory locations that are addressed relative to ENV are accounted. Any other access types are handled conservatively. When a load is encountered, source memory location is checked against

[Qemu-devel] [PATCH RFC 1/3] tcg: support MOV_VEC and MOVI_VEC opcodes in register allocator

2017-11-09 Thread Kirill Batuzov
Signed-off-by: Kirill Batuzov --- tcg/tcg.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/tcg/tcg.c b/tcg/tcg.c index a7854a59a1..6db7dd526a 100644 --- a/tcg/tcg.c +++ b/tcg/tcg.c @@ -3327,10 +3327,12 @@ int tcg_gen_code(TCGContext *s, TranslationBlock *tb) switch (opc) {

[Qemu-devel] [PATCH RFC 3/3] tcg/optimize: handle vector loads and stores during copy propagation

2017-11-09 Thread Kirill Batuzov
Signed-off-by: Kirill Batuzov --- tcg/optimize.c | 22 ++ 1 file changed, 22 insertions(+) diff --git a/tcg/optimize.c b/tcg/optimize.c index da7f069444..1b6962c6c5 100644 --- a/tcg/optimize.c +++ b/tcg/optimize.c @@ -318,6 +318,8 @@ static TCGOpcode ld_to_mov(TCGOpcode op)

Re: [Qemu-devel] [PATCH v2 1/7] nbd-client: Fix error message typos

2017-11-09 Thread Eric Blake
On 11/09/2017 02:58 AM, Vladimir Sementsov-Ogievskiy wrote: > 09.11.2017 00:56, Eric Blake wrote: >> Provide missing spaces that are required when using string >> concatenation to break error messages across source lines. >> >> Signed-off-by: Eric Blake > > Reviewed-by: Vladimir Sementsov-Ogievsk

Re: [Qemu-devel] [PATCH v2 5/7] nbd-client: Short-circuit 0-length operations

2017-11-09 Thread Eric Blake
On 11/09/2017 03:20 AM, Vladimir Sementsov-Ogievskiy wrote: > 09.11.2017 00:57, Eric Blake wrote: >> The NBD spec was recently clarified to state that clients should >> not send 0-length requests to the server, as the server behavior >> is undefined [1].  We know that qemu-nbd's behavior is a succe

Re: [Qemu-devel] [PATCH v4 04/45] tests: Replace fprintf(stderr, "*\n" with error_report()

2017-11-09 Thread Philippe Mathieu-Daudé
On 11/09/2017 11:38 AM, Eric Blake wrote: > On 11/08/2017 04:56 PM, Alistair Francis wrote: [...] >> exit(-1); } qemu_thread_create(&threads[n_threads], "test", func, >> &data[n_threads], @@ -417,7 +418,7 @@ static void >> gtest_stress_10_5(void) >> >> static void usage(int argc, char *argv[]) { -

Re: [Qemu-devel] [PATCH v2 6/7] nbd-client: Stricter enforcing of structured reply spec

2017-11-09 Thread Eric Blake
On 11/09/2017 03:37 AM, Vladimir Sementsov-Ogievskiy wrote: > 09.11.2017 00:57, Eric Blake wrote: >> Ensure that the server is not sending unexpected chunk lengths >> for either the NONE or the OFFSET_DATA chunk, nor unexpected >> hole length for OFFSET_HOLE.  This will flag any server that >> resp

Re: [Qemu-devel] [PATCH] coroutine: simplify co_aio_sleep_ns() prototype

2017-11-09 Thread Eric Blake
On 11/09/2017 04:26 AM, Stefan Hajnoczi wrote: > The AioContext pointer argument to co_aio_sleep_ns() is only used for > the sleep timer. It does not affect where the caller coroutine is > resumed. > > Due to changes to coroutine and AIO APIs it is now possible to drop the > AioContext pointer ar

Re: [Qemu-devel] [RISU PATCH 07/10] risugen: add --sve support

2017-11-09 Thread Alex Bennée
Dave Martin writes: > On Tue, Nov 07, 2017 at 03:05:55PM +, Alex Bennée wrote: >> This is similar to the approach used by the FP/simd data in so far as >> we generate a block of random data and then load into it. As there are >> no post-index SVE operations we need to emit an additional incp

[Qemu-devel] [PATCH] Add mon pretty parameter to help documentation

2017-11-09 Thread Vicente Jimenez Aguilar
Signed-off-by: Vicente Jimenez Aguilar --- qemu-options.hx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/qemu-options.hx b/qemu-options.hx index 3728e9b4dd..2692a48f63 100644 --- a/qemu-options.hx +++ b/qemu-options.hx @@ -3477,7 +3477,7 @@ Like -qmp but uses pretty JSON for

  1   2   >