Signed-off-by: Marc-André Lureau
---
block/quorum.c | 27 ---
1 file changed, 8 insertions(+), 19 deletions(-)
diff --git a/block/quorum.c b/block/quorum.c
index d04da4f430..e4271caa7a 100644
--- a/block/quorum.c
+++ b/block/quorum.c
@@ -22,6
This will help with the introduction of a new structure to handle
enum lookup.
Signed-off-by: Marc-André Lureau
---
include/qapi/util.h | 2 +
backends/hostmem.c | 3 +-
block/backup.c | 3 +-
Store the length in the lookup table, i.e. change it from
const char *const[] to struct { int n, const char *const s[] }.
The following conditional enum entry change will create "hole"
elements in the generated lookup array, that should be skipped.
Signed-off-by: Marc-André Lureau
Now that all usages have been converted to user lookup helpers.
Signed-off-by: Marc-André Lureau
---
scripts/qapi.py | 1 -
block/parallels.c | 1 -
ui/input-legacy.c | 2 +-
3 files changed, 1 insertion(+), 3 deletions(-)
diff --git a/scripts/qapi.py
On 08/22/2017 10:18 AM, Paolo Bonzini wrote:
Move more knowledge of sense data format out of hw/scsi/scsi-bus.c
for reusability.
Signed-off-by: Paolo Bonzini
Reviewed-by: Philippe Mathieu-Daudé
---
hw/scsi/scsi-bus.c | 8 +---
On 08/22/2017 10:18 AM, Paolo Bonzini wrote:
There is a bunch of SCSI code that is shared by block/iscsi.c and
hw/scsi, and the introduction of the persistent reservation helper
will add more instances of this. There is also include/block/scsi.h,
which actually is not part of the core block
9e047b982452 "piix4: add acpi pci hotplug support" introduced a new property
'use_acpi_pci_hotplug' for pc-1.7 and older machines.
c24d5e0b91d1 "convert ACPI PCI hotplug to use hotplug-handler API" added the
qbus hotplug handlers but forgot to check for the 'use_acpi_pci_hotplug'
property.
Check
On Tue, Aug 22, 2017 at 06:43:43PM -0300, Philippe Mathieu-Daudé wrote:
> 9e047b982452 "piix4: add acpi pci hotplug support" introduced a new property
> 'use_acpi_pci_hotplug' for pc-1.7 and older machines.
> c24d5e0b91d1 "convert ACPI PCI hotplug to use hotplug-handler API" added the
> qbus
On 08/22/2017 07:42 PM, Michael S. Tsirkin wrote:
On Tue, Aug 22, 2017 at 06:43:43PM -0300, Philippe Mathieu-Daudé wrote:
9e047b982452 "piix4: add acpi pci hotplug support" introduced a new property
'use_acpi_pci_hotplug' for pc-1.7 and older machines.
c24d5e0b91d1 "convert ACPI PCI hotplug to
On Tue, Aug 22, 2017 at 03:25:41PM +0200, Alberto Garcia wrote:
+/* This function edits throttle_groups and must be called under the global
+ * mutex */
+static void throttle_group_obj_complete(UserCreatable *obj, Error **errp)
+{
+ThrottleGroup *tg = THROTTLE_GROUP(obj);
+ThrottleConfig
On Tue 22 Aug 2017 03:22:12 PM CEST, Marc-André Lureau wrote:
> @@ -925,7 +908,13 @@ static int quorum_open(BlockDriverState *bs, QDict
> *options, int flags,
> goto exit;
> }
>
> -ret = parse_read_pattern(qemu_opt_get(opts, QUORUM_OPT_READ_PATTERN));
> +if
Hi
On Tue, Aug 22, 2017 at 3:00 PM, Markus Armbruster wrote:
> Marc-André Lureau writes:
>
>> Hi
>>
>> On Mon, Aug 7, 2017 at 4:45 PM, Markus Armbruster wrote:
>>> Sizes should use QAPI type 'size' (uint64_t). ringbuf-read
Igor Mammedov writes:
> On Tue, 22 Aug 2017 15:50:14 +0200
> Markus Armbruster wrote:
>
>> Igor Mammedov writes:
>>
>> > On Mon, 7 Aug 2017 16:45:16 +0200
>> > Markus Armbruster wrote:
>> >
>> >> Sizes and
Hi,
This series failed build test on FreeBSD host. Please find the details below.
Message-id: 20170822131832.20191-1-pbonz...@redhat.com
Type: series
Subject: [Qemu-devel] [RFC PATCH 00/10] scsi, block: introduce persistent
reservation managers
=== TEST SCRIPT BEGIN ===
#!/bin/sh
# Testing
Marc-André Lureau writes:
> Hi
>
> On Tue, Aug 22, 2017 at 3:00 PM, Markus Armbruster wrote:
>> Marc-André Lureau writes:
>>
>>> Hi
>>>
>>> On Mon, Aug 7, 2017 at 4:45 PM, Markus Armbruster wrote:
On 22/08/2017 15:45, Philippe Mathieu-Daudé wrote:
> Hi Paolo,
>
> On 08/22/2017 10:18 AM, Paolo Bonzini wrote:
>> Move more knowledge of SG_IO out of hw/scsi/scsi-generic.c, for
>> reusability.
>>
>> Signed-off-by: Paolo Bonzini
>> ---
>> hw/scsi/scsi-generic.c | 40
Hi
On Tue, Aug 22, 2017 at 3:18 PM, Paolo Bonzini wrote:
> Introduce a privileged helper to run persistent reservation commands.
> This lets virtual machines send persistent reservations without using
> CAP_SYS_RAWIO or out-of-tree patches. The helper uses Unix permissions
On Tue, Aug 22, 2017 at 04:16:26PM +0200, Alberto Garcia wrote:
On Tue 22 Aug 2017 12:15:34 PM CEST, Manos Pitsidianakis wrote:
@@ -548,6 +548,11 @@ void throttle_group_unregister_tgm(ThrottleGroupMember
*tgm)
ThrottleGroupMember *token;
int i;
+if (!ts) {
+/* Discard
On 22/08/2017 16:34, Marc-André Lureau wrote:
> Could this be handled by udisk? It seems at first the problem is not
> specific to qemu.
Yes, possibly. In practice, everybody else who uses persistent
reservations seems to run as root. :)
>> +static void usage(const char *name)
>> +{
>> +
On 08/22/2017 10:18 AM, Paolo Bonzini wrote:
Complete the transition by renaming this header, which was
shared by block/iscsi.c and the SCSI emulation code.
Signed-off-by: Paolo Bonzini
Reviewed-by: Philippe Mathieu-Daudé
---
block/iscsi.c
Hi,
This series failed build test on s390x host. Please find the details below.
Message-id: 20170822131832.20191-1-pbonz...@redhat.com
Type: series
Subject: [Qemu-devel] [RFC PATCH 00/10] scsi, block: introduce persistent
reservation managers
=== TEST SCRIPT BEGIN ===
#!/bin/bash
# Testing
Hi,
This series seems to have some coding style problems. See output below for
more information:
Type: series
Message-id: 20170822131832.20191-1-pbonz...@redhat.com
Subject: [Qemu-devel] [RFC PATCH 00/10] scsi, block: introduce persistent
reservation managers
=== TEST SCRIPT BEGIN ===
Hi Paolo,
On 08/22/2017 10:18 AM, Paolo Bonzini wrote:
Move more knowledge of SG_IO out of hw/scsi/scsi-generic.c, for
reusability.
Signed-off-by: Paolo Bonzini
---
hw/scsi/scsi-generic.c | 40 +++-
include/scsi/utils.h | 3 +++
On 2017-08-22 01:31, John Snow wrote:
>
>
> On 08/17/2017 05:15 AM, Pavel Butsykin wrote:
>> This patch add shrinking of the image file for qcow2. As a result, this
>> allows
>> us to reduce the virtual image size and free up space on the disk without
>> copying the image. Image can be
On 08/22/2017 10:18 AM, Paolo Bonzini wrote:
After introducing the scsi/ subdirectory, there will be a scsi_build_sense
function that is the same as scsi_req_build_sense but without needing
a SCSIRequest. The existing scsi_build_sense function gets in the way,
remove it.
Signed-off-by: Paolo
On Tue 22 Aug 2017 12:15:34 PM CEST, Manos Pitsidianakis wrote:
> ##
> +# @BlockdevOptionsThrottle:
> +#
> +# Driver specific block device options for the throttle driver
> +#
> +# @throttle-group: the name of the throttle-group object to use. It
> +#must already exist.
> +#
* Stefan Hajnoczi (stefa...@redhat.com) wrote:
> The following scenario leads to an assertion failure in
> qio_channel_yield():
>
> 1. Request coroutine calls qio_channel_yield() successfully when sending
>would block on the socket. It is now yielded.
> 2. nbd_read_reply_entry() calls
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.
Type: series
Message-id: 20170822131832.20191-1-pbonz...@redhat.com
Subject: [Qemu-devel] [RFC PATCH 00/10] scsi, block:
Igor Mammedov writes:
> On Mon, 7 Aug 2017 16:45:16 +0200
> Markus Armbruster wrote:
>
>> Sizes and addresses should use QAPI type 'size' (uint64_t).
>> PCDIMMDeviceInfo members @addr and @size are 'int' (int64_t).
>> qmp_pc_dimm_device_list() implicitly
Hi Markus,
On 07/08/2017 17:45, Markus Armbruster wrote:
Sizes and addresses should use QAPI type 'size' (uint64_t).
PciMemoryRegion members @address and @size are 'int' (int64_t).
qmp_query_pci_regions() implicitly converts from pcibus_t,
i.e. uint64_t.
Change these PciMemoryRegion members to
On Tue, 22 Aug 2017 15:50:14 +0200
Markus Armbruster wrote:
> Igor Mammedov writes:
>
> > On Mon, 7 Aug 2017 16:45:16 +0200
> > Markus Armbruster wrote:
> >
> >> Sizes and addresses should use QAPI type 'size' (uint64_t).
> >>
On 08/21/2017 01:15 PM, Stefan Hajnoczi wrote:
Commit 72b6ffc76653214b69a94a7b1643ff80df134486 ("nbd-client: Fix
regression when server sends garbage") improved NBD client behavior when
the connection enters a broken state.
The following still does not behave as expected:
$ qemu-nbd -p 1234
On 08/22/2017 09:22 AM, Marc-André Lureau wrote:
> This will help with the introduction of a new structure to handle
> enum lookup.
>
Procedurally for the sake of review, it's a little odd to introduce the
function, deploy it, and then change it and update all callers.
content-wise, I'm
On 08/08/2017 04:00 PM, Eric Blake wrote:
> On 08/08/2017 01:32 PM, John Snow wrote:
>> Out with the old, in with the new.
>>
>> Signed-off-by: John Snow
>> ---
>
>> hw/ide/piix.c | 11
>> hw/ide/trace-events | 33
>>
Hi!
Looks like there is a use-after-free problem somewhere in
the ahci.c or ich.c code when trying to add the ich9-ahci
on a old PC machine. Using valgrind, I get:
$ valgrind x86_64-softmmu/qemu-system-x86_64 -M pc-1.2 -nographic -S
==6604== Memcheck, a memory error detector
==6604== Copyright
On 08/22/2017 02:15 PM, Thomas Huth wrote:
>
> Hi!
>
> Looks like there is a use-after-free problem somewhere in
> the ahci.c or ich.c code when trying to add the ich9-ahci
> on a old PC machine. Using valgrind, I get:
>
I'll look; it looks like it works okay for pc-i440fx-2.9 as well as
Well, we knew we'd want this sooner or later. I've got some pings
downstream over whether or not we support persistent bitmaps for
non-qcow2 formats.
Currently: no, we don't.
We tried two different ideas for storage agnostic bitmap persistence:
(1) Using qcow2 as a storage container format
On Tue, 08/22 15:18, Paolo Bonzini wrote:
> Proper support of persistent reservation for multipath devices requires
> communication with the multipath daemon, so that the reservation is
> registered and applied when a path comes up. The device mapper
> utilities provide a library to do so; this
On Tue, 08/22 15:18, Paolo Bonzini wrote:
> diff --git a/docs/pr-manager.rst b/docs/pr-manager.rst
Is docs/interop/persistent-reservation-manager.rst better? (Move to interop/ and
de-abbreviate) ...
> new file mode 100644
> index 00..b6089fb57c
> --- /dev/null
> +++ b/docs/pr-manager.rst
On Tue, 08/22 15:18, Paolo Bonzini wrote:
> It is pretty common to read a fixed-size buffer from a socket. Add a
> function that does this, either with multiple reads (on blocking sockets)
> or by yielding if called from a coroutine.
>
> Cc: Daniel P. Berrange
>
On Tue, 08/22 15:18, Paolo Bonzini wrote:
> This adds a concrete subclass of pr-manager that talks to qemu-pr-helper.
>
> Signed-off-by: Paolo Bonzini
> ---
> scsi/Makefile.objs | 2 +-
> scsi/pr-manager-helper.c | 288
>
On 23.08.2017 02:10, Philippe Mathieu-Daudé wrote:
> On 08/22/2017 07:42 PM, Michael S. Tsirkin wrote:
>> On Tue, Aug 22, 2017 at 06:43:43PM -0300, Philippe Mathieu-Daudé wrote:
>>> 9e047b982452 "piix4: add acpi pci hotplug support" introduced a new
>>> property
>>> 'use_acpi_pci_hotplug' for
On 08/22/2017 03:39 PM, John Snow wrote:
On 08/22/2017 02:15 PM, Thomas Huth wrote:
Looks like there is a use-after-free problem somewhere in
the ahci.c or ich.c code when trying to add the ich9-ahci
on a old PC machine. Using valgrind, I get:
those old PC don't support AHCI hotplug, so
On 08/22/2017 05:02 PM, Philippe Mathieu-Daudé wrote:
> On 08/22/2017 03:39 PM, John Snow wrote:
>> On 08/22/2017 02:15 PM, Thomas Huth wrote:
>>>
>>> Looks like there is a use-after-free problem somewhere in
>>> the ahci.c or ich.c code when trying to add the ich9-ahci
>>> on a old PC machine.
timer_cb() needs to know about the current Aio context of the throttle
request that is woken up. In order to make ThrottleGroupMember backend
agnostic, this information is stored in an aio_context field instead of
accessing it from BlockBackend.
Reviewed-by: Alberto Garcia
This series adds a throttle block driver filter. Currently throttling is done
at the BlockBackend level. Using block driver interfaces we can move the
throttling to any point in the BDS graph using a throttle node which uses the
existing throttling code. This allows for potentially more complex
Move the CoMutex and CoQueue inits inside throttle_group_register_tgm()
which is called whenever a ThrottleGroupMember is initialized. There's
no need for them to be separate.
Reviewed-by: Alberto Garcia
Reviewed-by: Stefan Hajnoczi
Signed-off-by: Manos
block/throttle.c uses existing I/O throttle infrastructure inside a
block filter driver. I/O operations are intercepted in the filter's
read/write coroutines, and referred to block/throttle-groups.c
The driver can be used with the syntax
-drive
On Tue 22 Aug 2017 12:31:26 PM CEST, Manos Pitsidianakis wrote:
> On Tue, Aug 22, 2017 at 11:57:28AM +0200, Alberto Garcia wrote:
>>On Mon 21 Aug 2017 05:39:48 PM CEST, Manos Pitsidianakis wrote:
> -if (job_id == NULL && !(flags & BLOCK_JOB_INTERNAL)) {
> -job_id =
On Mon 21 Aug 2017 05:39:48 PM CEST, Manos Pitsidianakis wrote:
>>> -if (job_id == NULL && !(flags & BLOCK_JOB_INTERNAL)) {
>>> -job_id = bdrv_get_device_name(bs);
>>> -if (!*job_id) {
>>> -error_setg(errp, "An explicit job ID is required for this
>>> node");
>>> -
On Tue, Aug 22, 2017 at 11:57:28AM +0200, Alberto Garcia wrote:
On Mon 21 Aug 2017 05:39:48 PM CEST, Manos Pitsidianakis wrote:
-if (job_id == NULL && !(flags & BLOCK_JOB_INTERNAL)) {
-job_id = bdrv_get_device_name(bs);
-if (!*job_id) {
-error_setg(errp, "An
This commit eliminates the 1:1 relationship between BlockBackend and
throttle group state. Users will be able to create multiple throttle
nodes, each with its own throttle group state, in the future. The
throttle group state cannot be per-BlockBackend anymore, it must be
per-throttle node. This
ThrottleGroup is converted to an object. This will allow the future
throttle block filter drive easy creation and configuration of throttle
groups in QMP and cli.
A new QAPI struct, ThrottleLimits, is introduced to provide a shared
struct for all throttle configuration needs in QMP.
Hi
Is this based on
https://lists.gnu.org/archive/html/qemu-devel/2017-06/msg01894.html ?
If so, you should probably keep me signed-off.
My patch had also a test :)
- Original Message -
> Signed-off-by: Markus Armbruster
> ---
> include/qapi/qmp/qdict.h | 5
Hi
On Mon, Aug 7, 2017 at 4:45 PM, Markus Armbruster wrote:
> Sizes should use QAPI type 'size' (uint64_t). ringbuf-read parameter
> @size is 'int' (int64_t). qmp_ringbuf_read() rejects negative values,
> then implicitly converts to size_t.
>
> Change the parameter to 'size'
On Wed 09 Aug 2017 04:02:54 PM CEST, Manos Pitsidianakis wrote:
> +void blk_io_limits_update_group(BlockBackend *blk, const char *group, Error
> **errp)
> {
> +ThrottleGroupMember *tgm;
> +
> /* this BB is not part of any group */
> -if
On Wed 09 Aug 2017 04:02:56 PM CEST, Manos Pitsidianakis wrote:
> All BlockBackend level throttling (via the implicit throttle filter node) is
> done in block/block-backend.c and block/throttle-groups.c doesn't know
> about BlockBackends anymore. Since BlockBackendPublic is not needed anymore,
>
The following scenario leads to an assertion failure in
qio_channel_yield():
1. Request coroutine calls qio_channel_yield() successfully when sending
would block on the socket. It is now yielded.
2. nbd_read_reply_entry() calls nbd_recv_coroutines_enter_all() because
nbd_receive_reply()
On Mon, 7 Aug 2017 16:45:16 +0200
Markus Armbruster wrote:
> Sizes and addresses should use QAPI type 'size' (uint64_t).
> PCDIMMDeviceInfo members @addr and @size are 'int' (int64_t).
> qmp_pc_dimm_device_list() implicitly converts from uint64_t.
>
> Change these
Marc-André Lureau writes:
> Hi
>
> On Mon, Aug 7, 2017 at 4:45 PM, Markus Armbruster wrote:
>> Sizes should use QAPI type 'size' (uint64_t). ringbuf-read parameter
>> @size is 'int' (int64_t). qmp_ringbuf_read() rejects negative values,
>> then
Introduce a privileged helper to run persistent reservation commands.
This lets virtual machines send persistent reservations without using
CAP_SYS_RAWIO or out-of-tree patches. The helper uses Unix permissions
and SCM_RIGHTS to restrict access to processes that can access its socket
and prove
It is a common requirement for virtual machine to send persistent
reservations, but this currently requires either running QEMU with
CAP_SYS_RAWIO, or using out-of-tree patches that let an unprivileged
QEMU bypass Linux's filter on SG_IO commands.
As an alternative mechanism, the next patches
This adds a concrete subclass of pr-manager that talks to qemu-pr-helper.
Signed-off-by: Paolo Bonzini
---
scsi/Makefile.objs | 2 +-
scsi/pr-manager-helper.c | 288 +++
2 files changed, 289 insertions(+), 1 deletion(-)
On 22/08/2017 14:51, Stefan Hajnoczi wrote:
> This should fix the issue that Dave is seeing but I'm concerned that
> there are more problems in nbd-client.c. We don't have good
> abstractions for writing coroutine socket I/O code. Something like Go's
> channels would avoid manual low-level
There is a bunch of SCSI code that is shared by block/iscsi.c and
hw/scsi, and the introduction of the persistent reservation helper
will add more instances of this. There is also include/block/scsi.h,
which actually is not part of the core block layer.
Create a directory for this kind of shared
Complete the transition by renaming this header, which was
shared by block/iscsi.c and the SCSI emulation code.
Signed-off-by: Paolo Bonzini
---
block/iscsi.c | 2 +-
hw/block/virtio-blk.c | 2 +-
hw/scsi/megasas.c
SCSI persistent Reservations allow restricting access to block devices
to specific initiators in a shared storage setup. When implementing
clustering of virtual machines, it is a common requirement for virtual
machines to send persistent reservation SCSI commands. However,
the operating system
Move more knowledge of sense data format out of hw/scsi/scsi-bus.c
for reusability.
Signed-off-by: Paolo Bonzini
---
hw/scsi/scsi-bus.c | 8 +---
include/scsi/utils.h | 2 ++
scsi/utils.c | 11 +++
3 files changed, 14 insertions(+), 7 deletions(-)
Move more knowledge of SG_IO out of hw/scsi/scsi-generic.c, for
reusability.
Signed-off-by: Paolo Bonzini
---
hw/scsi/scsi-generic.c | 40 +++-
include/scsi/utils.h | 3 +++
scsi/utils.c | 35
It is pretty common to read a fixed-size buffer from a socket. Add a
function that does this, either with multiple reads (on blocking sockets)
or by yielding if called from a coroutine.
Cc: Daniel P. Berrange
Signed-off-by: Paolo Bonzini
---
Proper support of persistent reservation for multipath devices requires
communication with the multipath daemon, so that the reservation is
registered and applied when a path comes up. The device mapper
utilities provide a library to do so; this patch makes qemu-pr-helper.c
detect multipath
After introducing the scsi/ subdirectory, there will be a scsi_build_sense
function that is the same as scsi_req_build_sense but without needing
a SCSIRequest. The existing scsi_build_sense function gets in the way,
remove it.
Signed-off-by: Paolo Bonzini
---
This slightly change the error report message from "Invalid event
name" to "Invalid parameter".
Signed-off-by: Marc-André Lureau
---
block/blkdebug.c | 28
1 file changed, 8 insertions(+), 20 deletions(-)
diff --git a/block/blkdebug.c
73 matches
Mail list logo