Re: [Qemu-block] [Qemu-devel] Question about xen disk unplug support for ahci missed in qemu

2015-10-16 Thread Paul Durrant
> -Original Message- > From: Kevin Wolf [mailto:kw...@redhat.com] > Sent: 16 October 2015 16:02 > To: Paul Durrant > Cc: Fabio Fantoni; Stefano Stabellini; John Snow; Anthony Perard; qemu- > de...@nongnu.org; xen-de...@lists.xen.org; qemu-block@nongnu.org > Sub

Re: [Qemu-block] [Qemu-devel] Question about xen disk unplug support for ahci missed in qemu

2015-10-16 Thread Paul Durrant
> -Original Message- > From: Kevin Wolf [mailto:kw...@redhat.com] > Sent: 16 October 2015 15:04 > To: Paul Durrant > Cc: Fabio Fantoni; Stefano Stabellini; John Snow; Anthony Perard; qemu- > de...@nongnu.org; xen-de...@lists.xen.org; qemu-block@nongnu.org > Sub

Re: [Qemu-block] [Qemu-devel] Question about xen disk unplug support for ahci missed in qemu

2015-10-16 Thread Paul Durrant
> -Original Message- > From: Kevin Wolf [mailto:kw...@redhat.com] > Sent: 16 October 2015 17:12 > To: Paul Durrant > Cc: Fabio Fantoni; Stefano Stabellini; John Snow; Anthony Perard; qemu- > de...@nongnu.org; xen-de...@lists.xen.org; qemu-block@nongnu.org > Sub

Re: [Qemu-block] [Qemu-devel] Question about xen disk unplug support for ahci missed in qemu

2015-10-16 Thread Paul Durrant
> -Original Message- > From: Kevin Wolf [mailto:kw...@redhat.com] > Sent: 16 October 2015 17:43 > To: Paul Durrant > Cc: Fabio Fantoni; Stefano Stabellini; John Snow; Anthony Perard; qemu- > de...@nongnu.org; xen-de...@lists.xen.org; qemu-block@nongnu.org > Sub

Re: [Qemu-block] [Qemu-devel] Question about xen disk unplug support for ahci missed in qemu

2015-10-14 Thread Paul Durrant
> -Original Message- > From: Fabio Fantoni [mailto:fabio.fant...@m2r.biz] > Sent: 14 October 2015 12:12 > To: Kevin Wolf; Stefano Stabellini > Cc: John Snow; Anthony Perard; qemu-de...@nongnu.org; xen- > de...@lists.xen.org; qemu-block@nongnu.org; Paul Durrant > Sub

Re: [Qemu-block] [PATCH v2 3/3] xen-disk: use an IOThread per instance

2017-07-07 Thread Paul Durrant
> -Original Message- > From: Stefano Stabellini [mailto:sstabell...@kernel.org] > Sent: 22 June 2017 23:15 > To: Paul Durrant <paul.durr...@citrix.com> > Cc: xen-de...@lists.xenproject.org; qemu-de...@nongnu.org; qemu- > bl...@nongnu.org; Stefano Stabellini

Re: [Qemu-block] [PATCH v2 3/3] xen-disk: use an IOThread per instance

2017-07-10 Thread Paul Durrant
> -Original Message- [snip] > > > > +object_unparent(OBJECT(blkdev->iothread)); > > > > > > Shouldn't this be object_unref? > > > > > > > I don't think so. I think this is required to undo what was done by calling > object_property_add_child() on the root object. > > Right, so if

Re: [Qemu-block] [Xen-devel] [PATCH v2 0/3] xen-disk: performance improvements

