Re: [Qemu-devel] [Bug 1608802] [NEW] READ_DMA (0xC8) command does not work correctly

2016-08-01 Thread Stefan Weil
Am 02.08.2016 um 08:11 schrieb Stefan Weil: > Public bug reported: > > The QEMU PC emulation of DMA does not behave like real hardware or other > virtualization software. > > >From the original bug report (Benjamin David Lunt): > > Back to the READ_DMA command, it is my conclusion that the >

Re: [Qemu-devel] [PATCH v2 for-2.7] wxx: Fix handling of files used for character devices

2016-08-01 Thread Paolo Bonzini
On 02/08/2016 07:14, Stefan Weil wrote: > On Windows, such files were not truncated like on all other hosts. > Now we also test whether truncation is needed when running on Windows. > > The append case was also incorrect because it needs a different value > for the desired access mode. > > Repo

Re: [Qemu-devel] [PATCH] virtio-blk: Release s->rq queue at system_reset

2016-08-01 Thread Paolo Bonzini
On 29/07/2016 12:22, Fam Zheng wrote: > At system_reset, there is no point in retrying the queued request, > because the driver that issued the request won't be around any more. > > Analyzed-by: Laszlo Ersek > Reported-by: Laszlo Ersek > Signed-off-by: Fam Zheng > --- > hw/block/virtio-blk.c

Re: [Qemu-devel] [PATCH] qdev: Fix use after free in qdev_init_nofail error path

2016-08-01 Thread Paolo Bonzini
On 02/08/2016 06:00, John Snow wrote: > > > On 08/01/2016 11:41 PM, Fam Zheng wrote: >> Since 69382d8b (qdev: Fix object reference leak in case device.realize() >> fails), object_property_set_bool could release the object. The error >> path wants the type name, so hold an reference before reali

Re: [Qemu-devel] [RFC PATCH V10 3/7] Jhash: add linux kernel jhashtable in qemu

2016-08-01 Thread Jason Wang
On 2016年07月26日 09:49, Zhang Chen wrote: Jhash used by colo-compare and filter-rewriter to save and lookup net connection info Signed-off-by: Zhang Chen Signed-off-by: Li Zhijian Signed-off-by: Wen Congyang --- include/qemu/jhash.h | 61

Re: [Qemu-devel] [RFC PATCH V10 2/7] colo-base: add colo-base to define and handle packet

2016-08-01 Thread Jason Wang
On 2016年07月26日 09:49, Zhang Chen wrote: COLO-base used by colo-compare and filter-rewriter. s/used/is used/ this can share common data structure like:net packet, s/this/This/ and ':' looks unnecessary. and share other functions. s/share// Signed-off-by: Zhang Chen Signed-off-by: Li

Re: [Qemu-devel] [PATCH] vhost: don't set vring call if no vector

