[Qemu-devel] [PATCH 14/15] vnc-tight: make the encoding palette static

2016-06-28 Thread Peter Lieven
for the calculation of number of subcolors of each subrect a new palette was allocated, memset to zero and then destroyed. Use a static palette for this instead. Signed-off-by: Peter Lieven <p...@kamp.de> --- ui/vnc-enc-tight.c | 21 ++--- ui/vnc.h | 1 + 2

[Qemu-devel] [PATCH 09/15] loader: use mmap for ROMs

2016-06-28 Thread Peter Lieven
a classic use for mmap here. Signed-off-by: Peter Lieven <p...@kamp.de> --- hw/core/loader.c | 16 +++- 1 file changed, 7 insertions(+), 9 deletions(-) diff --git a/hw/core/loader.c b/hw/core/loader.c index 53e0e41..f217edc 100644 --- a/hw/core/loader.c +++ b/hw/core/lo

[Qemu-devel] [PATCH 04/15] coroutine: add a knob to disable the shared release pool

2016-06-28 Thread Peter Lieven
is used it should be made sure that all fast block devices use virtio and each virtio device has its own thread (dataplane). An IDE cdrom might still be used, but coroutine creation will be slow, but a CDROM is considred slow anyway. Signed-off-by: Peter Lieven <p...@kamp.de> --- con

[Qemu-devel] [PATCH 13/15] exec: use mmap for PhysPageMap->nodes

2016-06-28 Thread Peter Lieven
this was causing serious framentation in conjunction with the subpages since RCU was introduced. The node space was allocated at approx 32kB then reallocted to approx 75kB and this a few hundred times at startup. And thanks to RCU the freeing was delayed. Signed-off-by: Peter Lieven <p...@kamp

[Qemu-devel] [PATCH 02/15] coroutine-ucontext: add a switch to monitor maximum stack size

2016-06-28 Thread Peter Lieven
this adds a debug configure switch to enable monitoring of the maximum used stack size by all coroutines. Signed-off-by: Peter Lieven <p...@kamp.de> --- configure | 18 ++ util/coroutine-ucontext.c | 40 2 files chang

[Qemu-devel] [PATCH 11/15] qom: use mmap for bigger Objects

2016-06-28 Thread Peter Lieven
Signed-off-by: Peter Lieven <p...@kamp.de> --- include/qom/object.h | 1 + qom/object.c | 20 +--- 2 files changed, 18 insertions(+), 3 deletions(-) diff --git a/include/qom/object.h b/include/qom/object.h index 2f8ac47..c612f3a 100644 --- a/include/qom/object.h

[Qemu-devel] [PATCH 00/15] optimize Qemu RSS usage

2016-06-28 Thread Peter Lieven
systems. Peter Lieven (15): coroutine-ucontext: mmap stack memory coroutine-ucontext: add a switch to monitor maximum stack size coroutine-ucontext: reduce stack size to 64kB coroutine: add a knob to disable the shared release pool util: add a helper to mmap private anonymous memory exec: use

[Qemu-devel] [PATCH 01/15] coroutine-ucontext: mmap stack memory

2016-06-28 Thread Peter Lieven
at the bottom of the stack to avoid overflows. Suggested-by: Peter Maydell <peter.mayd...@linaro.org> Signed-off-by: Peter Lieven <p...@kamp.de> --- util/coroutine-ucontext.c | 26 +++--- 1 file changed, 23 insertions(+), 3 deletions(-) diff --git a/util/coroutine-ucont

[Qemu-devel] [PATCH 15/15] vnc: use mmap for VncState

2016-06-28 Thread Peter Lieven
the VncState is approx. 85kB Signed-off-by: Peter Lieven <p...@kamp.de> --- ui/vnc.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/ui/vnc.c b/ui/vnc.c index 95e4db7..bf87135 100644 --- a/ui/vnc.c +++ b/ui/vnc.c @@ -45,6 +45,7 @@ #include "crypto/tls

[Qemu-devel] [PATCH 03/15] coroutine-ucontext: reduce stack size to 64kB

2016-06-28 Thread Peter Lieven
evaluation with the recently introduced maximum stack size monitoring revealed that the actual used stack size was never above 4kB so allocating 1MB stack for each coroutine is a lot of wasted memory. So reduce the stack size to 64kB which should still give enough head room. Signed-off-by: Peter

Re: [Qemu-devel] Regression: virtio-pci: convert to ioeventfd callbacks

2016-06-28 Thread Peter Lieven
Am 28.06.2016 um 09:42 schrieb Cornelia Huck: On Tue, 28 Jun 2016 10:03:21 +0300 "Michael S. Tsirkin" wrote: I notice cleanup is a bit weird: virtio_queue_set_host_notifier_fd_handler(vq, false, false); k->ioeventfd_assign(proxy, notifier, n, assign);

Re: [Qemu-devel] Regression: virtio-pci: convert to ioeventfd callbacks

2016-06-28 Thread Peter Lieven
Am 27.06.2016 um 17:09 schrieb Cornelia Huck: On Mon, 27 Jun 2016 11:44:47 +0200 Peter Lieven <p...@kamp.de> wrote: Hi, with the above patch applied: commit 9f06e71a567ba5ee8b727e65a2d5347fd331d2aa Author: Cornelia Huck <cornelia.h...@de.ibm.com> Date: Fri Jun 10 11:04:1

Re: [Qemu-devel] Qemu and heavily increased RSS usage

2016-06-27 Thread Peter Lieven
> Am 27.06.2016 um 14:39 schrieb Stefan Hajnoczi <stefa...@gmail.com>: > >> On Fri, Jun 24, 2016 at 12:45:49PM +0200, Peter Lieven wrote: >>> Am 24.06.2016 um 11:58 schrieb Peter Maydell: >>>> On 24 June 2016 at 10:37, Stefan Hajnoczi <stefa...@gmail.co

