The old VHD_MAX_SECTORS value is incorrect, and is a throwback
to the CHS calculations. The VHD specification allows images up to 2040
GiB, which (using 512 byte sectors) corresponds to a maximum number of
sectors of 0xff00, rather than the old value of 0xfe0001ff.
Update VHD_MAX_SECTORS to r
The check on the max_table_size field not being larger than required is
valid, and in accordance with the VHD spec. However, there have been
VHD images encountered in the wild that have an out-of-spec max table
size that is technically too large.
There is no issue in allowing this larger table si
Signed-off-by: Jeff Cody
---
block/vpc.c | 70 ++---
1 file changed, 35 insertions(+), 35 deletions(-)
diff --git a/block/vpc.c b/block/vpc.c
index 5dd9950..0b48cf4 100644
--- a/block/vpc.c
+++ b/block/vpc.c
@@ -36,7 +36,7 @@
#define HEA
XenConverter VHD images are another VHD image where current_size is
different from the CHS values in the the format header. Use
current_size as the default, by looking at the creator_app signature
field.
Signed-off-by: Jeff Cody
---
block/vpc.c | 2 ++
1 file changed, 2 insertions(+)
diff --gi
From: Stefan Hajnoczi
The vpc driver has two methods of determining virtual disk size. The
correct one to use depends on the software that generated the image
file. Add the XenServer creator_app signature so that image size is
correctly detected for those images.
Reported-by: Grant Wu
Reporte
Commit 'b8f45cdf7827e39f9a1e6cc446f5972cc6144237' switched VPC
over to using blk_pwrite() instead of bdrv_pwrite_sync(). The
return value of bdrv_pwrite_sync() was always 0 for success, and
create_dynamic_disk() in one instance checked for a non-zero return
value to indicate error. However, blk_p
Add more useful error information to failure paths in vpc_open
Signed-off-by: Jeff Cody
---
block/vpc.c | 9 +
1 file changed, 9 insertions(+)
diff --git a/block/vpc.c b/block/vpc.c
index 67ab376..5dd9950 100644
--- a/block/vpc.c
+++ b/block/vpc.c
@@ -237,6 +237,7 @@ static int vpc_open
Fixes for a regression in vpc_create(), as well as a few issues with VHD format
compatibility.
Jeff Cody (6):
block/vpc: fix VPC 'qemu-img create' regression
block/vpc: use current_size field for XenConverter VHD images
block/vpc: Use the correct max sector count for VHD images
block/vpc:
On 03/22/2016 09:33 AM, Kevin Wolf wrote:
> Some features, like I/O throttling, are implemented outside
> block-backend.c, but still want to keep BlockBackends in a list. In
> order to avoid exposing the whole struct layout in the public header
> file, this patch introduces an embedded public struc
On 03/15/2016 04:04 PM, Vladimir Sementsov-Ogievskiy wrote:
> Add functions for load/store HBitmap to BDS, using clusters table:
> Last level of the bitmap is splitted into chunks of 'cluster_size'
> size. Each cell of the table contains offset in bds, to load/store
> corresponding chunk.
>
> Al
On 03/22/2016 09:33 AM, Kevin Wolf wrote:
> It was already true in principle that a throttled BDS always has a BB
> attached, except that the order of operations while attaching or
> detaching a BDS to/from a BB wasn't careful enough.
>
> This commit breaks graph manipulations while I/O throttling
On 03/22/2016 09:33 AM, Kevin Wolf wrote:
> We had to disable I/O throttling with synchronous requests because we
> didn't use to run timers in nested event loops when the code was
> introduced. This isn't true any more, and throttling works just fine
> even when using the synchronous API.
>
> The
On 03/10/2016 11:59 AM, Daniel P. Berrange wrote:
> The VNC server has historically had support for ACLs to check
> both the SASL username and the TLS x509 distinguished name.
> The VNC server was responsible for creating the initial ACL,
> and the client app was then responsible for populating it
On 22/03/2016 20:36, Kevin Wolf wrote:
> This is the final patch series that is required before we can start allowing
> setups with more than one BlockBackend per BlockDriverState.
>
> My current plan is to put the patches up to (and including) this series into
> 2.6 so that we have a relatively
On 22/03/2016 16:33, Kevin Wolf wrote:
> This is another feature that was "logically" part of the BlockBackend, but
> implemented as a BlockDriverState feature. It was always kept on top using
> swap_feature_fields().
>
> This series moves it to be actually implemented in the BlockBackend, removin
On 03/10/2016 11:59 AM, Daniel P. Berrange wrote:
> Currently any client which can complete the TLS handshake
> is able to use a chardev server. The server admin can turn
> on the 'verify-peer' option for the x509 creds to require
> the client to provide a x509 certificate. This means the
> client
This patch removes the remaining users of bs->blk, which will allow us
to have multiple BBs on top of a single BDS. All checks that are
currently in place to prevent the user from creating such setups.
Future patches can allow them and e.g. enable users to mirror to a block
device that already has
query-named-block-nodes should not return information that is related
to the attached BlockBackend rather than the node itself, so throttling
information needs to be removed from it.
Signed-off-by: Kevin Wolf
---
block/qapi.c | 6 +++---
tests/qemu-iotests/096 | 3 ++-
2 files changed,
We just want to know whether a BDS has at least one BB attached in order
to avoid enumerating it twice. This doesn't depend on the exact BB that
is attached and is still a valid question when more than one BB can be
attached, so just answer it by checking the parents list.
Signed-off-by: Kevin Wol
bdrv_move_feature_fields() and swap_feature_fields() are empty now, they
can be removed.
Signed-off-by: Kevin Wolf
---
block.c | 30 --
1 file changed, 30 deletions(-)
diff --git a/block.c b/block.c
index 66f918e..3770fb0 100644
--- a/block.c
+++ b/block.c
@@ -,1
Since virtio-blk implements request merging itself these days, the only
remaining users are test cases for the function. That doesn't make the
function exactly useful any more.
Signed-off-by: Kevin Wolf
---
block/block-backend.c | 14 ---
block/io.c | 194 --
In order to get rid of bs->blk for bdrv_get_device_name() and
bdrv_get_device_or_node_name(), ask all parents for their name and
simply pick the first one.
Signed-off-by: Kevin Wolf
---
block.c | 22 --
block/block-backend.c | 6 ++
include/block/bl
The block jobs currently modify the target BB's error handling options
and require that the source BB's iostatus is enabled in order to
implement the per-job error options. It's obvious that this is something
between ugly, adventurous and plain wrong, so we should ideally fix this
instead of thinki
We need to introduce a separate BdrvNextIterator struct that can keep
more state than just the current BDS in order to avoid using the bs->blk
pointer.
Signed-off-by: Kevin Wolf
---
block.c| 34 +---
block/block-backend.c | 44
This is the final patch series that is required before we can start allowing
setups with more than one BlockBackend per BlockDriverState.
My current plan is to put the patches up to (and including) this series into
2.6 so that we have a relatively consistent block layer state in the release
that i
We want to get rid of BlockDriverState.blk in order to allow multiple
BlockBackends per BDS. Converting the device callbacks in block.c (which
assume a single BlockBackend) to per-child callbacks gets us rid of the
first few instances.
Signed-off-by: Kevin Wolf
---
block.c | 38
On 03/15/2016 02:04 PM, Vladimir Sementsov-Ogievskiy wrote:
> If this flag is unset and exta data present the bitmap should be
s/exta/extra/
s/present/is present/
> read-only. For now just return error for this case.
>
> Signed-off-by: Vladimir Sementsov-Ogievskiy
> ---
> block/qcow2-dirty-bit
On 03/15/2016 02:04 PM, Vladimir Sementsov-Ogievskiy wrote:
In the subject: s/stroing/storing/
> Check, that bitmap is stored to the owning bs.
>
> Signed-off-by: Vladimir Sementsov-Ogievskiy
> ---
--
Eric Blake eblake redhat com+1-919-301-3266
Libvirt virtualization library http://libv
On 03/15/2016 02:04 PM, Vladimir Sementsov-Ogievskiy wrote:
> The function checks existing of the bitmap without loading it.
s/existing/the existence/
>
> Signed-off-by: Vladimir Sementsov-Ogievskiy
> ---
--
Eric Blake eblake redhat com+1-919-301-3266
Libvirt virtualization library http
On 03/15/2016 02:04 PM, Vladimir Sementsov-Ogievskiy wrote:
> This function stores block dirty bitmap to qcow2. If the bitmap with
> the same name, size and granularity already exists, it will be
> rewritten, if the bitmap with the same name exists but granularity or
> size does not match, an error
On 03/15/2016 02:04 PM, Vladimir Sementsov-Ogievskiy wrote:
> Add simple test cases for testing persistent dirty bitmaps.
>
> Signed-off-by: Vladimir Sementsov-Ogievskiy
> ---
> tests/qemu-iotests/160| 112
> ++
> tests/qemu-iotests/160.out|
On 03/15/2016 02:04 PM, Vladimir Sementsov-Ogievskiy wrote:
in subject: s/launcn/launch/
> Test vm can launch and print output in case of fail. This function is
> needed for testing erroneous cases
>
> Signed-off-by: Vladimir Sementsov-Ogievskiy
> ---
> tests/qemu-iotests/iotests.py | 20 +
On 03/10/2016 11:59 AM, Daniel P. Berrange wrote:
> As with the previous patch to qemu-nbd, the nbd-server-start
> QMP command also needs to be able to specify an ACL when
> enabling TLS encryption.
>
> First the client must create a QAuthZ object instance using
> the 'object-add' command:
>
> S
On 03/10/2016 11:59 AM, Daniel P. Berrange wrote:
> Currently any client which can complete the TLS handshake
> is able to use the NBD server. The server admin can turn
> on the 'verify-peer' option for the x509 creds to require
> the client to provide a x509 certificate. This means the
> client wi
On 03/15/2016 04:04 PM, Vladimir Sementsov-Ogievskiy wrote:
> When testing migration, auto-generated by qemu node-names differs in
> source and destination qemu and migration fails. After this patch,
> auto-generated by iotest nodenames will be the same.
>
> Signed-off-by: Vladimir Sementsov-Ogi
On 03/15/2016 04:08 PM, Vladimir Sementsov-Ogievskiy wrote:
> On 15.03.2016 23:04, Vladimir Sementsov-Ogievskiy wrote:
>> 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
>> Signed-off-by
On 22/03/2016 13:52, Fam Zheng wrote:
>> You're right. After unrealizing virtio_blk_data_plane_stop has set of
>> vblk->dataplane_started = false, so that's covered. However, you still
>> need an object_ref/object_object_unref pair.
>
> Is it safe to call object_unref outside BQL?
Hmm, no.
H
On 03/10/2016 11:59 AM, Daniel P. Berrange wrote:
> The 'qemu_acl' type was a previous non-QOM based attempt to
> provide an authorization facility in QEMU. Because it is
> non-QOM based it cannot be created via the command line and
> requires special monitor commands to manipulate it.
>
> The new
On 03/10/2016 11:59 AM, Daniel P. Berrange wrote:
> Add a QAuthZSimple object type that implements the QAuthZ
> interface. This simple built-in implementation maintains
> a trivial access control list with a sequence of match
> rules and a final default policy. This replicates the
> functionality c
Am 22.03.2016 um 16:50 hat Markus Armbruster geschrieben:
> Peter Xu writes:
>
> > One is to use literal printf format when possible.
> >
> > One is to fix an unbounded usage of stack.
>
> I lack the time to take this through my tree before my Easter vacation.
> Kevin, can you stick it into your
On Tue, Mar 22, 2016 at 10:33:42AM -0600, Eric Blake wrote:
> On 03/10/2016 11:59 AM, Daniel P. Berrange wrote:
> > The current qemu_acl module provides a simple access control
> > list facility inside QEMU, which is used via a set of monitor
> > commands acl_show, acl_policy, acl_add, acl_remove &
On 03/15/2016 02:08 PM, Vladimir Sementsov-Ogievskiy wrote:
> On 15.03.2016 23:04, Vladimir Sementsov-Ogievskiy wrote:
>> 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
>> Signed-off-by:
On Tue, Mar 22, 2016 at 10:33:42AM -0600, Eric Blake wrote:
> On 03/10/2016 11:59 AM, Daniel P. Berrange wrote:
> > The current qemu_acl module provides a simple access control
> > list facility inside QEMU, which is used via a set of monitor
> > commands acl_show, acl_policy, acl_add, acl_remove &
On 03/10/2016 11:59 AM, Daniel P. Berrange wrote:
> The current qemu_acl module provides a simple access control
> list facility inside QEMU, which is used via a set of monitor
> commands acl_show, acl_policy, acl_add, acl_remove & acl_reset.
>
> Note there is no ability to create ACLs - the netwo
On 03/22/2016 09:49 AM, Daniel P. Berrange wrote:
> On Mon, Mar 21, 2016 at 05:18:01PM -0600, Eric Blake wrote:
>> On 03/10/2016 11:59 AM, Daniel P. Berrange wrote:
>>> Currently the QmpInputVisitor assumes that all scalar
>>> values are directly represented as their final types.
>>> ie it assumes
On 03/22/2016 06:55 AM, Kevin Wolf wrote:
> The function is unused since commit f21d96d0 ('block: Use BdrvChild in
> BlockBackend').
>
> Signed-off-by: Kevin Wolf
> ---
> block/block-backend.c | 17 -
> include/block/block_int.h | 2 --
> 2 files changed, 19 deletions(-)
Re
On Mon, Mar 21, 2016 at 05:27:24PM -0600, Eric Blake wrote:
> On 03/10/2016 11:59 AM, Daniel P. Berrange wrote:
> > The current -object command line syntax only allows for
> > creation of objects with scalar properties, or a list
> > with a fixed scalar element type. Objects which have
> > properti
Peter Xu writes:
> One is to use literal printf format when possible.
>
> One is to fix an unbounded usage of stack.
I lack the time to take this through my tree before my Easter vacation.
Kevin, can you stick it into your next pull request for me? Note
trivial fixup on PATCH 2.
On Mon, Mar 21, 2016 at 05:18:01PM -0600, Eric Blake wrote:
> On 03/10/2016 11:59 AM, Daniel P. Berrange wrote:
> > Currently the QmpInputVisitor assumes that all scalar
> > values are directly represented as their final types.
> > ie it assumes an 'int' is using QInt, and a 'bool' is
> > using QBo
Peter Xu writes:
> Using heap instead of stack for better safety.
>
> Signed-off-by: Peter Xu
> ---
> block/qapi.c | 4 ++--
> 1 file changed, 2 insertions(+), 2 deletions(-)
>
> diff --git a/block/qapi.c b/block/qapi.c
> index c4c2115..b798e35 100644
> --- a/block/qapi.c
> +++ b/block/qapi.c
>
Peter Xu writes:
> Fix two places to use literal printf format when possible.
>
> Signed-off-by: Peter Xu
Reviewed-by: Markus Armbruster
On Mon, Mar 21, 2016 at 04:45:39PM -0600, Eric Blake wrote:
> On 03/10/2016 11:59 AM, Daniel P. Berrange wrote:
> > +/* Unescape the '..' sequence into '.' */
> > +for (i = 0, j = 0; (*prefix)[i] != '\0'; i++, j++) {
> > +if ((*prefix)[i] == '.' &&
> > +(*prefix)[i + 1]
Some features, like I/O throttling, are implemented outside
block-backend.c, but still want to keep BlockBackends in a list. In
order to avoid exposing the whole struct layout in the public header
file, this patch introduces an embedded public struct where list entry
structs can be added and a pair
Checking whether there are throttled requests requires going to the
associated BlockBackend, which we want to avoid. All users of
bdrv_requests_pending() already call bdrv_flush_io_queue() first, which
restarts throttled requests. We just have to use the return value of
that callback (which tells u
This removes the last part of I/O throttling from block/io.c and moves
it to the BlockBackend.
When draining the queue of a BlockDriverState, we must make sure that no
new requests can come in for it. Request sources from outside the block
layer are disabled with aio_disable_external(), but the th
BlockBackends use it to get a back pointer from BdrvChild to
BlockBackend in any BdrvChildRole callbacks.
Signed-off-by: Kevin Wolf
---
block/block-backend.c | 2 ++
include/block/block_int.h | 1 +
2 files changed, 3 insertions(+)
diff --git a/block/block-backend.c b/block/block-backend.c
Signed-off-by: Kevin Wolf
---
block.c | 2 +-
block/block-backend.c | 49 +++--
block/io.c | 47 +--
block/qapi.c| 2 +-
block/throttle-groups.c
Signed-off-by: Kevin Wolf
---
block/block-backend.c | 10 ++
block/io.c | 10 --
block/throttle-groups.c | 5 ++---
include/block/throttle-groups.h | 2 +-
4 files changed, 13 insertions(+), 14 deletions(-)
diff --git a/block/block-backend
Signed-off-by: Kevin Wolf
---
block/block-backend.c | 2 +-
block/io.c | 2 +-
block/qapi.c| 2 +-
block/throttle-groups.c | 12 ++--
include/block/throttle-groups.h | 2 +-
tests/test-throttle.c | 4 ++--
6 files c
This moves the throttling related part of the BDS life cycle management
to BlockBackend. The throttling group reference is now kept even when no
medium is inserted.
With this commit, throttling isn't disabled and then re-enabled any more
during graph reconfiguration. This fixes the temporary break
This patch changes where the throttling state is stored (used to be the
BlockDriverState, now it is the BlockBackend), but it doesn't actually
make it a BB level feature yet. For example, throttling is still
disabled when the BDS is detached from the BB.
Signed-off-by: Kevin Wolf
---
block.c
We had to disable I/O throttling with synchronous requests because we
didn't use to run timers in nested event loops when the code was
introduced. This isn't true any more, and throttling works just fine
even when using the synchronous API.
The removed code is in fact dead code since commit a8823a
This is another feature that was "logically" part of the BlockBackend, but
implemented as a BlockDriverState feature. It was always kept on top using
swap_feature_fields().
This series moves it to be actually implemented in the BlockBackend, removing
another obstacle for removing bs->blk and allow
As a first step towards moving I/O throttling to the BlockBackend level,
this patch changes all pointers in struct ThrottleGroup from referencing
a BlockDriverState to referencing a BlockBackend.
This change is valid because we made sure that throttling can only be
enabled on BDSes which have a BB
It was already true in principle that a throttled BDS always has a BB
attached, except that the order of operations while attaching or
detaching a BDS to/from a BB wasn't careful enough.
This commit breaks graph manipulations while I/O throttling is enabled.
It would have been possible, but quite
root@storage-4:~# hexdump -C -n 512 -s 512 /dev/vgstorage/tartanfsbackup
0200 63 78 73 70 61 72 73 65 ff ff ff ff ff ff ff ff
|cxsparse|
0210 00 00 00 00 00 00 06 00 00 01 00 00 00 10 00 00
||
0220 00 20 00 00 ff ff f4 67 00 00 00 00 00 00 00 00 |.
.
On Fri, 18 Mar 2016, Kevin Wolf wrote:
> Signed-off-by: Kevin Wolf
> ---
> hw/block/xen_disk.c | 5 -
> 1 file changed, 4 insertions(+), 1 deletion(-)
>
> diff --git a/hw/block/xen_disk.c b/hw/block/xen_disk.c
> index 635328f..c358709 100644
> --- a/hw/block/xen_disk.c
> +++ b/hw/block/xen_d
On Tue, 22 Mar 2016 13:11:05 +0100
Paolo Bonzini wrote:
> On 22/03/2016 12:59, Cornelia Huck wrote:
> >> > They can be fixed with just an extra object_ref/object_unref.
> >> >
> >> > I didn't understand that Tu Bo also needed the BH fix, and with that
> >> > information it makes sense. Passing
The function is unused since commit f21d96d0 ('block: Use BdrvChild in
BlockBackend').
Signed-off-by: Kevin Wolf
---
block/block-backend.c | 17 -
include/block/block_int.h | 2 --
2 files changed, 19 deletions(-)
diff --git a/block/block-backend.c b/block/block-backend.c
i
On Thu, 03/17 16:07, Paolo Bonzini wrote:
>
>
> On 17/03/2016 16:00, Stefan Hajnoczi wrote:
> >> > +data = g_new(VirtIOBlockStartData, 1);
> >> > +data->vblk = vblk;
> >> > +data->bh = aio_bh_new(s->ctx, virtio_blk_data_plane_start_bh_cb,
> >> > data);
> >> > +qemu_bh_schedule(da
On 22/03/2016 12:59, Cornelia Huck wrote:
>> > They can be fixed with just an extra object_ref/object_unref.
>> >
>> > I didn't understand that Tu Bo also needed the BH fix, and with that
>> > information it makes sense. Passing the assign value ensures that
>> > ioeventfd remains always assign
On Tue, 22 Mar 2016 10:46:58 +0100
Paolo Bonzini wrote:
> On 22/03/2016 10:07, Cornelia Huck wrote:
> > So far, we had the best results with my refactoring + the mutex/bh
> > change. Two problems:
> >
> > - We don't really understand yet why my refactoring helps, but passing
> > the assign value
On 22.03.2016 01:42, John Snow wrote:
On 03/15/2016 04:04 PM, Vladimir Sementsov-Ogievskiy wrote:
Add functions for load/store HBitmap to BDS, using clusters table:
Last level of the bitmap is splitted into chunks of 'cluster_size'
size. Each cell of the table contains offset in bds, to load/st
On Mon, Mar 21, 2016 at 02:37:46PM -0400, Spencer Baugh wrote:
> Stefan Hajnoczi writes:
> > What output did you get from "qemu-img info /dev/dm-1"?
>
> After the patching:
>
> root@storage-4:~# hexdump -C -n 512 /dev/vgstorage/tartanfsbackup
> 63 6f 6e 65 63 74 69 78 00 00 00 02 00 0
On Mon, Mar 21, 2016 at 02:08:16PM -0600, Eric Blake wrote:
> On 03/21/2016 08:11 AM, Daniel P. Berrange wrote:
> > Currently all block tests use the traditional syntax for images
> > just specifying a filename. To support the LUKS driver without
> > resorting to JSON, the tests need to be able to
On Tue, Mar 22, 2016 at 10:07:42AM +0100, Markus Armbruster wrote:
> Eric Blake writes:
>
> > On 03/10/2016 11:59 AM, Daniel P. Berrange wrote:
> >> The current -object command line syntax only allows for
> >> creation of objects with scalar properties, or a list
> >> with a fixed scalar element
On 22/03/2016 10:07, Cornelia Huck wrote:
> So far, we had the best results with my refactoring + the mutex/bh
> change. Two problems:
>
> - We don't really understand yet why my refactoring helps, but passing
> the assign value is a good canditate (and it's agreed that this fixes a
> bug, I thi
Eric Blake writes:
> On 03/10/2016 11:59 AM, Daniel P. Berrange wrote:
>> The current -object command line syntax only allows for
>> creation of objects with scalar properties, or a list
>> with a fixed scalar element type. Objects which have
>> properties that are represented as structs in the Q
(re-adding cc:s)
On Tue, 22 Mar 2016 15:18:05 +0800
Fam Zheng wrote:
> On Tue, 03/22 15:10, tu bo wrote:
> > Hi Fam:
> >
> > On 03/21/2016 06:57 PM, Fam Zheng wrote:
> > >On Thu, 03/17 19:03, tu bo wrote:
> > >>
> > >>On 03/17/2016 08:39 AM, Fam Zheng wrote:
> > >>>On Wed, 03/16 14:45, Paolo Bo
On Tue, 22 Mar 2016 07:45:19 +0800
Fam Zheng wrote:
> On Mon, 03/21 14:02, Cornelia Huck wrote:
> > On Mon, 21 Mar 2016 20:45:27 +0800
> > Fam Zheng wrote:
> >
> > > On Mon, 03/21 12:15, Cornelia Huck wrote:
> > > > On Mon, 21 Mar 2016 18:57:18 +0800
> > > > Fam Zheng wrote:
> > > >
> > > > >
80 matches
Mail list logo