2016-08-01 Thread Cornelia Huck
On Tue, 2 Aug 2016 10:39:22 +0800 Jason Wang wrote: > On 2016年08月02日 02:00, Cornelia Huck wrote: > > On Mon, 1 Aug 2016 16:07:58 +0800 > > Jason Wang wrote: > >> +if (k->query_guest_notifiers && > >> +k->query_guest_notifiers(qbus->parent) && > >> +virtio_queue_vector(vdev,

Re: [Qemu-devel] Making cputlb.c operations safe for MTTCG

2016-08-01 Thread Alex Bennée
Paolo Bonzini writes: > On 26/07/2016 14:09, Alex Bennée wrote: >> >> As the eventual operation is the setting of a flag I'm wondering if we >> can simply use atomic primitives to ensure we don't corrupt the lookup >> address when setting the TLB_NOTDIRTY flag? > > In theory tlb_reset_dirty and

[Qemu-devel] [PATCH] xen: use a common function for pv and hvm guest backend register calls

2016-08-01 Thread Juergen Gross
Instead of calling xen_be_register() for each supported backend type for hvm and pv guests in their machine init functions use a common function in order not to have to add new backends twice. This at once fixes the error that hvm domains couldn't use the qusb backend. Signed-off-by: Juergen Gros

Re: [Qemu-devel] [RFC PATCH 00/11] Clock framework API.

2016-08-01 Thread KONRAD Frederic
Le 29/07/2016 à 15:59, Peter Maydell a écrit : On 13 June 2016 at 17:27, wrote: From: KONRAD Frederic Hi, This is a first draft of the clock framework API it contains: * The first 5 patches which introduce the framework. * The 6th patch which introduces a fixed-clock model. * Th

Re: [Qemu-devel] [RFC PATCH V10 1/7] colo-compare: introduce colo compare initialization

2016-08-01 Thread Jason Wang
On 2016年07月26日 09:49, Zhang Chen wrote: This a COLO net ascii figure: Primary qemu Secondary qemu +--+ +--

Re: [Qemu-devel] [PATCH] spapr: Don't support query-hotpluggable-cpus on earlier pseries machine types

2016-08-01 Thread Peter Krempa
On Tue, Aug 02, 2016 at 16:20:50 +1000, David Gibson wrote: > On Tue, Aug 02, 2016 at 10:34:34AM +0530, Bharata B Rao wrote: > > On Tue, Aug 02, 2016 at 02:25:08PM +1000, David Gibson wrote: > > > On Power, support for vCPU hotplug is new in qemu 2.7. However, we > > > currently implement the quer

[Qemu-devel] [Bug 1608802] [NEW] READ_DMA (0xC8) command does not work correctly

2016-08-01 Thread Stefan Weil
Public bug reported: The QEMU PC emulation of DMA does not behave like real hardware or other virtualization software. >From the original bug report (Benjamin David Lunt): Back to the READ_DMA command, it is my conclusion that the READ_DMA command, more precisely, the BUS Master part of

Re: [Qemu-devel] [PATCH] spapr: Don't support query-hotpluggable-cpus on earlier pseries machine types

2016-08-01 Thread David Gibson
On Tue, Aug 02, 2016 at 10:34:34AM +0530, Bharata B Rao wrote: > On Tue, Aug 02, 2016 at 02:25:08PM +1000, David Gibson wrote: > > On Power, support for vCPU hotplug is new in qemu 2.7. However, we > > currently implement the query_hotpluggable_cpus hook the same for all > > pseries machine type v

Re: [Qemu-devel] [RFC PATCH 1/3] hw/arm/virt: add hotplug memory support

2016-08-01 Thread kwangwoo....@sk.com
Hi, Thank you for the alignment information and discussion, Igor and Peter! I'll try to find out proper alignment by looking at the codes. Best Regards, Kwangwoo Lee > -Original Message- > From: Igor Mammedov [mailto:imamm...@redhat.com] > Sent: Monday, August 01, 2016 6:15 PM > To: Pet

Re: [Qemu-devel] [PATCHv3 RESEND] ppc: Rename #include'd .c files to .inc.c

2016-08-01 Thread David Gibson
On Mon, Aug 01, 2016 at 08:17:42PM +1000, Benjamin Herrenschmidt wrote: > Also while at it, group the #include statements in translate.c > > Signed-off-by: Benjamin Herrenschmidt Applied, thanks. > --- > target-ppc/translate.c | 40 > +++--- > .../t

Re: [Qemu-devel] [PATCH] ppc: Add MacOS VGA driver ROM

2016-08-01 Thread Benjamin Herrenschmidt
On Tue, 2016-08-02 at 07:25 +0200, Gerd Hoffmann wrote: > > That's the part we cannot provide unfortunately. There is sadly no > > toolchain that can produce a MacOS PEF binary other than hosted in > > MacOS itself. In fact I don't think Apple XCode can either, which > > leaves us with CodeWarrior

Re: [Qemu-devel] [PATCH] ppc: Add MacOS VGA driver ROM

2016-08-01 Thread Gerd Hoffmann
On Di, 2016-08-02 at 07:24 +1000, Benjamin Herrenschmidt wrote: > On Mon, 2016-08-01 at 21:38 +0200, Gerd Hoffmann wrote: > > Hi, > > > > > So, I believe qemu convention is to include the ROM source via a > > > submodule - even though it won't typically be built from there and > > the > > > preb

[Qemu-devel] [PATCH v2 for-2.7] wxx: Fix handling of files used for character devices

2016-08-01 Thread Stefan Weil
On Windows, such files were not truncated like on all other hosts. Now we also test whether truncation is needed when running on Windows. The append case was also incorrect because it needs a different value for the desired access mode. Reported-by: Benjamin David Lunt Signed-off-by: Stefan Weil

Re: [Qemu-devel] [PATCH for-2.7] wxx: Truncate files used for character devices

2016-08-01 Thread Stefan Weil
Am 01.08.2016 um 10:31 schrieb Paolo Bonzini: > On 26/07/2016 19:11, Stefan Weil wrote: >> On Windows, such files were not truncated like on all other hosts. >> Now we also test whether truncation is needed when running on Windows. >> >> Reported-by: Benjamin David Lunt >> Signed-off-by: Stefan We

[Qemu-devel] [PATCH v3] vfio : add aer process

2016-08-01 Thread Zhou Jie
During aer err occurs and resume do following to protect device from being accessed. 1. Make config space read only. 2. Disable INTx/MSI Interrupt. 3. Do nothing for bar regions. Signed-off-by: Zhou Jie --- v2-v3: 1. Call init_completion() in vfio_pci_probe. 2. Call reinit_completion() in v

Re: [Qemu-devel] [PATCH] qdev: Fix use after free in qdev_init_nofail error path

2016-08-01 Thread John Snow
On 08/01/2016 11:41 PM, Fam Zheng wrote: Since 69382d8b (qdev: Fix object reference leak in case device.realize() fails), object_property_set_bool could release the object. The error path wants the type name, so hold an reference before realizing it. Cc: Igor Mammedov Signed-off-by: Fam Zheng

[Qemu-devel] [PATCH] qdev: Fix use after free in qdev_init_nofail error path

2016-08-01 Thread Fam Zheng
Since 69382d8b (qdev: Fix object reference leak in case device.realize() fails), object_property_set_bool could release the object. The error path wants the type name, so hold an reference before realizing it. Cc: Igor Mammedov Signed-off-by: Fam Zheng --- hw/core/qdev.c | 2 ++ 1 file changed,

Re: [Qemu-devel] [PATCH for-2.7 1/1] ide: fix halted IO segfault at reset

2016-08-01 Thread John Snow
On 08/01/2016 04:52 AM, Paolo Bonzini wrote: On 27/07/2016 00:07, John Snow wrote: If one attempts to perform a system_reset after a failed IO request that causes the VM to enter a paused state, QEMU will segfault trying to free up the pending IO requests. These requests have already been c

Re: [Qemu-devel] [PATCH for-2.7 1/1] ide: fix halted IO segfault at reset

2016-08-01 Thread John Snow
On 08/01/2016 04:52 AM, Paolo Bonzini wrote: On 27/07/2016 00:07, John Snow wrote: If one attempts to perform a system_reset after a failed IO request that causes the VM to enter a paused state, QEMU will segfault trying to free up the pending IO requests. These requests have already been c

Re: [Qemu-devel] [PATCH] curl: Cast fd to int for DPRINTF

2016-08-01 Thread John Snow
On 08/01/2016 09:09 PM, Fam Zheng wrote: On Mon, 08/01 12:41, John Snow wrote: -DPRINTF("CURL (AIO): Sock action %d on fd %d\n", action, fd); +DPRINTF("CURL (AIO): Sock action %d on fd %d\n", action, (int)fd); switch (action) { case CURL_POLL_IN: aio_set_fd_h

Re: [Qemu-devel] [PATCH v3] x86: ioapic: add support for explicit EOI

2016-08-01 Thread Peter Xu
On Mon, Aug 01, 2016 at 04:43:26PM +0200, Igor Mammedov wrote: > > One thing to mention: this patch only applies to emulated IOAPIC. It > > does not affect kernel IOAPIC behavior. > ^^^ which is ? What I wanted to express is that this property will not taking e

Re: [Qemu-devel] [PATCH] vhost: don't set vring call if no vector

2016-08-01 Thread Jason Wang
On 2016年08月02日 02:00, Cornelia Huck wrote: On Mon, 1 Aug 2016 16:07:58 +0800 Jason Wang wrote: We used to set vring call fd unconditionally even if guest driver does not use MSIX for this vritqueue at all. This will cause lots of unnecessary userspace access and other checks for drivers doe

Re: [Qemu-devel] [PATCH] vhost: don't set vring call if no vector

2016-08-01 Thread Jason Wang
On 2016年08月01日 22:08, Michael S. Tsirkin wrote: On Mon, Aug 01, 2016 at 04:07:58PM +0800, Jason Wang wrote: We used to set vring call fd unconditionally even if guest driver does not use MSIX for this vritqueue at all. This will cause lots of unnecessary userspace access and other checks for d

Re: [Qemu-devel] [PATCH for 2.8 3/3] sdl: Modularize

2016-08-01 Thread Fam Zheng
On Mon, 08/01 12:31, Paolo Bonzini wrote: > > + > > +static void sdl_init_fn(void) > > +{ > > +sdl_register_init_fun(sdl_display_init_do); > > +} > > + > > +sdl_init(sdl_init_fn); > > Can you use __attribute__((constructor)) instead of going through the > burden of defining a new type? The re

Re: [Qemu-devel] [PATCH 1/2] xen: when removing a backend don't remove many of them

2016-08-01 Thread Stefano Stabellini
On Fri, 29 Jul 2016, Juergen Gross wrote: > When a Xenstore watch fires indicating a backend has to be removed > don't remove all backends for that domain with the specified device > index, but just the one which has the correct type. > > The easiest way to achieve this is to use the already deter

Re: [Qemu-devel] [PATCH v2 2/2] vfio : add aer process

2016-08-01 Thread Zhou Jie
Hi, Alex Clearly this has only been tested for a single instance of an AER error event and resume per device. Are the things you're intending to block actually blocked for subsequent events? Note how complete_all() fills the done field to let all current and future waiters go through and nowhe

Re: [Qemu-devel] [PATCH for 2.8 3/3] sdl: Modularize

2016-08-01 Thread Fam Zheng
On Mon, 08/01 13:53, Gerd Hoffmann wrote: > On Mi, 2016-07-27 at 14:26 +0800, Fam Zheng wrote: > > Signed-off-by: Fam Zheng > > more verbose commit message please, especially for those (like me) who > have not worked yet with modules. Yeah, my bad. Maybe I should have put RFC to the subject too.

Re: [Qemu-devel] [PATCH] virtio-blk: Remove stale comment about draining

2016-08-01 Thread Fam Zheng
On Mon, 08/01 15:45, Laszlo Ersek wrote: > The thing I mildly dislike about patches that consist purely of code > removal is that they don't show up in "git blame", so it's hard to get > credit for them :) Which is a shame, beacuse code deletion is the best > kind of patch! :) I can't agree more!

Re: [Qemu-devel] [PATCH] curl: Cast fd to int for DPRINTF

2016-08-01 Thread Fam Zheng
On Mon, 08/01 12:41, John Snow wrote: > > -DPRINTF("CURL (AIO): Sock action %d on fd %d\n", action, fd); > > +DPRINTF("CURL (AIO): Sock action %d on fd %d\n", action, (int)fd); > > switch (action) { > > case CURL_POLL_IN: > > aio_set_fd_handler(s->aio_context, fd,

Re: [Qemu-devel] [virtio-dev] Re: [PATCH v2 repost 4/7] virtio-balloon: speed up inflate/deflate process

2016-08-01 Thread Li, Liang Z
> > It's only small because it makes you rescan the free list. > > So maybe you should do something else. > > I looked at it a bit. Instead of scanning the free list, how about > > scanning actual page structures? If page is unused, pass it to host. > > Solves the problem of rescanning multiple tim

[Qemu-devel] [PATCH v8 03/10] tests: Add test code for meta bitmap

2016-08-01 Thread John Snow
From: Fam Zheng Signed-off-by: Fam Zheng Reviewed-by: John Snow Reviewed-by: Max Reitz Signed-off-by: John Snow --- tests/test-hbitmap.c | 116 +++ 1 file changed, 116 insertions(+) diff --git a/tests/test-hbitmap.c b/tests/test-hbitmap.c inde

[Qemu-devel] [PATCH v8 09/10] tests: Add test code for hbitmap serialization

2016-08-01 Thread John Snow
From: Fam Zheng Signed-off-by: Fam Zheng [Fixed minor constant issue. --js] Signed-off-by: John Snow Reviewed-by: Max Reitz Signed-off-by: John Snow --- tests/test-hbitmap.c | 139 +++ 1 file changed, 139 insertions(+) diff --git a/tests/test

[Qemu-devel] [PATCH v8 08/10] block: BdrvDirtyBitmap serialization interface

2016-08-01 Thread John Snow
From: Vladimir Sementsov-Ogievskiy Several functions to provide necessary access to BdrvDirtyBitmap for block-migration.c Signed-off-by: Vladimir Sementsov-Ogievskiy [Add the "finish" parameters. - Fam] Signed-off-by: Fam Zheng Reviewed-by: John Snow Reviewed-by: Max Reitz Signed-off-by: Jo

[Qemu-devel] [PATCH v8 01/10] block: Hide HBitmap in block dirty bitmap interface

2016-08-01 Thread John Snow
From: Fam Zheng HBitmap is an implementation detail of block dirty bitmap that should be hidden from users. Introduce a BdrvDirtyBitmapIter to encapsulate the underlying HBitmapIter. A small difference in the interface is, before, an HBitmapIter is initialized in place, now the new BdrvDirtyBitm

[Qemu-devel] [PATCH v8 05/10] block: Add two dirty bitmap getters

2016-08-01 Thread John Snow
From: Fam Zheng For dirty bitmap users to get the size and the name of a BdrvDirtyBitmap. Signed-off-by: Fam Zheng Reviewed-by: John Snow Reviewed-by: Max Reitz Signed-off-by: John Snow --- block/dirty-bitmap.c | 10 ++ include/block/dirty-bitmap.h | 2 ++ 2 files changed,

[Qemu-devel] [PATCH v8 07/10] hbitmap: serialization

2016-08-01 Thread John Snow
From: Vladimir Sementsov-Ogievskiy Functions to serialize / deserialize(restore) HBitmap. HBitmap should be saved to linear sequence of bits independently of endianness and bitmap array element (unsigned long) size. Therefore Little Endian is chosen. These functions are appropriate for dirty bit

[Qemu-devel] [PATCH v8 06/10] block: Assert that bdrv_release_dirty_bitmap succeeded

2016-08-01 Thread John Snow
From: Fam Zheng We use a loop over bs->dirty_bitmaps to make sure the caller is only releasing a bitmap owned by bs. Let's also assert that in this case the caller is releasing a bitmap that does exist. Signed-off-by: Fam Zheng Reviewed-by: Max Reitz Signed-off-by: John Snow --- block/dirty-

[Qemu-devel] [PATCH v8 10/10] block: More operations for meta dirty bitmap

2016-08-01 Thread John Snow
From: Fam Zheng Callers can create an iterator of meta bitmap with bdrv_dirty_meta_iter_new(), then use the bdrv_dirty_iter_* operations on it. Meta iterators are also counted by bitmap->active_iterators. Also add a couple of functions to retrieve granularity and count. Signed-off-by: Fam Zheng

[Qemu-devel] [PATCH v8 00/10] Dirty bitmap changes for migration/persistence work

2016-08-01 Thread John Snow
Key: [] : patches are identical [] : number of functional differences between upstream/downstream patch [down] : patch is downstream-only The flags [FC] indicate (F)unctional and (C)ontextual differences, respectively 001/10:[] [-C] 'block: Hide HBitmap in block dirty bitmap interface'

[Qemu-devel] [PATCH v8 02/10] HBitmap: Introduce "meta" bitmap to track bit changes

2016-08-01 Thread John Snow
From: Fam Zheng Upon each bit toggle, the corresponding bit in the meta bitmap will be set. Signed-off-by: Fam Zheng [Amended text inline. --js] Reviewed-by: Max Reitz Signed-off-by: John Snow --- include/qemu/hbitmap.h | 21 +++ util/hbitmap.c | 69 +

[Qemu-devel] [PATCH v8 04/10] block: Support meta dirty bitmap

2016-08-01 Thread John Snow
From: Fam Zheng The added group of operations enables tracking of the changed bits in the dirty bitmap. Signed-off-by: Fam Zheng Reviewed-by: Max Reitz Signed-off-by: John Snow --- block/dirty-bitmap.c | 52 include/block/dirty-bitmap.h |

Re: [Qemu-devel] [PATCH v2] balloon: Fix failure of updating guest memory status

2016-08-01 Thread Michael S. Tsirkin
On Mon, Aug 01, 2016 at 11:59:31PM +, Li, Liang Z wrote: > > On Wed, Jul 06, 2016 at 12:49:06PM +, Li, Liang Z wrote: > > > > > > > After live migration, 'guest-stats' can't get the expected > > > > > > > memory status in the guest. This issue is caused by commit > > 4eae2a657d. > > > > > >

Re: [Qemu-devel] [PATCH v9 1/8] loader: Allow ELF loader to auto-detect the ELF arch

2016-08-01 Thread Alistair Francis
On Fri, Jul 29, 2016 at 8:42 AM, Peter Maydell wrote: > On 14 July 2016 at 01:03, Alistair Francis > wrote: >> If the caller didn't specify an architecture for the ELF machine >> the load_elf() function will auto detect it based on the ELF file. >> >> Signed-off-by: Alistair Francis >> --- >> V

Re: [Qemu-devel] [PATCH v2] balloon: Fix failure of updating guest memory status

2016-08-01 Thread Li, Liang Z
> On Wed, Jul 06, 2016 at 12:49:06PM +, Li, Liang Z wrote: > > > > > > After live migration, 'guest-stats' can't get the expected > > > > > > memory status in the guest. This issue is caused by commit > 4eae2a657d. > > > > > > The value of 's->stats_vq_elem' will be NULL after live > > > > > >

Re: [Qemu-devel] [QEMU v2 1/9] virtio-balloon: Remove needless precompiled directive

2016-08-01 Thread Li, Liang Z
> * Liang Li (liang.z...@intel.com) wrote: > > Since there in wrapper around madvise(), the virtio-balloon code is > > able to work without the precompiled directive, the directive can be > > removed. > > > > Signed-off-by: Liang Li > > Suggested-by: Thomas Huth > > This one could be posted sepa

Re: [Qemu-devel] [Qemu-block] [PATCH 1/3] blockjob: fix dead pointer in txn list

2016-08-01 Thread John Snow
On 07/27/2016 06:49 AM, Vladimir Sementsov-Ogievskiy wrote: Job may be freed in block_job_unref and in this case this would break transaction QLIST. Fix this by removing job from this list before unref. Signed-off-by: Vladimir Sementsov-Ogievskiy --- blockjob.c | 1 + 1 file changed, 1 insert

Re: [Qemu-devel] [PATCH] ppc: Add MacOS VGA driver ROM

2016-08-01 Thread Benjamin Herrenschmidt
On Mon, 2016-08-01 at 21:38 +0200, Gerd Hoffmann wrote: >   Hi, > > > So, I believe qemu convention is to include the ROM source via a > > submodule - even though it won't typically be built from there and > the > > prebuilt blob will be used instead. > > Correct.  Also rules in roms/Makefile to

Re: [Qemu-devel] [PATCH 1/2] ide: ide-cd without drive property for empty drive

2016-08-01 Thread Kevin Wolf
Am 14.07.2016 um 21:48 hat Eric Blake geschrieben: > On 07/14/2016 07:49 AM, Kevin Wolf wrote: > > This allows to create an empty ide-cd device without manually creating a > > BlockBackend. > > > > Signed-off-by: Kevin Wolf > > --- > > hw/ide/qdev.c | 20 +++- > > 1 file changed,

Re: [Qemu-devel] [PATCH] ppc: Add MacOS VGA driver ROM

2016-08-01 Thread Gerd Hoffmann
Hi, > So, I believe qemu convention is to include the ROM source via a > submodule - even though it won't typically be built from there and the > prebuilt blob will be used instead. Correct. Also rules in roms/Makefile to build the thing, to document the build process and to simplify the maint

Re: [Qemu-devel] [PATCH v2 1/1] KVM: PPC: Introduce KVM_CAP_PPC_HTM

2016-08-01 Thread Paolo Bonzini
On 20/07/2016 08:30, Paolo Bonzini wrote: > In particular this patch would indeed have a conflict, because you have > > +#define KVM_CAP_PPC_HTM 129 > > but cap numbers 129 and 130 are already taken. So whoever applies it > should bump the number to 131. Applied now, it's 132. Paolo

Re: [Qemu-devel] [PATCH] vhost: don't set vring call if no vector

2016-08-01 Thread Cornelia Huck
On Mon, 1 Aug 2016 16:07:58 +0800 Jason Wang wrote: > We used to set vring call fd unconditionally even if guest driver does > not use MSIX for this vritqueue at all. This will cause lots of > unnecessary userspace access and other checks for drivers does not use > interrupt at all (e.g virtio-n

Re: [Qemu-devel] [PATCH for-2.7] Xen PCI passthrough: fix passthrough failure when no interrupt pin

2016-08-01 Thread Bruce Rogers
Hi Cao, Upon re-reading your comment, I believe you are still thinking that it was right to use the error object in this context. The fact that this device has no pin interrupt is _not_ an error condition, and hence the use of error_setg() is not appropriate, and in fact causes Xen HVM PCI p

Re: [Qemu-devel] [PATCH] curl: Cast fd to int for DPRINTF

2016-08-01 Thread John Snow
On 08/01/2016 01:04 AM, Fam Zheng wrote: Currently "make docker-test-mingw@fedora" has a warning like: /tmp/qemu-test/src/block/curl.c: In function 'curl_sock_cb': /tmp/qemu-test/src/block/curl.c:172:6: warning: format '%d' expects argument of type 'int', but argument 4 has type 'c

Re: [Qemu-devel] [PULL v5 29/57] intel_iommu: add SID validation for IR

2016-08-01 Thread Jan Kiszka
On 2016-07-21 19:53, Michael S. Tsirkin wrote: > From: Peter Xu > > This patch enables SID validation. Invalid interrupts will be dropped. > > Signed-off-by: Peter Xu > Reviewed-by: Michael S. Tsirkin > Signed-off-by: Michael S. Tsirkin > --- > include/hw/i386/intel_iommu.h | 17 +++

Re: [Qemu-devel] [PATCH v1 1/1] MAINTAINERS: Update the Xilinx maintainers

2016-08-01 Thread Alistair Francis
On Mon, Aug 1, 2016 at 7:32 AM, Peter Maydell wrote: > On 28 July 2016 at 17:55, Alistair Francis > wrote: >> Update the Xilinx maintainers documentation to simplify what we maintain >> and cover all of our upstream code. >> >> Signed-off-by: Alistair Francis > > Mailing list seems not to have

Re: [Qemu-devel] [PATCH 6/7] qemu: Implement virtio-pstore device

2016-08-01 Thread Namhyung Kim
On Mon, Aug 01, 2016 at 10:24:39AM +0100, Daniel P. Berrange wrote: > On Sat, Jul 30, 2016 at 05:57:02PM +0900, Namhyung Kim wrote: > > On Thu, Jul 28, 2016 at 02:22:39PM +0100, Daniel P. Berrange wrote: > > > > +static void virtio_pstore_from_filename(VirtIOPstore *s, char *name, > > > > +

Re: [Qemu-devel] [PATCH v2 2/2] vfio : add aer process

2016-08-01 Thread Alex Williamson
On Mon, 1 Aug 2016 10:14:06 +0800 Zhou Jie wrote: > Hi, Alex > > On 2016/7/30 1:12, Alex Williamson wrote: > > On Tue, 19 Jul 2016 15:32:43 +0800 > > Zhou Jie wrote: > > > >> From: Chen Fan > >> > >> During aer err occurs and resume do following to > >> protect device from being accessed. >

Re: [Qemu-devel] [PATCH 6/7] qemu: Implement virtio-pstore device

2016-08-01 Thread Namhyung Kim
Hi Daniel, On Mon, Aug 01, 2016 at 10:21:30AM +0100, Daniel P. Berrange wrote: > On Sat, Jul 30, 2016 at 05:38:27PM +0900, Namhyung Kim wrote: > > Hello, > > > > On Thu, Jul 28, 2016 at 02:08:41PM +0100, Daniel P. Berrange wrote: > > > On Thu, Jul 28, 2016 at 01:56:07PM +0100, Stefan Hajnoczi wro

Re: [Qemu-devel] [PATCH] mptsas: Fix a migration compatible issue

2016-08-01 Thread Amit Shah
On (Mon) 01 Aug 2016 [10:16:50], Paolo Bonzini wrote: > > > On 26/07/2016 11:03, Cao jin wrote: > > My previous commit 2e2aa316 removed internal flag msi_in_use, which > > exists in vmstate, use VMSTATE_UNUSED for migration compatibility. > > > > Reported-by: Amit Shah > > Suggested-by: Amit Sh

Re: [Qemu-devel] [PATCH] help: Update help to reflect that GTK is the default

2016-08-01 Thread Markus Armbruster
Paolo Bonzini writes: > On 27/07/2016 18:21, Colin Lord wrote: >> Updates the messages displayed in the help option to reflect that GTK is >> the default display, not SDL. >> --- >> qemu-options.hx | 16 >> 1 file changed, 12 insertions(+), 4 deletions(-) >> >> diff --git a/qem

Re: [Qemu-devel] [PATCH v2 1/1] Reorganize help output of '-display' option

2016-08-01 Thread Markus Armbruster
Robert Ho writes: > The '-display' help information is not very correct. This patch sort > it a little. > Also, in its help information, reveals what implicit display option > will be chosen if no definition. > > Changelog: > v2: > --fix typo of 'display' > --change some discription words > > S

Re: [Qemu-devel] [PATCH v3] x86: ioapic: add support for explicit EOI

2016-08-01 Thread Paolo Bonzini
On 01/08/2016 15:59, Peter Xu wrote: > Some old Linux kernels (upstream before v4.0), or any released RHEL > kernels has problem in sending APIC EOI when IR is enabled. Meanwhile, > many of them only support explicit EOI for IOAPIC, which is only > introduced in IOAPIC version 0x20. This patch pr

Re: [Qemu-devel] [PATCH RFC 1/1] arm64: add an option to turn on/off vpmu support

2016-08-01 Thread Andrea Bolognani
On Mon, 2016-08-01 at 14:32 +0100, Peter Maydell wrote: > > Wouldn't that mean that you'd be unable to use > >  > >   -cpu foo,pmu=off > >  > > if CPU model 'foo' doesn't support a PMU? I'd expect that > > to work. >  > The current precedent (has_el3) doesn't work like that: if > foo isn't a CPU wh

Re: [Qemu-devel] Making cputlb.c operations safe for MTTCG

2016-08-01 Thread Paolo Bonzini
On 26/07/2016 14:09, Alex Bennée wrote: > > As the eventual operation is the setting of a flag I'm wondering if we > can simply use atomic primitives to ensure we don't corrupt the lookup > address when setting the TLB_NOTDIRTY flag? In theory tlb_reset_dirty and tlb_set_dirty1 can use atomic_*

Re: [Qemu-devel] [PATCH v3] x86: ioapic: add support for explicit EOI

2016-08-01 Thread Paolo Bonzini
On 01/08/2016 16:43, Igor Mammedov wrote: > > To be compatible with old systems, 0x11 will still be the default IOAPIC > > version. Here 0x11 and 0x20 are the only versions to be supported. > > Is there a reason not to default to 0x20 for new machine types and > set 2.6 and older machine types t

Re: [Qemu-devel] [PATCH v3] x86: ioapic: add support for explicit EOI

2016-08-01 Thread Igor Mammedov
On Mon, 1 Aug 2016 21:59:19 +0800 Peter Xu wrote: > Some old Linux kernels (upstream before v4.0), or any released RHEL > kernels has problem in sending APIC EOI when IR is enabled. Meanwhile, > many of them only support explicit EOI for IOAPIC, which is only > introduced in IOAPIC version 0x20.

Re: [Qemu-devel] [PATCH] MAINTAINERS: Add Host Memory Backends section

2016-08-01 Thread Markus Armbruster
Eduardo Habkost writes: > The hostmem code is closely related to the NUMA code, so I am > willing to handle patches to those files and share the work with > Igor (the original author of that code). > > Signed-off-by: Eduardo Habkost Thanks, Eduardo! Reviewed-by: Markus Armbruster

Re: [Qemu-devel] [PATCH v1 1/1] MAINTAINERS: Update the Xilinx maintainers

2016-08-01 Thread Peter Maydell
On 28 July 2016 at 17:55, Alistair Francis wrote: > Update the Xilinx maintainers documentation to simplify what we maintain > and cover all of our upstream code. > > Signed-off-by: Alistair Francis Mailing list seems not to have got this one second time around either -- maybe some spam filter d

Re: [Qemu-devel] [PATCH] Fix bsd-user build errors after 8642c1b81e0418df066a7960a7426d85a923a253

2016-08-01 Thread Peter Maydell
On 29 July 2016 at 17:02, Sean Bruno wrote: > LINK sparc-bsd-user/qemu-sparc > bsd-user/main.o: In function `cpu_loop': > /home/sbruno/bsd/qemu/bsd-user/main.c:515: undefined reference to > `cpu_sparc_exec' > c++: error: linker command failed with exit code 1 (use -v to see invocation) > gmake

Re: [Qemu-devel] [PATCH] block/iscsi: Adding iser support in Libiscsi-QEMU

2016-08-01 Thread Roy Shterman
On 8/1/2016 4:52 PM, Paolo Bonzini wrote: On 28/07/2016 10:45, Peter Lieven wrote: Furthermore I would suggest using LIBISCS_FEATURE_ISER and not the API version in the preprocessor commands. Actually I disagree with this suggestion. The new API could be used also if iSER is not used, can i

Re: [Qemu-devel] [PATCH] MAINTAINERS: Add Host Memory Backends section

2016-08-01 Thread Igor Mammedov
On Mon, 1 Aug 2016 10:52:42 -0300 Eduardo Habkost wrote: > The hostmem code is closely related to the NUMA code, so I am > willing to handle patches to those files and share the work with > Igor (the original author of that code). > > Signed-off-by: Eduardo Habkost > --- > MAINTAINERS | 7 +++

Re: [Qemu-devel] [PATCH v4 07/11] block: Accept node-name for change-backing-file

2016-08-01 Thread Alberto Garcia
On Thu 14 Jul 2016 03:28:10 PM CEST, Kevin Wolf wrote: > In order to remove the necessity to use BlockBackend names in the > external API, we want to allow node-names everywhere. This converts > change-backing-file to accept a node-name without lifting the > restriction that we're operating at a ro

Re: [Qemu-devel] [PATCH] vhost: don't set vring call if no vector

2016-08-01 Thread Michael S. Tsirkin
On Mon, Aug 01, 2016 at 04:07:58PM +0800, Jason Wang wrote: > We used to set vring call fd unconditionally even if guest driver does > not use MSIX for this vritqueue at all. This will cause lots of > unnecessary userspace access and other checks for drivers does not use > interrupt at all (e.g vir

[Qemu-devel] [PATCH RFC] block/vxhs: Initial commit to add Veritas HyperScale VxHS block device support

2016-08-01 Thread Ashish Mittal
This patch adds support for a new block device type called "vxhs". Source code for the library that this code loads can be downloaded from: https://github.com/MittalAshish/libqnio.git Signed-off-by: Ashish Mittal --- block/Makefile.objs |1 + block/vxhs.c| 1460 ++

Re: [Qemu-devel] [PATCH for 2.8?] x86: ioapic: ignore level irq during processing

2016-08-01 Thread Peter Xu
On Mon, Aug 01, 2016 at 12:58:42PM +0200, Paolo Bonzini wrote: > > > On 31/07/2016 16:18, Peter Xu wrote: > > For level triggered interrupts, we will get Remote IRR bit cleared after > > guest kernel finished processing specific request. Before that, we > > should ignore the same interrupt from t

Re: [Qemu-devel] [PATCH v4 08/11] block: Accept node-name for drive-backup

2016-08-01 Thread Alberto Garcia
On Thu 14 Jul 2016 03:28:11 PM CEST, Kevin Wolf wrote: > In order to remove the necessity to use BlockBackend names in the > external API, we want to allow node-names everywhere. This converts > drive-backup and the corresponding transaction action to accept a > node-name without lifting the restri

[Qemu-devel] [PATCH RFC] Addition of Veritas HyperScale VxHS block device support

2016-08-01 Thread Ashish Mittal
This is a request to include a new block device protocol called vxhs in qemu. Following work items have been completed: (1) Rebase VxHS code to latest qemu master. (2) Removed all errors/warnings found by checkpatch.pl (3) Unit-tested qemu and qemu-io binaries to ensure that we are able to open a

Re: [Qemu-devel] [PATCH v2] x86: ioapic: conditionally upgrade IOAPIC version

2016-08-01 Thread Peter Xu
On Mon, Aug 01, 2016 at 12:38:58PM +0200, Paolo Bonzini wrote: > > > On 26/07/2016 05:28, Peter Xu wrote: > > IOMMU IR and IOAPIC legacy devices (e.g., e1000) cannot work well > > together with some old Linux kernels (upstream before v4.0, or any > > released RHEL kernels). This patch fixes it. >

[Qemu-devel] [PATCH v3] x86: ioapic: add support for explicit EOI

2016-08-01 Thread Peter Xu
Some old Linux kernels (upstream before v4.0), or any released RHEL kernels has problem in sending APIC EOI when IR is enabled. Meanwhile, many of them only support explicit EOI for IOAPIC, which is only introduced in IOAPIC version 0x20. This patch provide a way to boost QEMU IOAPIC to version 0x2

[Qemu-devel] [PATCH RFC] block/vxhs: Initial commit to add Veritas HyperScale VxHS block device support

2016-08-01 Thread Ashish Mittal
This patch adds support for a new block device type called "vxhs". Source code for the library that this code loads can be downloaded from: https://github.com/MittalAshish/libqnio.git Signed-off-by: Ashish Mittal --- block/Makefile.objs |1 + block/vxhs.c| 1460 ++

[Qemu-devel] [PATCH RFC] Addition of Veritas HyperScale VxHS block device support

2016-08-01 Thread Ashish Mittal
This is a request to include a new block device protocol called vxhs in qemu. Following work items have been completed: (1) Rebase VxHS code to latest qemu master. (2) Removed all errors/warnings found by checkpatch.pl (3) Unit-tested qemu and qemu-io binaries to ensure that we are able to open a

Re: [Qemu-devel] [PATCH v4 06/11] block: Accept node-name for blockdev-snapshot-internal-sync

2016-08-01 Thread Alberto Garcia
On Thu 14 Jul 2016 03:28:09 PM CEST, Kevin Wolf wrote: > In order to remove the necessity to use BlockBackend names in the > external API, we want to allow node-names everywhere. This converts > blockdev-snapshot-internal-sync to accept a node-name without lifting > the restriction that we're opera

[Qemu-devel] [PATCH] MAINTAINERS: Add Host Memory Backends section

2016-08-01 Thread Eduardo Habkost
The hostmem code is closely related to the NUMA code, so I am willing to handle patches to those files and share the work with Igor (the original author of that code). Signed-off-by: Eduardo Habkost --- MAINTAINERS | 7 +++ 1 file changed, 7 insertions(+) diff --git a/MAINTAINERS b/MAINTAIN

Re: [Qemu-devel] [PATCH] block/iscsi: Adding iser support in Libiscsi-QEMU

2016-08-01 Thread Paolo Bonzini
On 28/07/2016 10:45, Peter Lieven wrote: > > Furthermore I would suggest using LIBISCS_FEATURE_ISER and not the API > version in the > preprocessor commands. Actually I disagree with this suggestion. The new API could be used also if iSER is not used, can it? Thanks, Paolo

Re: [Qemu-devel] [PATCH] block/iscsi: Adding iser support in Libiscsi-QEMU

2016-08-01 Thread Paolo Bonzini
On 27/07/2016 12:02, Roy Shterman wrote: > iSER is a new transport layer supported in Libiscsi, > iSER provides a zero-copy RDMA capable interface that can > improve performance. > > New API is introduced in abstracion of the Libiscsi transport layer. > In order to use the new iSER transport, on

Re: [Qemu-devel] [PATCH] util: Relax assertion in iov_copy()

2016-08-01 Thread Paolo Bonzini
On 25/07/2016 13:43, Shmulik Ladkani wrote: > From: Shmulik Ladkani > > In cases where iov_copy() is passed with zero 'bytes' argument and a > non-zero 'offset' argument, nothing gets copied - as expected. > > However since no copy iterations are performed, 'offset' is left > unaltered, leadin

Re: [Qemu-devel] [PATCH] virtio-blk: Remove stale comment about draining

2016-08-01 Thread Laszlo Ersek
On 08/01/16 04:53, Fam Zheng wrote: > This is stale after commit 6e40b3bf (virtio-blk: Use blk_drain() to > drain IO requests), remove it. > > Suggested-by: Laszlo Ersek > Signed-off-by: Fam Zheng > --- > hw/block/virtio-blk.c | 4 > 1 file changed, 4 deletions(-) > > diff --git a/hw/bloc

Re: [Qemu-devel] [PATCH v4 05/11] block: Accept node-name for blockdev-snapshot-delete-internal-sync

2016-08-01 Thread Alberto Garcia
On Thu 14 Jul 2016 03:28:08 PM CEST, Kevin Wolf wrote: > In order to remove the necessity to use BlockBackend names in the > external API, we want to allow node-names everywhere. This converts > blockdev-snapshot-delete-internal-sync to accept a node-name without > lifting the restriction that we'r

Re: [Qemu-devel] [PATCH v4 04/11] block: Accept node-name for blockdev-mirror

2016-08-01 Thread Alberto Garcia
On Thu 14 Jul 2016 03:28:07 PM CEST, Kevin Wolf wrote: > In order to remove the necessity to use BlockBackend names in the > external API, we want to allow node-names everywhere. This converts > blockdev-mirror to accept a node-name without lifting the restriction > that we're operating at a root n

Re: [Qemu-devel] [PATCH RFC 1/1] arm64: add an option to turn on/off vpmu support

2016-08-01 Thread Peter Maydell
On 1 August 2016 at 14:26, Andrea Bolognani wrote: > On Mon, 2016-08-01 at 15:08 +0200, Andrew Jones wrote: >> > I'm not sure a warning is enough: if I start a guest and >> > explicitly ask for a PMU, I expect it to be there, or for >> > the guest not to start at all. How does x86 behave in this >

Re: [Qemu-devel] [PATCH v4 02/11] block: Accept node-name for block-commit

2016-08-01 Thread Alberto Garcia
On Thu 14 Jul 2016 03:28:05 PM CEST, Kevin Wolf wrote: > -blk = blk_by_name(device); > -if (!blk) { > -error_set(errp, ERROR_CLASS_DEVICE_NOT_FOUND, > - "Device '%s' not found", device); > +bs = qmp_get_root_bs(device, &local_err); > +if (!bs) { > +b

Re: [Qemu-devel] [PATCH RFC 1/1] arm64: add an option to turn on/off vpmu support

2016-08-01 Thread Andrea Bolognani
On Mon, 2016-08-01 at 15:08 +0200, Andrew Jones wrote: > > I'm not sure a warning is enough: if I start a guest and > > explicitly ask for a PMU, I expect it to be there, or for > > the guest not to start at all. How does x86 behave in this > > regard? >  > Peter had a good suggestion for this. We

Re: [Qemu-devel] [PATCH v4 01/11] block: Accept node-name for block-stream

2016-08-01 Thread Alberto Garcia
On Thu 14 Jul 2016 03:28:04 PM CEST, Kevin Wolf wrote: > In order to remove the necessity to use BlockBackend names in the > external API, we want to allow node-names everywhere. This converts > block-stream to accept a node-name without lifting the restriction that > we're operating at a root node

Re: [Qemu-devel] [PATCH RFC 1/1] arm64: add an option to turn on/off vpmu support

2016-08-01 Thread Peter Maydell
On 1 August 2016 at 14:08, Andrew Jones wrote: > Peter had a good suggestion for this. We need to wrap the property > addition in an arm_feature check like the has_el3 property. That will > remove it from all cpu types that don't support it. Then there's no > need for the enable_pmu && !has_pmu ch

  1   2   >