[Qemu-devel] Regression: virtio-pci: convert to ioeventfd callbacks

2016-06-27 Thread Peter Lieven
Hi, with the above patch applied: commit 9f06e71a567ba5ee8b727e65a2d5347fd331d2aa Author: Cornelia Huck Date: Fri Jun 10 11:04:12 2016 +0200 virtio-pci: convert to ioeventfd callbacks a Ubuntu 14.04 VM freezes at startup when blk-mq is set up - even if there is

Re: [Qemu-devel] Qemu and heavily increased RSS usage

2016-06-24 Thread Peter Lieven
Am 24.06.2016 um 11:58 schrieb Peter Maydell: > On 24 June 2016 at 10:37, Stefan Hajnoczi <stefa...@gmail.com> wrote: >> On Wed, Jun 22, 2016 at 09:56:06PM +0100, Peter Maydell wrote: >>> On 22 June 2016 at 20:55, Peter Lieven <p...@kamp.de> wrote: >>>

Re: [Qemu-devel] Qemu and heavily increased RSS usage

2016-06-24 Thread Peter Lieven
Am 24.06.2016 um 11:37 schrieb Stefan Hajnoczi: > On Wed, Jun 22, 2016 at 09:56:06PM +0100, Peter Maydell wrote: >> On 22 June 2016 at 20:55, Peter Lieven <p...@kamp.de> wrote: >>> What makes the coroutine pool memory intensive is the stack size of 1MB per >>>

Re: [Qemu-devel] Qemu and heavily increased RSS usage

2016-06-24 Thread Peter Lieven
Am 24.06.2016 um 10:20 schrieb Paolo Bonzini: > > On 24/06/2016 10:11, Peter Lieven wrote: >> Am 24.06.2016 um 06:10 schrieb Paolo Bonzini: >>>>> If it's 10M nothing. If there is a 100M regression that is also caused >>>>> by RCU, we have to give up on

Re: [Qemu-devel] Qemu and heavily increased RSS usage

2016-06-24 Thread Peter Lieven
Am 24.06.2016 um 06:10 schrieb Paolo Bonzini: >>> If it's 10M nothing. If there is a 100M regression that is also caused >>> by RCU, we have to give up on it for that data structure, or mmap/munmap >>> the affected data structures. >> If it was only 10MB I would agree. But if I run the VM

Re: [Qemu-devel] Qemu and heavily increased RSS usage

2016-06-23 Thread Peter Lieven
Am 23.06.2016 um 18:53 schrieb Paolo Bonzini: > > On 23/06/2016 18:19, Peter Lieven wrote: >> Mhh, so your idea could be right. But what to do now? The introduction >> of RCU obviously increases the short term RSS usage. But thats never >> corrected as it seems. &g

Re: [Qemu-devel] Qemu and heavily increased RSS usage

2016-06-23 Thread Peter Lieven
Am 23.06.2016 um 17:47 schrieb Paolo Bonzini: On 23/06/2016 17:31, Peter Lieven wrote: Am 23.06.2016 um 17:21 schrieb Paolo Bonzini: On 23/06/2016 16:58, Peter Lieven wrote: commit ba3f4f64b0e941b9e03568b826746941bef071f9 Author: Paolo Bonzini <pbonz...@redhat.com> Date: Wed Jan 21

Re: [Qemu-devel] [PATCH] iscsi: fix assertion in is_sector_request_lun_aligned

2016-06-23 Thread Peter Lieven
Am 23.06.2016 um 17:50 schrieb Paolo Bonzini: On 20/06/2016 11:24, Peter Lieven wrote: Commit 94d047a added an assertion the the request alignment check. This introduced 2 issues: a) A off-by-one error since a request of BDRV_REQUEST_MAX_SECTORS is actually allowed. b

Re: [Qemu-devel] Qemu and heavily increased RSS usage

2016-06-23 Thread Peter Lieven
Am 23.06.2016 um 17:21 schrieb Paolo Bonzini: On 23/06/2016 16:58, Peter Lieven wrote: commit ba3f4f64b0e941b9e03568b826746941bef071f9 Author: Paolo Bonzini <pbonz...@redhat.com> Date: Wed Jan 21 12:09:14 2015 +0100 exec: RCUify AddressSpaceDispatch Note that even

Re: [Qemu-devel] Qemu and heavily increased RSS usage

2016-06-23 Thread Peter Lieven
Am 23.06.2016 um 17:00 schrieb Dr. David Alan Gilbert: * Peter Lieven (p...@kamp.de) wrote: Am 21.06.2016 um 15:18 schrieb Dr. David Alan Gilbert: * Peter Lieven (p...@kamp.de) wrote: Hi, while upgrading from Qemu 2.2.0 to Qemu 2.5.1.1 I noticed that the RSS memory usage has heavily

Re: [Qemu-devel] Qemu and heavily increased RSS usage

2016-06-23 Thread Peter Lieven
Am 21.06.2016 um 15:18 schrieb Dr. David Alan Gilbert: * Peter Lieven (p...@kamp.de) wrote: Hi, while upgrading from Qemu 2.2.0 to Qemu 2.5.1.1 I noticed that the RSS memory usage has heavily increased. We use hugepages so the RSS memory does not include VM memory. In Qemu 2.2.0 it used

Re: [Qemu-devel] Qemu and heavily increased RSS usage

2016-06-23 Thread Peter Lieven
Am 21.06.2016 um 15:18 schrieb Dr. David Alan Gilbert: * Peter Lieven (p...@kamp.de) wrote: Hi, while upgrading from Qemu 2.2.0 to Qemu 2.5.1.1 I noticed that the RSS memory usage has heavily increased. We use hugepages so the RSS memory does not include VM memory. In Qemu 2.2.0 it used

Re: [Qemu-devel] Qemu and heavily increased RSS usage