2017-06-28 Thread Paul Durrant
> -Original Message- > From: Stefano Stabellini [mailto:sstabell...@kernel.org] > Sent: 27 June 2017 23:07 > To: Paul Durrant <paul.durr...@citrix.com> > Cc: xen-de...@lists.xenproject.org; qemu-de...@nongnu.org; qemu- > bl...@nongnu.org > Subject: Re: [Xen-dev

Re: [Qemu-block] [PATCH 1/3] xen-disk: only advertize feature-persistent if grant copy is not available

2017-06-21 Thread Paul Durrant
> -Original Message- > From: Roger Pau Monne > Sent: 21 June 2017 10:18 > To: Stefano Stabellini <sstabell...@kernel.org> > Cc: Paul Durrant <paul.durr...@citrix.com>; xen-de...@lists.xenproject.org; > qemu-de...@nongnu.org; qemu-block@nongnu.org;

Re: [Qemu-block] [Qemu-devel] [PATCH 1/3] xen-disk: only advertize feature-persistent if grant copy is not available

2017-06-21 Thread Paul Durrant
> -Original Message- > From: Qemu-devel [mailto:qemu-devel- > bounces+paul.durrant=citrix@nongnu.org] On Behalf Of Paul Durrant > Sent: 21 June 2017 10:36 > To: Roger Pau Monne <roger@citrix.com>; Stefano Stabellini > <sstabell...@kernel.org> >

Re: [Qemu-block] [Qemu-devel] [PATCH 1/3] xen-disk: only advertize feature-persistent if grant copy is not available

2017-06-21 Thread Paul Durrant
> -Original Message- > From: Roger Pau Monne > Sent: 21 June 2017 11:51 > To: Paul Durrant <paul.durr...@citrix.com> > Cc: Stefano Stabellini <sstabell...@kernel.org>; Kevin Wolf > <kw...@redhat.com>; qemu-block@nongnu.org; qemu-de...@nongnu.org; >

Re: [Qemu-block] [PATCH 2/3] xen-disk: add support for multi-page shared rings

2017-06-21 Thread Paul Durrant
> -Original Message- > From: Stefano Stabellini [mailto:sstabell...@kernel.org] > Sent: 20 June 2017 23:51 > To: Paul Durrant <paul.durr...@citrix.com> > Cc: xen-de...@lists.xenproject.org; qemu-de...@nongnu.org; qemu- > bl...@nongnu.org; Stefano Stabellini

[Qemu-block] [PATCH 1/3] xen-disk: only advertize feature-persistent if grant copy is not available

2017-06-20 Thread Paul Durrant
If grant copy is available then it will always be used in preference to persistent maps. In this case feature-persistent should not be advertized to the frontend, otherwise it may needlessly copy data into persistently granted buffers. Signed-off-by: Paul Durrant <paul.durr...@citrix.com>

[Qemu-block] [PATCH 2/3] xen-disk: add support for multi-page shared rings

2017-06-20 Thread Paul Durrant
The blkif protocol has had provision for negotiation of multi-page shared rings for some time now and many guest OS have support in their frontend drivers. This patch makes the necessary modifications to xen-disk support a shared ring up to order 4 (i.e. 16 pages). Signed-off-by: Paul Durrant

[Qemu-block] [PATCH 0/3] xen-disk: performance improvements

2017-06-20 Thread Paul Durrant
Paul Durrant (3): xen-disk: only advertize feature-persistent if grant copy is not available xen-disk: add support for multi-page shared rings xen-disk: use an IOThread per instance hw/block/trace-events | 7 ++ hw/block/xen_disk.c | 200

[Qemu-block] [PATCH 3/3] xen-disk: use an IOThread per instance

2017-06-20 Thread Paul Durrant
. Signed-off-by: Paul Durrant <paul.durr...@citrix.com> --- Cc: Stefano Stabellini <sstabell...@kernel.org> Cc: Anthony Perard <anthony.per...@citrix.com> Cc: Kevin Wolf <kw...@redhat.com> Cc: Max Reitz <mre...@redhat.com> --- hw/block/trace-events | 7 +

[Qemu-block] [PATCH v2 0/3] xen-disk: performance improvements

2017-06-21 Thread Paul Durrant
Paul Durrant (3): xen-disk: only advertize feature-persistent if grant copy is not available xen-disk: add support for multi-page shared rings xen-disk: use an IOThread per instance hw/block/trace-events | 7 ++ hw/block/xen_disk.c | 228

[Qemu-block] [PATCH v2 3/3] xen-disk: use an IOThread per instance

2017-06-21 Thread Paul Durrant
. Signed-off-by: Paul Durrant <paul.durr...@citrix.com> --- Cc: Stefano Stabellini <sstabell...@kernel.org> Cc: Anthony Perard <anthony.per...@citrix.com> Cc: Kevin Wolf <kw...@redhat.com> Cc: Max Reitz <mre...@redhat.com> v2: - explicitly acquire and release AI

[Qemu-block] [PATCH v2 2/3] xen-disk: add support for multi-page shared rings

2017-06-21 Thread Paul Durrant
The blkif protocol has had provision for negotiation of multi-page shared rings for some time now and many guest OS have support in their frontend drivers. This patch makes the necessary modifications to xen-disk support a shared ring up to order 4 (i.e. 16 pages). Signed-off-by: Paul Durrant

Re: [Qemu-block] [PATCH 3/3] xen-disk: use an IOThread per instance

2017-06-20 Thread Paul Durrant
> -Original Message- > From: Paolo Bonzini [mailto:paolo.bonz...@gmail.com] On Behalf Of Paolo > Bonzini > Sent: 20 June 2017 17:08 > To: Paul Durrant <paul.durr...@citrix.com>; xen-de...@lists.xenproject.org; > qemu-de...@nongnu.org; qemu-block@nongnu.org > Cc:

Re: [Qemu-block] [PATCH v2 7/8] xen_disk: use a single entry iovec

2018-05-04 Thread Paul Durrant
> -Original Message- > From: Paul Durrant [mailto:paul.durr...@citrix.com] > Sent: 04 May 2018 14:56 > To: xen-de...@lists.xenproject.org; qemu-block@nongnu.org; qemu- > de...@nongnu.org > Cc: Paul Durrant <paul.durr...@citrix.com>; Stefano Stabellini > <ss

[Qemu-block] [PATCH v3 4/8] xen_backend: add an emulation of grant copy

2018-05-04 Thread Paul Durrant
Not all Xen environments support the xengnttab_grant_copy() operation. E.g. where the OS is FreeBSD or Xen is older than 4.8.0. This patch introduces an emulation of that operation using xengnttab_map_domain_grant_refs() and memcpy() for those environments. Signed-off-by: Paul Durrant <paul.d

[Qemu-block] [PATCH v3 2/8] xen_disk: remove open-coded use of libxengnttab

2018-05-04 Thread Paul Durrant
Now that helpers are present in xen_backend, this patch removes open-coded calls to libxengnttab from the xen_disk code. This patch also fixes one whitspace error in the assignment of the XenDevOps initialise method. Signed-off-by: Paul Durrant <paul.durr...@citrix.com> --- Cc: S

[Qemu-block] [PATCH v3 5/8] xen_disk: remove use of grant map/unmap

2018-05-04 Thread Paul Durrant
Now that the (native or emulated) xen_be_copy_grant_refs() helper is always available, the xen_disk code can be significantly simplified by removing direct use of grant map and unmap operations. Signed-off-by: Paul Durrant <paul.durr...@citrix.com> --- Cc: Stefano Stabellini <

[Qemu-block] [PATCH v3 8/8] xen_disk: be consistent with use of xendev and blkdev->xendev

2018-05-04 Thread Paul Durrant
ent. This patch is a purely cosmetic patch which makes sure there is a xendev pointer on stack for any function where the pointer is need on multiple occasions modified those functions to use it consistently. Signed-off-by: Paul Durrant <paul.durr...@citrix.com> --- Cc: Stefano Stabellini

[Qemu-block] [PATCH v3 0/8] xen_disk: legacy code removal and cleanup

2018-05-04 Thread Paul Durrant
be simplified without regressing support for any environment. This series also performs general cleanup of the code by introducing and consistently using helper functions for calling into libxenttab. Paul Durrant (8): xen_backend: add grant table helpers xen_disk: remove open-coded use of libxengnttab

[Qemu-block] [PATCH v3 6/8] xen_backend: make the xen_feature_grant_copy flag private

2018-05-04 Thread Paul Durrant
There is no longer any use of this flag outside of the xen_backend code. Signed-off-by: Paul Durrant <paul.durr...@citrix.com> --- Cc: Stefano Stabellini <sstabell...@kernel.org> Cc: Anthony Perard <anthony.per...@citrix.com> v2: - New in v2 --- hw/xen/xen_backend.c

[Qemu-block] [PATCH v3 1/8] xen_backend: add grant table helpers

2018-05-04 Thread Paul Durrant
. No prior method requires access to the grant table. Signed-off-by: Paul Durrant <paul.durr...@citrix.com> --- Cc: Stefano Stabellini <sstabell...@kernel.org> Cc: Anthony Perard <anthony.per...@citrix.com> v2: - New in v2 --- hw/xen/xen_backe

[Qemu-block] [PATCH v3 3/8] xen: remove other open-coded use of libxengnttab

2018-05-04 Thread Paul Durrant
Now that helpers are available in xen_backend, use them throughout all Xen PV backends. Signed-off-by: Paul Durrant <paul.durr...@citrix.com> --- Cc: Stefano Stabellini <sstabell...@kernel.org> Cc: Anthony Perard <anthony.per...@citrix.com> Cc: Greg Kurz <gr...@kaod.org>

[Qemu-block] [PATCH v3 7/8] xen_disk: use a single entry iovec

2018-05-04 Thread Paul Durrant
Since xen_disk now always copies data to and from a guest there is no need to maintain a vector entry corresponding to every page of a request. This means there is less per-request state to maintain so the ioreq structure can shrink significantly. Signed-off-by: Paul Durrant <paul.d

[Qemu-block] [PATCH v2 2/8] xen_disk: remove open-coded use of libxengnttab

2018-05-04 Thread Paul Durrant
Now that helpers are present in xen_backend, this patch removes open-coded calls to libxengnttab from the xen_disk code. This patch also fixes one whitspace error in the assignment of the XenDevOps initialise method. Signed-off-by: Paul Durrant <paul.durr...@citrix.com> --- Cc: S

[Qemu-block] [PATCH v2 7/8] xen_disk: use a single entry iovec

2018-05-04 Thread Paul Durrant
Since xen_disk now always copies data to and from a guest there is no need to maintain a vector entry corresponding to every page of a request. This means there is less per-request state to maintain so the ioreq structure can shrink significantly. Signed-off-by: Paul Durrant <paul.d

[Qemu-block] [PATCH v2 1/8] xen_backend: add grant table helpers

2018-05-04 Thread Paul Durrant
. No prior method requires access to the grant table. Signed-off-by: Paul Durrant <paul.durr...@citrix.com> --- Cc: Stefano Stabellini <sstabell...@kernel.org> Cc: Anthony Perard <anthony.per...@citrix.com> v2: - New in v2 --- hw/xen/xen_backe

[Qemu-block] [PATCH v2 4/8] xen_backend: add an emulation of grant copy

2018-05-04 Thread Paul Durrant
Not all Xen environments support the xengnttab_grant_copy() operation. E.g. where the OS is FreeBSD or Xen is older than 4.8.0. This patch introduces an emulation of that operation using xengnttab_map_domain_grant_refs() and memcpy() for those environments. Signed-off-by: Paul Durrant <paul.d

[Qemu-block] [PATCH v2 5/8] xen_disk: remove use of grant map/unmap

2018-05-04 Thread Paul Durrant
Now that the (native or emulated) xen_be_copy_grant_refs() helper is always available, the xen_disk code can be significantly simplified by removing direct use of grant map and unmap operations. Signed-off-by: Paul Durrant <paul.durr...@citrix.com> --- Cc: Stefano Stabellini <

[Qemu-block] [PATCH v2 8/8] xen_disk: be consistent with use of xendev and blkdev->xendev

2018-05-04 Thread Paul Durrant
ent. This patch is a purely cosmetic patch which makes sure there is a xendev pointer on stack for any function where the pointer is need on multiple occasions modified those functions to use it consistently. Signed-off-by: Paul Durrant <paul.durr...@citrix.com> --- Cc: Stefano Stabellini

[Qemu-block] [PATCH v2 0/8] xen_disk: legacy code removal and cleanup

2018-05-04 Thread Paul Durrant
be simplified without regressing support for any environment. This version also performs general cleanup of the code by introducing and consistently using helper functions for calling into libxenttab. Paul Durrant (8): xen_backend: add grant table helpers xen_disk: remove open-coded use

[Qemu-block] [PATCH v2 3/8] xen: remove other open-coded use of libxengnttab

2018-05-04 Thread Paul Durrant
Now that helpers are available in xen_backend, use them throughout all Xen PV backends. Signed-off-by: Paul Durrant <paul.durr...@citrix.com> --- Cc: Stefano Stabellini <sstabell...@kernel.org> Cc: Anthony Perard <anthony.per...@citrix.com> Cc: Greg Kurz <gr...@kaod.org>

[Qemu-block] [PATCH v2 6/8] xen_backend: make the xen_feature_grant_copy flag private

2018-05-04 Thread Paul Durrant
There is no longer any use of this flag outside of the xen_backend code. Signed-off-by: Paul Durrant <paul.durr...@citrix.com> --- Cc: Stefano Stabellini <sstabell...@kernel.org> Cc: Anthony Perard <anthony.per...@citrix.com> v2: - New in v2 --- hw/xen/xen_backend.c

[Qemu-block] [PATCH v4 9/9] xen_disk: be consistent with use of xendev and blkdev->xendev

2018-05-17 Thread Paul Durrant
ent. This patch is a purely cosmetic patch which makes sure there is a xendev pointer on stack for any function where the pointer is need on multiple occasions modified those functions to use it consistently. Signed-off-by: Paul Durrant <paul.durr...@citrix.com> --- Cc: Stefano Stabellini

[Qemu-block] [PATCH v4 7/9] xen_backend: make the xen_feature_grant_copy flag private

2018-05-17 Thread Paul Durrant
There is no longer any use of this flag outside of the xen_backend code. Signed-off-by: Paul Durrant <paul.durr...@citrix.com> Acked-by: Anthony Perard <anthony.per...@citrix.com> --- Cc: Stefano Stabellini <sstabell...@kernel.org> v2: - New in v2 --- hw/xen/xen_bac

[Qemu-block] [PATCH v4 2/9] xen_backend: add grant table helpers

2018-05-17 Thread Paul Durrant
. No prior method requires access to the grant table. Signed-off-by: Paul Durrant <paul.durr...@citrix.com> --- Cc: Stefano Stabellini <sstabell...@kernel.org> Cc: Anthony Perard <anthony.per...@citrix.com> v2: - New in v2 --- hw/xen/xen_backe

[Qemu-block] [PATCH v4 6/9] xen_disk: remove use of grant map/unmap

2018-05-17 Thread Paul Durrant
Now that the (native or emulated) xen_be_copy_grant_refs() helper is always available, the xen_disk code can be significantly simplified by removing direct use of grant map and unmap operations. Signed-off-by: Paul Durrant <paul.durr...@citrix.com> Acked-by: Anthony Perard <an

[Qemu-block] [PATCH v4 5/9] xen_backend: add an emulation of grant copy

2018-05-17 Thread Paul Durrant
Not all Xen environments support the xengnttab_grant_copy() operation. E.g. where the OS is FreeBSD or Xen is older than 4.8.0. This patch introduces an emulation of that operation using xengnttab_map_domain_grant_refs() and memcpy() for those environments. Signed-off-by: Paul Durrant <paul.d

[Qemu-block] [PATCH v4 0/9] xen_disk: legacy code removal and cleanup

2018-05-17 Thread Paul Durrant
(previous patch #1) to remain unmodified from v3 but still compile against Xen 4.7. Paul Durrant (9): xen: add a meaningful declaration of grant_copy_segment into xen_common.h xen_backend: add grant table helpers xen_disk: remove open-coded use of libxengnttab xen: remove other open

[Qemu-block] [PATCH v4 4/9] xen: remove other open-coded use of libxengnttab

2018-05-17 Thread Paul Durrant
Now that helpers are available in xen_backend, use them throughout all Xen PV backends. Signed-off-by: Paul Durrant <paul.durr...@citrix.com> Acked-by: Anthony Perard <anthony.per...@citrix.com> --- Cc: Stefano Stabellini <sstabell...@kernel.org> Cc: Greg Kurz <gr...@kaod.o

[Qemu-block] [PATCH v4 1/9] xen: add a meaningful declaration of grant_copy_segment into xen_common.h

2018-05-17 Thread Paul Durrant
. Signed-off-by: Paul Durrant <paul.durr...@citrix.com> --- Cc: Stefano Stabellini <sstabell...@kernel.org> Cc: Anthony Perard <anthony.per...@citrix.com> v4: - New in v4 --- hw/block/xen_disk.c | 18 -- include/hw/xen/xen_common.h | 17 +++-- 2

[Qemu-block] [PATCH v4 3/9] xen_disk: remove open-coded use of libxengnttab

2018-05-17 Thread Paul Durrant
Now that helpers are present in xen_backend, this patch removes open-coded calls to libxengnttab from the xen_disk code. This patch also fixes one whitspace error in the assignment of the XenDevOps initialise method. Signed-off-by: Paul Durrant <paul.durr...@citrix.com> Acked-by: Anthony

Re: [Qemu-block] [PATCH v4 9/9] xen_disk: be consistent with use of xendev and blkdev->xendev

2018-05-17 Thread Paul Durrant
> -Original Message- > From: Paul Durrant [mailto:paul.durr...@citrix.com] > Sent: 17 May 2018 16:36 > To: xen-de...@lists.xenproject.org; qemu-block@nongnu.org; qemu- > de...@nongnu.org > Cc: Paul Durrant <paul.durr...@citrix.com>; Stefano Stabellini > <ss

[Qemu-block] [PATCH v4 8/9] xen_disk: use a single entry iovec

2018-05-17 Thread Paul Durrant
Since xen_disk now always copies data to and from a guest there is no need to maintain a vector entry corresponding to every page of a request. This means there is less per-request state to maintain so the ioreq structure can shrink significantly. Signed-off-by: Paul Durrant <paul.d

Re: [Qemu-block] [PATCH v3 4/8] xen_backend: add an emulation of grant copy

2018-05-16 Thread Paul Durrant
> -Original Message- > From: Anthony PERARD [mailto:anthony.per...@citrix.com] > Sent: 16 May 2018 15:31 > To: Paul Durrant <paul.durr...@citrix.com> > Cc: xen-de...@lists.xenproject.org; qemu-block@nongnu.org; qemu- > de...@nongnu.org; Stefano Stabellini <sstabe

Re: [Qemu-block] [PATCH v3 3/8] xen: remove other open-coded use of libxengnttab

2018-05-16 Thread Paul Durrant
> -Original Message- > From: Anthony PERARD [mailto:anthony.per...@citrix.com] > Sent: 16 May 2018 15:14 > To: Paul Durrant <paul.durr...@citrix.com> > Cc: xen-de...@lists.xenproject.org; qemu-block@nongnu.org; qemu- > de...@nongnu.org; Stefano Stabellini <ss

Re: [Qemu-block] [PATCH 0/4] block/xen_disk: legacy code removal and cleanup

2018-05-02 Thread Paul Durrant
> -Original Message- > From: Anthony PERARD [mailto:anthony.per...@citrix.com] > Sent: 02 May 2018 16:58 > To: Paul Durrant <paul.durr...@citrix.com> > Cc: xen-de...@lists.xenproject.org; qemu-block@nongnu.org; qemu- > de...@nongnu.org; Stefano Stabellini <sst

Re: [Qemu-block] [Xen-devel] [PATCH 2/4] block/xen_disk: remove use of grant map/unmap

2018-05-01 Thread Paul Durrant
> -Original Message- > From: Wei Liu [mailto:wei.l...@citrix.com] > Sent: 01 May 2018 11:30 > To: Paul Durrant <paul.durr...@citrix.com> > Cc: Roger Pau Monne <roger@citrix.com>; Kevin Wolf > <kw...@redhat.com>; Stefano Stabellini <sstabell..

Re: [Qemu-block] [Xen-devel] [PATCH 2/4] block/xen_disk: remove use of grant map/unmap

2018-04-30 Thread Paul Durrant
> -Original Message- > From: Roger Pau Monne > Sent: 30 April 2018 16:12 > To: Paul Durrant <paul.durr...@citrix.com> > Cc: xen-de...@lists.xenproject.org; qemu-block@nongnu.org; qemu- > de...@nongnu.org; Anthony Perard <anthony.per...@citrix.com>; Kevin >

Re: [Qemu-block] [Xen-devel] [PATCH 2/4] block/xen_disk: remove use of grant map/unmap

2018-04-30 Thread Paul Durrant
> -Original Message- > From: Roger Pau Monne > Sent: 30 April 2018 16:28 > To: Paul Durrant <paul.durr...@citrix.com> > Cc: xen-de...@lists.xenproject.org; qemu-block@nongnu.org; qemu- > de...@nongnu.org; Anthony Perard <anthony.per...@citrix.com>; Kevin >

[Qemu-block] [PATCH 1/4] block/xen_disk: remove persistent grant code

2018-04-30 Thread Paul Durrant
The grant copy operation was added to libxengnttab in Xen 4.8.0. If grant copy is available then persistent grants will not be used. The xen_disk source can be siginificantly simplified by removing this now redundant code. Signed-off-by: Paul Durrant <paul.durr...@citrix.com> --- Cc: S

[Qemu-block] [PATCH 0/4] block/xen_disk: legacy code removal and cleanup

2018-04-30 Thread Paul Durrant
this support for older versions of Xen from QEMU reduces the size of the xen_disk source by more than 350 lines (~25%). The majority of this is done in patches #1 and #2. Further simplifications are made in patch #3 and then some cosmetic work is done in patch #4. Paul Durrant (4): block/xen_disk: remove

[Qemu-block] [PATCH 3/4] block/xen_disk: use a single entry iovec

2018-04-30 Thread Paul Durrant
Since xen_disk now always copies data to and from a guest there is no need to maintain a vector entry corresponding to every page of a request. This means there is less per-request state to maintain so the ioreq structure can shrink significantly. Signed-off-by: Paul Durrant <paul.d

[Qemu-block] [PATCH 2/4] block/xen_disk: remove use of grant map/unmap

2018-04-30 Thread Paul Durrant
The grant copy operation was added to libxengnttab in Xen 4.8.0. If grant copy is available then data from the guest will be copied rather than mapped. The xen_disk source can be significantly simplified by removing this now redundant code. Signed-off-by: Paul Durrant <paul.durr...@citrix.

Re: [Qemu-block] xen_disk qdevification (was: [PATCH 0/3] Performance improvements for xen_disk v2)

2018-11-02 Thread Paul Durrant
> -Original Message- > From: Kevin Wolf [mailto:kw...@redhat.com] > Sent: 02 November 2018 11:04 > To: Tim Smith > Cc: xen-de...@lists.xenproject.org; qemu-de...@nongnu.org; qemu- > bl...@nongnu.org; Anthony Perard ; Paul Durrant > ; Stefano Stabellini ; > Max R

Re: [Qemu-block] [PATCH 1/3] Improve xen_disk batching behaviour

2018-11-02 Thread Paul Durrant
> -Original Message- > From: Tim Smith [mailto:tim.sm...@citrix.com] > Sent: 02 November 2018 10:01 > To: xen-de...@lists.xenproject.org; qemu-de...@nongnu.org; qemu- > bl...@nongnu.org > Cc: Anthony Perard ; Kevin Wolf > ; Paul Durrant ; Stefano > Stabellini ; Max

Re: [Qemu-block] [PATCH 2/3] Improve xen_disk response latency

2018-11-02 Thread Paul Durrant
> -Original Message- > From: Tim Smith [mailto:tim.sm...@citrix.com] > Sent: 02 November 2018 10:01 > To: xen-de...@lists.xenproject.org; qemu-de...@nongnu.org; qemu- > bl...@nongnu.org > Cc: Anthony Perard ; Kevin Wolf > ; Paul Durrant ; Stefano > Stabellin

Re: [Qemu-block] [PATCH 3/3] Avoid repeated memory allocation in xen_disk

2018-11-02 Thread Paul Durrant
> -Original Message- > From: Tim Smith [mailto:tim.sm...@citrix.com] > Sent: 02 November 2018 10:01 > To: xen-de...@lists.xenproject.org; qemu-de...@nongnu.org; qemu- > bl...@nongnu.org > Cc: Anthony Perard ; Kevin Wolf > ; Paul Durrant ; Stefano > Stabellini ; Max

Re: [Qemu-block] [Qemu-devel] xen_disk qdevification

2018-11-05 Thread Paul Durrant
> -Original Message- > From: Markus Armbruster [mailto:arm...@redhat.com] > Sent: 05 November 2018 15:58 > To: Paul Durrant > Cc: 'Kevin Wolf' ; Tim Smith ; > Stefano Stabellini ; qemu-block@nongnu.org; qemu- > de...@nongnu.org; Max Reitz ; Anth

Re: [Qemu-block] [Qemu-devel] xen_disk qdevification

2018-11-08 Thread Paul Durrant
> -Original Message- > From: Markus Armbruster [mailto:arm...@redhat.com] > Sent: 05 November 2018 15:58 > To: Paul Durrant > Cc: 'Kevin Wolf' ; Tim Smith ; > Stefano Stabellini ; qemu-block@nongnu.org; qemu- > de...@nongnu.org; Max Reitz ; Anth

Re: [Qemu-block] [Qemu-devel] xen_disk qdevification

2018-11-08 Thread Paul Durrant
> -Original Message- > From: Kevin Wolf [mailto:kw...@redhat.com] > Sent: 08 November 2018 15:21 > To: Paul Durrant > Cc: 'Markus Armbruster' ; Anthony Perard > ; Tim Smith ; Stefano > Stabellini ; qemu-block@nongnu.org; qemu- > de...@nongnu.or

Re: [Qemu-block] [Qemu-devel] xen_disk qdevification

2018-11-09 Thread Paul Durrant
> -Original Message- > From: Paul Durrant > Sent: 08 November 2018 16:44 > To: Paul Durrant ; 'Kevin Wolf' > > Cc: Stefano Stabellini ; qemu-block@nongnu.org; > Tim Smith ; qemu-de...@nongnu.org; 'Markus > Armbruster' ; Anthony Perard > ; xen-de...@list

Re: [Qemu-block] [Qemu-devel] xen_disk qdevification

2018-11-08 Thread Paul Durrant
> -Original Message- > From: Xen-devel [mailto:xen-devel-boun...@lists.xenproject.org] On Behalf > Of Paul Durrant > Sent: 08 November 2018 15:44 > To: 'Kevin Wolf' > Cc: Stefano Stabellini ; qemu-block@nongnu.org; > Tim Smith ; qemu-de...@nongnu.org; 'Markus &g

Re: [Qemu-block] [PATCH] hw/block/xen: use proper format string for printing sectors

2019-01-16 Thread Paul Durrant
> -Original Message- > From: Alex Bennée [mailto:alex.ben...@linaro.org] > Sent: 16 January 2019 12:14 > To: peter.mayd...@linaro.org > Cc: qemu-de...@nongnu.org; Alex Bennée ; Stefano > Stabellini ; Anthony Perard > ; Paul Durrant ; Kevin > Wolf ; Max Reitz

Re: [Qemu-block] [PATCH] xen: Fix format string

2019-01-16 Thread Paul Durrant
> -Original Message- > From: Xen-devel [mailto:xen-devel-boun...@lists.xenproject.org] On Behalf > Of Paul Durrant > Sent: 16 January 2019 12:04 > To: 'Philippe Mathieu-Daudé' ; qemu-de...@nongnu.org > Cc: Kevin Wolf ; Stefano Stabellini > ; qemu-block@nongnu.org;

Re: [Qemu-block] [PATCH] xen: Fix format string

2019-01-16 Thread Paul Durrant
> -Original Message- > From: Philippe Mathieu-Daudé [mailto:phi...@redhat.com] > Sent: 16 January 2019 12:01 > To: qemu-de...@nongnu.org > Cc: Paul Durrant ; Anthony Perard > ; Max Reitz ; qemu- > bl...@nongnu.org; Stefano Stabellini ; xen- > de...@lists.xe

Re: [Qemu-block] [Xen-devel] [PATCH] hw/block/xen: use proper format string for printing sectors

2019-01-17 Thread Paul Durrant
> -Original Message- > From: Alex Bennée [mailto:alex.ben...@linaro.org] > Sent: 17 January 2019 08:21 > To: Andrew Cooper > Cc: peter.mayd...@linaro.org; Kevin Wolf ; Stefano > Stabellini ; open list:Block layer core bl...@nongnu.org>; qemu-de...@nongnu.org; Max R

[Qemu-block] [PATCH] xen-block: handle resize callback

2019-01-23 Thread Paul Durrant
Some frontend drivers will handle dynamic resizing of PV disks, so set up the BlockDevOps resize_cb() method during xen_block_realize() to allow this to be done. Signed-off-by: Paul Durrant --- Cc: Stefan Hajnoczi Cc: Stefano Stabellini Cc: Anthony Perard Cc: Kevin Wolf Cc: Max Reitz

[Qemu-block] [PATCH v4 02/18] xen: introduce new 'XenBus' and 'XenDevice' object hierarchy

2018-12-11 Thread Paul Durrant
xen_be_init() function. Subsequent patches will flesh-out the functionality of these objects. Signed-off-by: Paul Durrant Reviewed-by: Anthony Perard --- Cc: Stefano Stabellini Cc: "Michael S. Tsirkin" Cc: Marcel Apfelbaum Cc: Paolo Bonzini Cc: Richard Henderson Cc: Eduardo Ha

[Qemu-block] [PATCH v4 16/18] xen: automatically create XenBlockDevice-s

2018-12-11 Thread Paul Durrant
is destroyed. Correspondingly the legacy backend scan for 'qdisk' is removed. After this patch is applied the legacy 'xen_disk' code is redundant. It will be removed by a subsequent patch. Signed-off-by: Paul Durrant Reviewed-by: Anthony Perard --- Cc: Kevin Wolf Cc: Max Reitz Cc: Stefano

[Qemu-block] [PATCH v4 07/18] xen: add event channel interface for XenDevice-s

2018-12-11 Thread Paul Durrant
The legacy PV backend infrastructure provides functions to bind, unbind and send notifications to event channnels. Similar functionality will be required by XenDevice implementations so this patch adds the necessary support. Signed-off-by: Paul Durrant Reviewed-by: Anthony Perard --- Cc

[Qemu-block] [PATCH v4 12/18] xen: remove 'ioreq' struct/varable/field names from dataplane/xen-block.c

2018-12-11 Thread Paul Durrant
' field/variable names with 'request', and then does necessary fix-up to adhere to coding style. Function names are not modified by this patch. They will be dealt with in a subsequent patch. No functional change. Signed-off-by: Paul Durrant Acked-by: Anthony Perard --- Cc: Stefan Hajnoczi Cc

[Qemu-block] [PATCH v4 14/18] xen: add implementations of xen-block connect and disconnect functions...

2018-12-11 Thread Paul Durrant
are mapped/bound and used to set up the dataplane. Signed-off-by: Paul Durrant --- Cc: Stefano Stabellini Cc: Anthony Perard Cc: Kevin Wolf Cc: Max Reitz v3: - Add missing return statement to xen_block_realize() - Set device name to 'vbd' now the backend is functional - Add an unplug handler

[Qemu-block] [PATCH v4 18/18] xen: remove the legacy 'xen_disk' backend

2018-12-11 Thread Paul Durrant
This backend has now been replaced by the 'xen-qdisk' XenDevice. Signed-off-by: Paul Durrant Acked-by: Anthony Perard --- Cc: Kevin Wolf Cc: Max Reitz Cc: Stefano Stabellini --- hw/block/Makefile.objs |1 - hw/block/xen_disk.c| 1011

Re: [Qemu-block] [PATCH v3 03/18] xen: introduce 'xen-block', 'xen-disk' and 'xen-cdrom'

2018-12-11 Thread Paul Durrant
> -Original Message- > From: Anthony PERARD [mailto:anthony.per...@citrix.com] > Sent: 11 December 2018 15:17 > To: Paul Durrant > Cc: qemu-de...@nongnu.org; qemu-block@nongnu.org; xen- > de...@lists.xenproject.org; Kevin Wolf ; Max Reitz > ; Stefano Stabellini >

[Qemu-block] [PATCH v4 11/18] xen: remove 'XenBlkDev' and 'blkdev' names from dataplane/xen-block

2018-12-11 Thread Paul Durrant
This is a purely cosmetic patch that substitutes the old 'struct XenBlkDev' name with 'XenBlockDataPlane' and 'blkdev' field/variable names with 'dataplane', and then does necessary fix-up to adhere to coding style. No functional change. Signed-off-by: Paul Durrant Acked-by: Anthony Perard

[Qemu-block] [PATCH v4 05/18] xen: add xenstore watcher infrastructure

2018-12-11 Thread Paul Durrant
-by: Paul Durrant Reviewed-by: Anthony Perard --- Cc: Kevin Wolf Cc: Max Reitz Cc: Stefano Stabellini v3: - Remove unnecessary instances of local_err v2: - Don't crash when xen_block_disconnect() fails - Check xs_unwatch() for error - Add new_watch() and free_watch() utility functions - Use

[Qemu-block] [PATCH v4 04/18] xen: create xenstore areas for XenDevice-s

2018-12-11 Thread Paul Durrant
is also added to make sure the xenstore areas are cleaned up if QEMU terminates without devices being unrealized. [1] The 'scanf' functions are actually not yet needed, but they will be needed by code delivered in subsequent patches. Signed-off-by: Paul Durrant Reviewed-by: Anthony Perard

[Qemu-block] [PATCH v4 08/18] xen: duplicate xen_disk.c as basis of dataplane/xen-block.c

2018-12-11 Thread Paul Durrant
harder. Signed-off-by: Paul Durrant Acked-by: Anthony Perard --- Cc: Stefano Stabellini Cc: Stefan Hajnoczi Cc: Kevin Wolf Cc: Max Reitz --- MAINTAINERS|1 + hw/block/dataplane/xen-block.c | 1019 2 files changed, 1020 insertions

[Qemu-block] [PATCH v4 10/18] xen: add header and build dataplane/xen-block.c

2018-12-11 Thread Paul Durrant
. These will be modified by subsequent patches. A typedef for XenBlockDataPlane has been added to the header (based on the old struct XenBlkDev name for the moment) so that the old names don't need to leak out of the dataplane code. Signed-off-by: Paul Durrant Reviewed-by: Anthony Perard --- Cc

[Qemu-block] [PATCH v4 17/18] MAINTAINERS: add myself as a Xen maintainer

2018-12-11 Thread Paul Durrant
. It therefore seems reasonable that I become a maintainer of the Xen code. Signed-off-by: Paul Durrant Acked-by: Anthony Perard Acked-by: Stefano Stabellini --- Cc: Paolo Bonzini v2: - Fix typo --- MAINTAINERS | 1 + 1 file changed, 1 insertion(+) diff --git a/MAINTAINERS b/MAINTAINERS index

Re: [Qemu-block] [PATCH v3 07/18] xen: add event channel interface for XenDevice-s

2018-12-11 Thread Paul Durrant
> -Original Message- > From: Anthony PERARD [mailto:anthony.per...@citrix.com] > Sent: 11 December 2018 15:25 > To: Paul Durrant > Cc: qemu-de...@nongnu.org; qemu-block@nongnu.org; xen- > de...@lists.xenproject.org > Subject: Re: [PATCH v3 07/18] xen: add ev

[Qemu-block] [PATCH v4 00/18] Xen PV backend 'qdevification'

2018-12-11 Thread Paul Durrant
-devel/2018-11/msg00259.html [2] http://xenbits.xen.org/gitweb/?p=people/pauldu/qemu.git;a=shortlog;h=refs/heads/qom29 Paul Durrant (18): xen: re-name XenDevice to XenLegacyDevice... xen: introduce new 'XenBus' and 'XenDevice' object hierarchy xen: introduce 'xen-block', 'xen-disk' and 'xen-cdrom

[Qemu-block] [PATCH v4 01/18] xen: re-name XenDevice to XenLegacyDevice...

2018-12-11 Thread Paul Durrant
to re-name parts of existing code to avoid name clashes. The re-named 'legacy' infrastructure will be removed once all backends have been ported to the new framework. This patch is purely cosmetic. No functional change. Signed-off-by: Paul Durrant Acked-by: Anthony Perard --- Cc: Stefano Stabellini

[Qemu-block] [PATCH v4 15/18] xen: add a mechanism to automatically create XenDevice-s...

2018-12-11 Thread Paul Durrant
the backend 'online' key to 0. NOTE: This patch only adds the framework. A subsequent patch will add a creator function for xen-block devices. Signed-off-by: Paul Durrant --- Cc: Anthony Perard Cc: Stefano Stabellini Cc: Anthony Perard v3: - Use a xenstore transaction in enumeration code

Re: [Qemu-block] [Xen-devel] [PATCH v3 09/18] xen: remove unnecessary code from dataplane/xen-block.c

2018-12-11 Thread Paul Durrant
> -Original Message- > From: Anthony PERARD [mailto:anthony.per...@citrix.com] > Sent: 11 December 2018 15:30 > To: Paul Durrant > Cc: qemu-de...@nongnu.org; qemu-block@nongnu.org; xen- > de...@lists.xenproject.org; Kevin Wolf ; Stefano > Stabellini ; Stefan H

[Qemu-block] [PATCH v4 06/18] xen: add grant table interface for XenDevice-s

2018-12-11 Thread Paul Durrant
The legacy PV backend infrastructure provides functions to map, unmap and copy pages granted by frontends. Similar functionality will be required by XenDevice implementations so this patch adds the necessary support. Signed-off-by: Paul Durrant Reviewed-by: Anthony Perard --- Cc: Stefano

[Qemu-block] [PATCH v4 13/18] xen: purge 'blk' and 'ioreq' from function names in dataplane/xen-block.c

2018-12-11 Thread Paul Durrant
This is a purely cosmetic patch that purges remaining use of 'blk' and 'ioreq' in local function names, and then makes sure all functions are prefixed with 'xen_block_'. No functional change. Signed-off-by: Paul Durrant Acked-by: Anthony Perard --- Cc: Stefano Stabellini Cc: Stefan Hajnoczi

[Qemu-block] [PATCH v4 09/18] xen: remove unnecessary code from dataplane/xen-block.c

2018-12-11 Thread Paul Durrant
(). NOTE: The code is still not yet built. Further transformations will be required to make it correctly interface to the new XenBus/XenDevice framework. They will be delivered in a subsequent patch. Signed-off-by: Paul Durrant Acked-by: Anthony Perard --- Cc: Stefano Stabellini Cc: Stefan

[Qemu-block] [PATCH v4 03/18] xen: introduce 'xen-block', 'xen-disk' and 'xen-cdrom'

2018-12-11 Thread Paul Durrant
] https://xenbits.xen.org/docs/unstable/man/xen-vbd-interface.7.html Signed-off-by: Paul Durrant Reviewed-by: Anthony Perard --- Cc: Kevin Wolf Cc: Max Reitz Cc: Stefano Stabellini v3: - Fix vdev parsing again, and vdev formatting this time - Remove an unnecessary local_err v2: - Fix

Re: [Qemu-block] [Xen-devel] [PATCH v1] xen_disk: fix memory leak

2018-12-13 Thread Paul Durrant
> -Original Message- > From: Xen-devel [mailto:xen-devel-boun...@lists.xenproject.org] On Behalf > Of Anthony PERARD > Sent: 13 December 2018 11:34 > To: Olaf Hering > Cc: Kevin Wolf ; Stefano Stabellini > ; open list:Block layer core bl...@nongnu.org>; qemu-de...@nongnu.org; Max Reitz ;

Re: [Qemu-block] [PATCH v4 16/18] xen: automatically create XenBlockDevice-s

2018-12-13 Thread Paul Durrant
> -Original Message- > From: Kevin Wolf [mailto:kw...@redhat.com] > Sent: 13 December 2018 11:52 > To: Paul Durrant > Cc: qemu-de...@nongnu.org; qemu-block@nongnu.org; xen- > de...@lists.xenproject.org; Max Reitz ; Stefano > Stabellini > Subject: Re: [PATCH v4 1

[Qemu-block] [PATCH v3 1/3] xen-block: improve batching behaviour

2018-12-12 Thread Paul Durrant
()/ blk_io_unplug() in an amount proportional to the number which were already in flight at the time we started reading the ring. Signed-off-by: Tim Smith Re-based and commit comment adjusted. Signed-off-by: Paul Durrant --- Cc: Stefan Hajnoczi Cc: Stefano Stabellini Cc: Anthony Perard Cc: Kevin Wolf

[Qemu-block] [PATCH v3 2/3] xen-block: improve response latency

2018-12-12 Thread Paul Durrant
-based and commit comment adjusted. Signed-off-by: Paul Durrant --- Cc: Stefan Hajnoczi Cc: Stefano Stabellini Cc: Anthony Perard Cc: Kevin Wolf Cc: Max Reitz --- hw/block/dataplane/xen-block.c | 56 ++ 1 file changed, 18 insertions(+), 38 deletions

  1   2   3   4   5   >