2016-06-22 Thread Peter Lieven
Am 22.06.2016 um 12:56 schrieb Stefan Hajnoczi: > On Tue, Jun 21, 2016 at 05:12:57PM +0200, Peter Lieven wrote: >> - We changed the coroutine pool to a per thread model. I disabled the pool. >> This seems >>to cut the max used RSS to about 150MB which is still a lot mor

Re: [Qemu-devel] Qemu and heavily increased RSS usage

2016-06-21 Thread Peter Lieven
Am 21.06.2016 um 15:18 schrieb Dr. David Alan Gilbert: * Peter Lieven (p...@kamp.de) wrote: Hi, while upgrading from Qemu 2.2.0 to Qemu 2.5.1.1 I noticed that the RSS memory usage has heavily increased. We use hugepages so the RSS memory does not include VM memory. In Qemu 2.2.0 it used

[Qemu-devel] Qemu and heavily increased RSS usage

2016-06-21 Thread Peter Lieven
Hi, while upgrading from Qemu 2.2.0 to Qemu 2.5.1.1 I noticed that the RSS memory usage has heavily increased. We use hugepages so the RSS memory does not include VM memory. In Qemu 2.2.0 it used to be ~30MB per vServer and increased to up to 300 - 400MB for Qemu 2.5.1.1 (same with master).

[Qemu-devel] [PATCH] iscsi: fix assertion in is_sector_request_lun_aligned

2016-06-20 Thread Peter Lieven
sectors which triggers the assertion. Fixes: 94d047a35bf663e28f8fef137544d8ea78165add Signed-off-by: Peter Lieven <p...@kamp.de> --- block/iscsi.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/block/iscsi.c b/block/iscsi.c index 7e78ade..9bb5ff6 100644 --- a/block/i

[Qemu-devel] Running nested Hyper-V inside KVM?

2016-06-16 Thread Peter Lieven
freundlichen Grüßen Peter Lieven ... KAMP Netzwerkdienste GmbH Vestische Str. 89-91 | 46117 Oberhausen Tel: +49 (0) 208.89 402-50 | Fax: +49 (0) 208.89 402-40 p...@kamp.de | http://www.kamp.de Geschäftsführer: Heiner Lante

Re: [Qemu-devel] [PATCH V3] block/iscsi: allow caching of the allocation map

2016-06-10 Thread Peter Lieven
Am 30.05.2016 um 08:33 schrieb Peter Lieven: > Am 25.05.2016 um 01:10 schrieb Eric Blake: >> On 05/24/2016 02:40 AM, Peter Lieven wrote: >>> until now the allocation map was used only as a hint if a cluster >>> is allocated or not. If a block was not allocated (or

[Qemu-devel] [PATCH V3] net: fix qemu_announce_self not emitting packets

2016-06-09 Thread Peter Lieven
with the VIRTIO_NET_F_GUEST_ANNOUNCE feature. Fixes: fefe2a78abde932e0f340b21bded2c86def1d242 Cc: qemu-sta...@nongnu.org Cc: hongyang.y...@easystack.cn Signed-off-by: Peter Lieven <p...@kamp.de> --- v1->v2: assert that only raw packets with a plain buffer come in. [Paolo] v2->v3: nc_senv_compat can take care of raw pa

Re: [Qemu-devel] [Qemu-stable] [PATCH V2] net: fix qemu_announce_self not emitting packets

2016-06-08 Thread Peter Lieven
Am 08.06.2016 um 12:23 schrieb Paolo Bonzini: > > - Original Message - >> From: "Jason Wang" <jasow...@redhat.com> >> To: "Peter Lieven" <p...@kamp.de>, qemu-devel@nongnu.org >> Cc: pbonz...@redhat.com, qemu-sta...@nongnu.org,

Re: [Qemu-devel] [Qemu-stable] [PATCH V2] net: fix qemu_announce_self not emitting packets

2016-06-08 Thread Peter Lieven
Am 08.06.2016 um 08:39 schrieb Jason Wang: > > > On 2016年06月07日 21:00, Peter Lieven wrote: >> commit fefe2a78 accidently dropped the code path for injecting >> raw packets. This feature is needed for sending gratuitous ARPs >> after an incoming migration has complet

Re: [Qemu-devel] [PATCH V2] net: fix qemu_announce_self not emitting packets

2016-06-07 Thread Peter Lieven
Am 07.06.2016 um 17:28 schrieb Yang Hongyang: On Tue, Jun 7, 2016 at 9:00 PM, Peter Lieven <p...@kamp.de <mailto:p...@kamp.de>> wrote: commit fefe2a78 accidently dropped the code path for injecting raw packets. This feature is needed for sending gratuitous ARPs after

[Qemu-devel] [PATCH V2] net: fix qemu_announce_self not emitting packets

2016-06-07 Thread Peter Lieven
with the VIRTIO_NET_F_GUEST_ANNOUNCE feature. Fixes: fefe2a78abde932e0f340b21bded2c86def1d242 Cc: qemu-sta...@nongnu.org Cc: hongyang.y...@easystack.cn Signed-off-by: Peter Lieven <p...@kamp.de> --- v1->v2: assert that only raw packets with a plain buffer come in. [Paolo] net/net.c | 10 +- 1 file changed, 9 i

Re: [Qemu-devel] [PATCH] net: fix qemu_announce_self not emitting packets

2016-06-07 Thread Peter Lieven
Am 07.06.2016 um 09:55 schrieb Paolo Bonzini: On 07/06/2016 09:37, Peter Lieven wrote: commit fefe2a78 accidently dropped the code path for injecting raw packets. This feature is needed for sending gratuitous ARPs after an incoming migration has completed. The result is increased network

Re: [Qemu-devel] [Qemu-stable] Broken live Migration in Qemu 2.5.1.1?

2016-06-07 Thread Peter Lieven
Am 06.06.2016 um 18:13 schrieb Stefan Priebe - Profihost AG: We're most probably seeing the same while migrating a machine running balanceng but haven't thought this might be a qemu bug. Instead we're investigating with balanceng people. Waiting for your further results. Can you try the

[Qemu-devel] [PATCH] net: fix qemu_announce_self not emitting packets

2016-06-07 Thread Peter Lieven
with the VIRTIO_NET_F_GUEST_ANNOUNCE feature. Fixes: fefe2a78abde932e0f340b21bded2c86def1d242 Cc: qemu-sta...@nongnu.org Cc: yan...@cn.fujitsu.com Signed-off-by: Peter Lieven <p...@kamp.de> --- net/net.c | 6 +- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/net/net.c b/net/net.c index 5f3e5a9..d5834ea

Re: [Qemu-devel] [Qemu-stable] Broken live Migration in Qemu 2.5.1.1?

2016-06-07 Thread Peter Lieven
Am 06.06.2016 um 18:13 schrieb Stefan Priebe - Profihost AG: We're most probably seeing the same while migrating a machine running balanceng but haven't thought this might be a qemu bug. Instead we're investigating with balanceng people. Waiting for your further results. This obviously is a

Re: [Qemu-devel] Broken live Migration in Qemu 2.5.1.1?

2016-06-06 Thread Peter Lieven
Am 06.06.2016 um 15:32 schrieb Peter Lieven: Hi, during internal testing of Qemu 2.5.1.1 I found a vServer running Ubuntu 12.04 (kernel 3.13) and a slave SQL server to stop replicating from the master. This seems to be reproducible. It is possible to continue replication when issuing a slave

[Qemu-devel] Broken live Migration in Qemu 2.5.1.1?

2016-06-06 Thread Peter Lieven
Hi, during internal testing of Qemu 2.5.1.1 I found a vServer running Ubuntu 12.04 (kernel 3.13) and a slave SQL server to stop replicating from the master. This seems to be reproducible. It is possible to continue replication when issuing a slave stop / slave start. There is no error visible

[Qemu-devel] [PATCH] block: assert that bs->request_alignment is a power of 2

2016-05-30 Thread Peter Lieven
at least bdrv_co_preadv/pwritev expect this. Signed-off-by: Peter Lieven <p...@kamp.de> --- block.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/block.c b/block.c index 736432f..f54bc25 100644 --- a/block.c +++ b/block.c @@ -1018,7 +1018,7 @@ static int bdrv_open_

[Qemu-devel] [PATCH] block/nfs: Implement .bdrv_co_preadv/pwritev interfaces

2016-05-30 Thread Peter Lieven
the libnfs read and write functions already take byte arguments so thats an easy change. Signed-off-by: Peter Lieven <p...@kamp.de> --- block/nfs.c | 40 +++- 1 file changed, 19 insertions(+), 21 deletions(-) diff --git a/block/nfs.c b/block/nfs.c

[Qemu-devel] [PATCH V3] block/io: optimize bdrv_co_pwritev for small requests

2016-05-30 Thread Peter Lieven
in a read-modify-write cycle a small request might cause head and tail to fall into the same aligned block. Currently QEMU reads the same block twice in this case which is not necessary. Signed-off-by: Peter Lieven <p...@kamp.de> --- v1->v2: following Paolos suggestions to

Re: [Qemu-devel] [PATCH V2] block/io: optimize bdrv_co_pwritev for small requests

2016-05-30 Thread Peter Lieven
Am 30.05.2016 um 12:06 schrieb Kevin Wolf: Am 30.05.2016 um 11:53 hat Peter Lieven geschrieben: Am 30.05.2016 um 11:47 schrieb Kevin Wolf: Am 30.05.2016 um 11:30 hat Peter Lieven geschrieben: Am 30.05.2016 um 10:24 schrieb Kevin Wolf: Am 30.05.2016 um 08:25 hat Peter Lieven geschrieben: Am

Re: [Qemu-devel] [PATCH V2] block/io: optimize bdrv_co_pwritev for small requests

2016-05-30 Thread Peter Lieven
Am 30.05.2016 um 11:47 schrieb Kevin Wolf: Am 30.05.2016 um 11:30 hat Peter Lieven geschrieben: Am 30.05.2016 um 10:24 schrieb Kevin Wolf: Am 30.05.2016 um 08:25 hat Peter Lieven geschrieben: Am 27.05.2016 um 10:55 schrieb Kevin Wolf: Am 27.05.2016 um 02:36 hat Fam Zheng geschrieben: On Thu

Re: [Qemu-devel] [PATCH V2] block/io: optimize bdrv_co_pwritev for small requests

2016-05-30 Thread Peter Lieven
Am 30.05.2016 um 10:24 schrieb Kevin Wolf: Am 30.05.2016 um 08:25 hat Peter Lieven geschrieben: Am 27.05.2016 um 10:55 schrieb Kevin Wolf: Am 27.05.2016 um 02:36 hat Fam Zheng geschrieben: On Thu, 05/26 11:20, Paolo Bonzini wrote: On 26/05/2016 10:30, Fam Zheng wrote: This doesn't look too

Re: [Qemu-devel] [PATCH V3] block/iscsi: allow caching of the allocation map

2016-05-30 Thread Peter Lieven
Am 25.05.2016 um 01:10 schrieb Eric Blake: On 05/24/2016 02:40 AM, Peter Lieven wrote: until now the allocation map was used only as a hint if a cluster is allocated or not. If a block was not allocated (or Qemu had no info about the allocation status) a get_block_status call was issued

Re: [Qemu-devel] [PATCH V2] block/io: optimize bdrv_co_pwritev for small requests

2016-05-30 Thread Peter Lieven
Am 27.05.2016 um 10:55 schrieb Kevin Wolf: Am 27.05.2016 um 02:36 hat Fam Zheng geschrieben: On Thu, 05/26 11:20, Paolo Bonzini wrote: On 26/05/2016 10:30, Fam Zheng wrote: This doesn't look too wrong... Should the right sequence of events be head/after_head or head/after_tail? It's

[Qemu-devel] [PATCH V2] block/io: optimize bdrv_co_pwritev for small requests

2016-05-24 Thread Peter Lieven
in a read-modify-write cycle a small request might cause head and tail to fall into the same aligned block. Currently QEMU reads the same block twice in this case which is not necessary. Signed-off-by: Peter Lieven <p...@kamp.de> --- v1->v2: following Paolos suggestions to

Re: [Qemu-devel] [PATCH] block/io: optimize bdrv_co_pwritev for small requests

2016-05-24 Thread Peter Lieven
Am 24.05.2016 um 15:59 schrieb Paolo Bonzini: On 24/05/2016 15:39, Peter Lieven wrote: bytes += offset & (align - 1); offset = offset & ~(align - 1); Because the low bits have been masked away from offset and added to bytes, + +/* if head and t

[Qemu-devel] [PATCH] block/io: optimize bdrv_co_pwritev for small requests

2016-05-24 Thread Peter Lieven
in a read-modify-write cycle a small request might cause head and tail to fall into the same alignment. Currently QEMU reads the same block twice in this case which is not necessary. Signed-off-by: Peter Lieven <p...@kamp.de> --- block/io.c | 12 1 file changed, 12 inse

[Qemu-devel] [PATCH] block/iscsi: avoid potential overflow of acb->task->cdb

2016-05-24 Thread Peter Lieven
at least in the path via virtio-blk the maximum size is not restricted. Cc: qemu-sta...@nongnu.org Signed-off-by: Peter Lieven <p...@kamp.de> --- block/iscsi.c | 7 +++ 1 file changed, 7 insertions(+) diff --git a/block/iscsi.c b/block/iscsi.c index 2ca8e72..e7d5f7b 100644 --- a

[Qemu-devel] [PATCH V3] block/iscsi: allow caching of the allocation map

2016-05-24 Thread Peter Lieven
get_block_status for known to be unallocated blocks. Signed-off-by: Peter Lieven <p...@kamp.de> --- v2->v3: - fix wording errors [Fam] - reinit allocmap only if allocmap is present in bdrv_reopen_commit v1->v2: - add more comments [Fam] - free allocmap i

[Qemu-devel] [PATCH V2] block/iscsi: allow caching of the allocation map

2016-05-20 Thread Peter Lieven
get_block_status for known to be unallocated blocks. Signed-off-by: Peter Lieven <p...@kamp.de> --- v1->v2: - add more comments [Fam] - free allocmap if allocation of allocmap_valid fails [Fam] - fix indent and whitespace errors [Fam] - account for cache mode changes

[Qemu-devel] [PATCH V2 2/2] block/nfs: add support for libnfs pagecache

2016-05-19 Thread Peter Lieven
in libnfs is always the NFS_BLKSIZE which is 4KB. Signed-off-by: Peter Lieven <p...@kamp.de> --- block/nfs.c | 37 - 1 file changed, 36 insertions(+), 1 deletion(-) diff --git a/block/nfs.c b/block/nfs.c index 60be45e..15d6832 100644 --- a/block/nfs.c +++ b

[Qemu-devel] [PATCH V2 1/2] block/nfs: refuse readahead if cache.direct is on

2016-05-19 Thread Peter Lieven
if we open a NFS export with disabled cache we should refuse the readahead feature as it will cache data inside libnfs. If a export was opened with readahead enabled it should futher not be allowed to disable the cache while running. Cc: qemu-sta...@nongnu.org Signed-off-by: Peter Lieven &l

[Qemu-devel] [PATCH V2 0/2] block/nfs: add support for libnfs pagecache

2016-05-19 Thread Peter Lieven
this adds support for the upcoming libnfs cachepage to Qemu. While at it neglect to use readahead if cache.direct is on. v1->v2: - move the readahead fix to Patch 1 and CC qemu-stable - check for changed cache settings in bdrv_reopen_prepare [Jeff] Peter Lieven (2): block/nfs: ref

Re: [Qemu-devel] [PATCH] block/iscsi: allow caching of the allocation map

2016-05-19 Thread Peter Lieven
Am 18.05.2016 um 09:41 schrieb Fam Zheng: On Tue, 05/17 15:59, Peter Lieven wrote: until now the allocation map was used only as a hint if a cluster is allocated or not. If a block was not allocated (or Qemu had no info about the allocation status) a get_block_status call was issued to check

Re: [Qemu-devel] [PATCH 2/2] block/nfs: refuse readahead if cache.direct is on

2016-05-19 Thread Peter Lieven
Am 18.05.2016 um 15:28 schrieb Jeff Cody: On Tue, May 17, 2016 at 04:11:55PM +0200, Peter Lieven wrote: Signed-off-by: Peter Lieven <p...@kamp.de> --- block/nfs.c | 5 + 1 file changed, 5 insertions(+) diff --git a/block/nfs.c b/block/nfs.c index 975510f..8b73a35 100644 --- a

[Qemu-devel] [PATCH 0/2] block/nfs: add support for libnfs pagecache

2016-05-17 Thread Peter Lieven
this adds support for the upcoming libnfs cachepage to Qemu. While at it neglect to use readahead if cache.direct is on. Peter Lieven (2): block/nfs: add support for libnfs pagecache block/nfs: refuse readahead if cache.direct is on block/nfs.c | 45

[Qemu-devel] [PATCH 1/2] block/nfs: add support for libnfs pagecache

2016-05-17 Thread Peter Lieven
in libnfs is always the NFS_BLKSIZE which is 4KB. Signed-off-by: Peter Lieven <p...@kamp.de> --- block/nfs.c | 40 1 file changed, 36 insertions(+), 4 deletions(-) diff --git a/block/nfs.c b/block/nfs.c index 9f51cc3..975510f 100644 --- a/block/nfs.c

[Qemu-devel] [PATCH] block/iscsi: allow caching of the allocation map

2016-05-17 Thread Peter Lieven
get_block_status for known to be unallocated blocks. Signed-off-by: Peter Lieven <p...@kamp.de> --- block/iscsi.c | 194 +++--- 1 file changed, 144 insertions(+), 50 deletions(-) diff --git a/block/iscsi.c b/block/iscsi.c index 10f3906..b

[Qemu-devel] [PATCH 2/2] block/nfs: refuse readahead if cache.direct is on

2016-05-17 Thread Peter Lieven
Signed-off-by: Peter Lieven <p...@kamp.de> --- block/nfs.c | 5 + 1 file changed, 5 insertions(+) diff --git a/block/nfs.c b/block/nfs.c index 975510f..8b73a35 100644 --- a/block/nfs.c +++ b/block/nfs.c @@ -331,6 +331,11 @@ static int64_t nfs_client_open(NFSClient *client, const

Re: [Qemu-devel] [PATCH for-2.6] block: add an 'iscsi-id' value to match -drive with -iscsi opts

2016-04-22 Thread Peter Lieven
Am 22.04.2016 um 12:59 schrieb Kevin Wolf: > Am 22.04.2016 um 12:24 hat Daniel P. Berrange geschrieben: >> The iSCSI block driver has ability to lookup various options, in >> particular authentication info, specified by the separate -iscsi >> argument. It currently uses the iSCSI IQN as the ID

Re: [Qemu-devel] [Qemu-stable] [ANNOUNCE] QEMU 2.5.1 Stable released

2016-04-01 Thread Peter Lieven
> Am 01.04.2016 um 16:53 schrieb Michael Roth <mdr...@linux.vnet.ibm.com>: > > Quoting Peter Lieven (2016-04-01 02:43:31) >>> Am 30.03.2016 um 02:11 schrieb Michael Roth: >>> Hi everyone, >>> >>> I am pleased to announce that

Re: [Qemu-devel] [Qemu-stable] [ANNOUNCE] QEMU 2.5.1 Stable released

2016-04-01 Thread Peter Lieven
Am 30.03.2016 um 02:11 schrieb Michael Roth: > Hi everyone, > > I am pleased to announce that the QEMU v2.5.1 stable release is now > available at: > > http://wiki.qemu.org/download/qemu-2.5.1.tar.bz2 > > v2.5.1 is now tagged in the official qemu.git repository, > and the stable-2.5 branch has

Re: [Qemu-devel] [Qemu-stable] [PATCH] target-i386: do not read/write MSR_TSC_AUX from KVM if CPUID bit is not set

2016-03-31 Thread Peter Lieven
Am 31.03.2016 um 18:52 schrieb Paolo Bonzini: > > On 31/03/2016 17:38, Peter Lieven wrote: >> >>> Am 31.03.2016 um 15:23 schrieb Paolo Bonzini <pbonz...@redhat.com>: >>> >>> >>> >>>> On 31/03/2016 15:12, Peter Lieven wrote: >&

Re: [Qemu-devel] [Qemu-stable] [PATCH] target-i386: do not read/write MSR_TSC_AUX from KVM if CPUID bit is not set

2016-03-31 Thread Peter Lieven
> Am 31.03.2016 um 15:23 schrieb Paolo Bonzini <pbonz...@redhat.com>: > > > >> On 31/03/2016 15:12, Peter Lieven wrote: >>>> >>>> KVM does not let you read or write this MSR if the corresponding CPUID >>>> bit is no

Re: [Qemu-devel] [Qemu-stable] [PATCH] target-i386: do not read/write MSR_TSC_AUX from KVM if CPUID bit is not set

2016-03-31 Thread Peter Lieven
Am 31.03.2016 um 14:56 schrieb Laszlo Ersek: On 03/30/16 22:59, Paolo Bonzini wrote: KVM does not let you read or write this MSR if the corresponding CPUID bit is not set. This in turn causes MSRs that come after MSR_TSC_AUX to be ignored by KVM_SET_MRSS. Is it possible that this causes a

Re: [Qemu-devel] [Qemu-stable] [PATCH 00/35] Patch Round-up for stable 2.5.1, freeze on 2016-03-25

2016-03-22 Thread Peter Lieven
Am 21.03.2016 um 18:27 schrieb Michael Roth: Hi everyone, The following new patches are queued for QEMU stable v2.5.1: https://github.com/mdroth/qemu/commits/stable-2.5-staging The release is planned for 2016-03-29: http://wiki.qemu.org/Planning/2.5 Please respond here or CC

[Qemu-devel] qemu/ipxe DHCP client identifier

2016-03-21 Thread Peter Lieven
Hi, is there a way to set the DHCP client identifier that iPXE uses? The issue I face is that each client gets 2 IP addresses assigned. One for iPXE which sends a client identifer derived from the MAC address. The second is assigned to ipconfig in initrd which uses no client identifier.

Re: [Qemu-devel] [PATCH 3/4] block/vpc: give option to force the current_size field in .bdrv_create

2016-02-24 Thread Peter Lieven
Am 24.02.2016 um 14:07 schrieb Kevin Wolf: > Am 24.02.2016 um 13:44 hat Peter Lieven geschrieben: >> if the size is forced I would set the chs values to max. this way no >> new creator String is needed and it is even backwards compatible. this >> is what disk2vhd doe

Re: [Qemu-devel] [PATCH 3/4] block/vpc: give option to force the current_size field in .bdrv_create

2016-02-24 Thread Peter Lieven
Am 24.02.2016 um 14:40 schrieb Jeff Cody: > On Wed, Feb 24, 2016 at 02:07:18PM +0100, Kevin Wolf wrote: >> Am 24.02.2016 um 13:44 hat Peter Lieven geschrieben: >>> if the size is forced I would set the chs values to max. this way no >>> new creator String is need

Re: [Qemu-devel] [PATCH 3/4] block/vpc: give option to force the current_size field in .bdrv_create

2016-02-24 Thread Peter Lieven
if the size is forced I would set the chs values to max. this way no new creator String is needed and it is even backwards compatible. this is what disk2vhd does. Peter > Am 24.02.2016 um 13:24 schrieb Jeff Cody : > >> On Wed, Feb 24, 2016 at 11:19:37AM +0100, Kevin Wolf

Re: [Qemu-devel] [Qemu-block] [PATCH] send readcapacity10 when readcapacity16 failed

2016-01-11 Thread Peter Lieven
Am 07.01.2016 um 11:07 schrieb Paolo Bonzini: > > On 06/01/2016 18:57, John Snow wrote: >> Ronnie: Thanks for the explanation! >> >> Zhu: In light of this, can the patch be reworked slightly to explicitly >> check *why* READCAPACITY16 failed and only attempt the READCAPACITY10 as >> a fallback if

Re: [Qemu-devel] [PATCH V5] block/nfs: add support for setting debug level

2016-01-11 Thread Peter Lieven
Am 13.11.2015 um 10:45 schrieb Stefan Hajnoczi: > On Mon, Nov 09, 2015 at 08:09:33AM +0100, Peter Lieven wrote: >> recent libnfs versions support logging debug messages. Add >> support for it in qemu through an URL parameter. >> >> Example: >> qemu -cdrom n

Re: [Qemu-devel] [PATCH] fix:readcapacity 10 failure shown even 16 sent

2015-12-10 Thread Peter Lieven
Am 10.12.2015 um 09:55 schrieb Paolo Bonzini: On 10/12/2015 03:59, Zhu Lingshan wrote: -if (task == NULL || task->status != SCSI_STATUS_GOOD) { +if ((rc16 != NULL) && ((task == NULL) || (task->status != SCSI_STATUS_GOOD))) { +error_setg(errp, "iSCSI: failed to send

Re: [Qemu-devel] [PULL 00/14] Migration pull request

2015-11-20 Thread Peter Lieven
Am 20.11.2015 um 12:33 schrieb Peter Maydell: > On 20 November 2015 at 09:38, Peter Lieven <p...@kamp.de> wrote: >> I wonder if there is a glitch in the PIO implementation of test-ide.c. As >> far as I understand the specs >> it is not allowed to read dat

Re: [Qemu-devel] [PULL 00/14] Migration pull request

2015-11-20 Thread Peter Lieven
Am 20.11.2015 um 14:53 schrieb Kevin Wolf: > Am 20.11.2015 um 14:44 hat Peter Lieven geschrieben: >> Am 20.11.2015 um 12:33 schrieb Peter Maydell: >>> On 20 November 2015 at 09:38, Peter Lieven <p...@kamp.de> wrote: >>>> I wonder if there is a glitch in

[Qemu-devel] [PATCH] tests: fix cdrom_pio_impl in ide-test

2015-11-20 Thread Peter Lieven
that transfers the data. Signed-off-by: Peter Lieven <p...@kamp.de> --- tests/ide-test.c | 16 1 file changed, 8 insertions(+), 8 deletions(-) diff --git a/tests/ide-test.c b/tests/ide-test.c index d1014bb..fc1ce52 100644 --- a/tests/ide-test.c +++ b/tests/ide-test.c @@ -

Re: [Qemu-devel] [PULL 00/14] Migration pull request

2015-11-20 Thread Peter Lieven
86-softmmu/qemu-system-i386 >> QTEST_QEMU_IMG=qemu-img gtester -k --verbose -m=quick tests/ide-test ; >> do true; done >> >> will eventually hang on /i386/ide/cdrom/pio_large (may take a fair >> number of loops; when it works fine the test does not take an >> appr

Re: [Qemu-devel] [PULL 00/14] Migration pull request

2015-11-20 Thread Peter Lieven
86-softmmu/qemu-system-i386 >> QTEST_QEMU_IMG=qemu-img gtester -k --verbose -m=quick tests/ide-test ; >> do true; done >> >> will eventually hang on /i386/ide/cdrom/pio_large (may take a fair >> number of loops; when it works fine the test does not take an >> appreciable amount of time). After a long time the timeout in the >> test kicks in and the assert happens. > cc'ing in Peter Lieven given his recent IDE buffering changes. Hi David, John and I are looking at this at this moment. Thanks for notifying us. Peter

Re: [Qemu-devel] [PATCH V4 0/6] ide: avoid main-loop hang on CDROM/NFS failure

2015-11-16 Thread Peter Lieven
Am 16.11.2015 um 07:17 schrieb Fam Zheng: On Fri, 11/13 17:44, John Snow wrote: On 11/12/2015 11:30 AM, Peter Lieven wrote: This series aims at avoiding a hanging main-loop if a vserver has a CDROM image mounted from a NFS share and that NFS share goes down. Typical situation is that users

Re: [Qemu-devel] block/vpc: Fix vhd extra sectors issue

2015-11-16 Thread Peter Lieven
Am 16.11.2015 um 13:22 schrieb Jeff Cody: On Mon, Nov 16, 2015 at 10:17:11AM +0100, Kevin Wolf wrote: Am 13.11.2015 um 16:32 hat Lucian Petrut geschrieben: At the moment, qemu-img extends new image virtual sizes based on the CHS algorithm provided by the VHD specs in order to ensure that the

Re: [Qemu-devel] [PATCH V5] block/nfs: add support for setting debug level

2015-11-13 Thread Peter Lieven
Am 13.11.2015 um 10:45 schrieb Stefan Hajnoczi: > On Mon, Nov 09, 2015 at 08:09:33AM +0100, Peter Lieven wrote: >> recent libnfs versions support logging debug messages. Add >> support for it in qemu through an URL parameter. >> >> Example: >> qemu -cdrom n

Re: [Qemu-devel] [PATCH V4 1/6] ide/atapi: make PIO read requests async

2015-11-13 Thread Peter Lieven
> Am 13.11.2015 um 23:42 schrieb John Snow <js...@redhat.com>: > > > >> On 11/12/2015 11:30 AM, Peter Lieven wrote: >> PIO read requests on the ATAPI interface used to be sync blk requests. >> This has two significant drawbacks. First the main loop hangs

Re: [Qemu-devel] [PATCH V3 4/6] ide: orphan all buffered requests on DMA cancel

2015-11-12 Thread Peter Lieven
Am 12.11.2015 um 09:27 schrieb Fam Zheng: On Fri, 11/06 09:42, Peter Lieven wrote: If the guests canceles a DMA request we can prematurely invoke all callbacks of buffered requests and flag all them as orphaned. Ideally this avoids the need for draining all requests. For CDROM devices

Re: [Qemu-devel] [PATCH V3 3/6] ide: add support for IDEBufferedRequest

2015-11-12 Thread Peter Lieven
Am 12.11.2015 um 10:57 schrieb Fam Zheng: On Fri, 11/06 09:42, Peter Lieven wrote: +BlockAIOCB *ide_buffered_readv(IDEState *s, int64_t sector_num, + QEMUIOVector *iov, int nb_sectors, + BlockCompletionFunc *cb, void *opaque

Re: [Qemu-devel] [PATCH V3 5/6] ide: enable buffered requests for ATAPI devices

2015-11-12 Thread Peter Lieven
Am 12.11.2015 um 12:25 schrieb Fam Zheng: On Fri, 11/06 09:42, Peter Lieven wrote: Signed-off-by: Peter Lieven <p...@kamp.de> --- hw/ide/atapi.c | 10 +- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/hw/ide/atapi.c b/hw/ide/atapi.c index 29fd131..2f6d018

Re: [Qemu-devel] [PATCH V3 0/6] ide: avoid main-loop hang on CDROM/NFS failure

2015-11-12 Thread Peter Lieven
Am 12.11.2015 um 12:33 schrieb Fam Zheng: On Fri, 11/06 09:42, Peter Lieven wrote: This series aims at avoiding a hanging main-loop if a vserver has a CDROM image mounted from a NFS share and that NFS share goes down. Typical situation is that users mount an CDROM ISO to install something

[Qemu-devel] [PATCH V4 2/6] block: add blk_abort_aio_request

2015-11-12 Thread Peter Lieven
Signed-off-by: Peter Lieven <p...@kamp.de> --- block/block-backend.c | 17 + include/sysemu/block-backend.h | 3 +++ 2 files changed, 12 insertions(+), 8 deletions(-) diff --git a/block/block-backend.c b/block/block-backend.c index 6f9309f..701234e 100644 --- a

[Qemu-devel] [PATCH V4 3/6] ide: add support for IDEBufferedRequest

2015-11-12 Thread Peter Lieven
written to the storage. Signed-off-by: Peter Lieven <p...@kamp.de> --- hw/ide/core.c | 47 +++ hw/ide/internal.h | 14 ++ 2 files changed, 61 insertions(+) diff --git a/hw/ide/core.c b/hw/ide/core.c index 364ba21..7ca67bc 100644 --

[Qemu-devel] [PATCH V4 5/6] ide: enable buffered requests for ATAPI devices

2015-11-12 Thread Peter Lieven
Signed-off-by: Peter Lieven <p...@kamp.de> --- hw/ide/atapi.c | 10 +- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/hw/ide/atapi.c b/hw/ide/atapi.c index cfd2d63..d1eaa29 100644 --- a/hw/ide/atapi.c +++ b/hw/ide/atapi.c @@ -190,8 +190,8 @@ static int cd_read_

[Qemu-devel] [PATCH V4 1/6] ide/atapi: make PIO read requests async

2015-11-12 Thread Peter Lieven
to possible race conditions requests during an ongoing elementary transfer are still sync. Signed-off-by: Peter Lieven <p...@kamp.de> --- hw/ide/atapi.c | 97 ++ 1 file changed, 85 insertions(+), 12 deletions(-) diff --git a/hw/ide/atapi.c b/

[Qemu-devel] [PATCH V4 0/6] ide: avoid main-loop hang on CDROM/NFS failure

2015-11-12 Thread Peter Lieven
improvement already. - Dropped Patch 5 because it is upstream meanwhile. Peter Lieven (6): ide/atapi: make PIO read requests async block: add blk_abort_aio_request ide: add support for IDEBufferedRequest ide: orphan all buffered requests on DMA cancel ide: enable buffe

[Qemu-devel] [PATCH V4 4/6] ide: orphan all buffered requests on DMA cancel

2015-11-12 Thread Peter Lieven
If the guests canceles a DMA request we can prematurely invoke all callbacks of buffered requests and flag all them as orphaned. Ideally this avoids the need for draining all requests. For CDROM devices this works in 100% of all cases. Signed-off-by: Peter Lieven <p...@kamp.de> --- hw/ide

[Qemu-devel] [PATCH V4 6/6] ide: enable buffered requests for PIO read requests

2015-11-12 Thread Peter Lieven
Signed-off-by: Peter Lieven <p...@kamp.de> --- hw/ide/core.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/hw/ide/core.c b/hw/ide/core.c index 7ca67bc..b9b531c 100644 --- a/hw/ide/core.c +++ b/hw/ide/core.c @@ -677,8 +677,8 @@ static void ide_sector_read(IDESt

[Qemu-devel] [PATCH V5] block/nfs: add support for setting debug level

2015-11-08 Thread Peter Lieven
recent libnfs versions support logging debug messages. Add support for it in qemu through an URL parameter. Example: qemu -cdrom nfs://127.0.0.1/iso/my.iso?debug=2 Signed-off-by: Peter Lieven <p...@kamp.de> --- v4->v5: add a comment in the code why we limit the debug level [Stefa

<    2   3   4   5   6   7   8   9   10   11   >