* [Qemu-devel] [PULL 0/1] xen-20160905
@ 2016-09-05 19:02 ` Stefano Stabellini
0 siblings, 0 replies; 6+ messages in thread
From: Stefano Stabellini @ 2016-09-05 19:02 UTC (permalink / raw)
To: peter.maydell; +Cc: sstabellini, qemu-devel, xen-devel
The following changes since commit 12d2c4184c5ab60be3428b2bdea5ae66e8d5d960:
Update version for v2.7.0-rc5 release (2016-08-30 20:39:45 +0100)
are available in the git repository at:
git://xenbits.xen.org/people/sstabellini/qemu-dm.git tags/xen-20160905
for you to fetch changes up to 4ada797b05a52ac824a710c67216b37739026a64:
xen: use native disk xenbus protocol if possible (2016-08-30 15:01:01 -0700)
----------------------------------------------------------------
Xen 2016/09/05
----------------------------------------------------------------
Juergen Gross (1):
xen: use native disk xenbus protocol if possible
hw/block/xen_disk.c | 18 ++++++++++--------
1 file changed, 10 insertions(+), 8 deletions(-)
^ permalink raw reply [flat|nested] 6+ messages in thread
* [PULL 0/1] xen-20160905
@ 2016-09-05 19:02 ` Stefano Stabellini
0 siblings, 0 replies; 6+ messages in thread
From: Stefano Stabellini @ 2016-09-05 19:02 UTC (permalink / raw)
To: peter.maydell; +Cc: xen-devel, sstabellini, qemu-devel
The following changes since commit 12d2c4184c5ab60be3428b2bdea5ae66e8d5d960:
Update version for v2.7.0-rc5 release (2016-08-30 20:39:45 +0100)
are available in the git repository at:
git://xenbits.xen.org/people/sstabellini/qemu-dm.git tags/xen-20160905
for you to fetch changes up to 4ada797b05a52ac824a710c67216b37739026a64:
xen: use native disk xenbus protocol if possible (2016-08-30 15:01:01 -0700)
----------------------------------------------------------------
Xen 2016/09/05
----------------------------------------------------------------
Juergen Gross (1):
xen: use native disk xenbus protocol if possible
hw/block/xen_disk.c | 18 ++++++++++--------
1 file changed, 10 insertions(+), 8 deletions(-)
_______________________________________________
Xen-devel mailing list
Xen-devel@lists.xen.org
https://lists.xen.org/xen-devel
^ permalink raw reply [flat|nested] 6+ messages in thread
* [Qemu-devel] [PULL 1/1] xen: use native disk xenbus protocol if possible
2016-09-05 19:02 ` Stefano Stabellini
@ 2016-09-05 19:03 ` Stefano Stabellini
-1 siblings, 0 replies; 6+ messages in thread
From: Stefano Stabellini @ 2016-09-05 19:03 UTC (permalink / raw)
To: peter.maydell; +Cc: sstabellini, qemu-devel, xen-devel, Juergen Gross
From: Juergen Gross <jgross@suse.com>
The qdisk implementation is using the native xenbus protocol only in
case of no protocol specified at all. As using the explicit 32- or
64-bit protocol is slower than the native one due to copying requests
not by memcpy but element for element, this is not optimal.
Correct this by using the native protocol in case word sizes of
frontend and backend match.
Signed-off-by: Juergen Gross <jgross@suse.com>
Reviewed-by: Anthony PERARD <anthony.perard@citrix.com>
Signed-off-by: Stefano Stabellini <sstabellini@kernel.org>
---
hw/block/xen_disk.c | 18 ++++++++++--------
1 file changed, 10 insertions(+), 8 deletions(-)
diff --git a/hw/block/xen_disk.c b/hw/block/xen_disk.c
index 3b8ad33..3428689 100644
--- a/hw/block/xen_disk.c
+++ b/hw/block/xen_disk.c
@@ -976,14 +976,16 @@ static int blk_connect(struct XenDevice *xendev)
blkdev->feature_persistent = !!pers;
}
- blkdev->protocol = BLKIF_PROTOCOL_NATIVE;
- if (blkdev->xendev.protocol) {
- if (strcmp(blkdev->xendev.protocol, XEN_IO_PROTO_ABI_X86_32) == 0) {
- blkdev->protocol = BLKIF_PROTOCOL_X86_32;
- }
- if (strcmp(blkdev->xendev.protocol, XEN_IO_PROTO_ABI_X86_64) == 0) {
- blkdev->protocol = BLKIF_PROTOCOL_X86_64;
- }
+ if (!blkdev->xendev.protocol) {
+ blkdev->protocol = BLKIF_PROTOCOL_NATIVE;
+ } else if (strcmp(blkdev->xendev.protocol, XEN_IO_PROTO_ABI_NATIVE) == 0) {
+ blkdev->protocol = BLKIF_PROTOCOL_NATIVE;
+ } else if (strcmp(blkdev->xendev.protocol, XEN_IO_PROTO_ABI_X86_32) == 0) {
+ blkdev->protocol = BLKIF_PROTOCOL_X86_32;
+ } else if (strcmp(blkdev->xendev.protocol, XEN_IO_PROTO_ABI_X86_64) == 0) {
+ blkdev->protocol = BLKIF_PROTOCOL_X86_64;
+ } else {
+ blkdev->protocol = BLKIF_PROTOCOL_NATIVE;
}
blkdev->sring = xengnttab_map_grant_ref(blkdev->xendev.gnttabdev,
--
1.9.1
^ permalink raw reply related [flat|nested] 6+ messages in thread
* [PULL 1/1] xen: use native disk xenbus protocol if possible
@ 2016-09-05 19:03 ` Stefano Stabellini
0 siblings, 0 replies; 6+ messages in thread
From: Stefano Stabellini @ 2016-09-05 19:03 UTC (permalink / raw)
To: peter.maydell; +Cc: Juergen Gross, xen-devel, sstabellini, qemu-devel
From: Juergen Gross <jgross@suse.com>
The qdisk implementation is using the native xenbus protocol only in
case of no protocol specified at all. As using the explicit 32- or
64-bit protocol is slower than the native one due to copying requests
not by memcpy but element for element, this is not optimal.
Correct this by using the native protocol in case word sizes of
frontend and backend match.
Signed-off-by: Juergen Gross <jgross@suse.com>
Reviewed-by: Anthony PERARD <anthony.perard@citrix.com>
Signed-off-by: Stefano Stabellini <sstabellini@kernel.org>
---
hw/block/xen_disk.c | 18 ++++++++++--------
1 file changed, 10 insertions(+), 8 deletions(-)
diff --git a/hw/block/xen_disk.c b/hw/block/xen_disk.c
index 3b8ad33..3428689 100644
--- a/hw/block/xen_disk.c
+++ b/hw/block/xen_disk.c
@@ -976,14 +976,16 @@ static int blk_connect(struct XenDevice *xendev)
blkdev->feature_persistent = !!pers;
}
- blkdev->protocol = BLKIF_PROTOCOL_NATIVE;
- if (blkdev->xendev.protocol) {
- if (strcmp(blkdev->xendev.protocol, XEN_IO_PROTO_ABI_X86_32) == 0) {
- blkdev->protocol = BLKIF_PROTOCOL_X86_32;
- }
- if (strcmp(blkdev->xendev.protocol, XEN_IO_PROTO_ABI_X86_64) == 0) {
- blkdev->protocol = BLKIF_PROTOCOL_X86_64;
- }
+ if (!blkdev->xendev.protocol) {
+ blkdev->protocol = BLKIF_PROTOCOL_NATIVE;
+ } else if (strcmp(blkdev->xendev.protocol, XEN_IO_PROTO_ABI_NATIVE) == 0) {
+ blkdev->protocol = BLKIF_PROTOCOL_NATIVE;
+ } else if (strcmp(blkdev->xendev.protocol, XEN_IO_PROTO_ABI_X86_32) == 0) {
+ blkdev->protocol = BLKIF_PROTOCOL_X86_32;
+ } else if (strcmp(blkdev->xendev.protocol, XEN_IO_PROTO_ABI_X86_64) == 0) {
+ blkdev->protocol = BLKIF_PROTOCOL_X86_64;
+ } else {
+ blkdev->protocol = BLKIF_PROTOCOL_NATIVE;
}
blkdev->sring = xengnttab_map_grant_ref(blkdev->xendev.gnttabdev,
--
1.9.1
_______________________________________________
Xen-devel mailing list
Xen-devel@lists.xen.org
https://lists.xen.org/xen-devel
^ permalink raw reply related [flat|nested] 6+ messages in thread
* Re: [Qemu-devel] [PULL 0/1] xen-20160905
2016-09-05 19:02 ` Stefano Stabellini
(?)
(?)
@ 2016-09-06 11:41 ` Peter Maydell
-1 siblings, 0 replies; 6+ messages in thread
From: Peter Maydell @ 2016-09-06 11:41 UTC (permalink / raw)
To: Stefano Stabellini; +Cc: QEMU Developers, xen-devel
On 5 September 2016 at 20:02, Stefano Stabellini <sstabellini@kernel.org> wrote:
> The following changes since commit 12d2c4184c5ab60be3428b2bdea5ae66e8d5d960:
>
> Update version for v2.7.0-rc5 release (2016-08-30 20:39:45 +0100)
>
> are available in the git repository at:
>
> git://xenbits.xen.org/people/sstabellini/qemu-dm.git tags/xen-20160905
>
> for you to fetch changes up to 4ada797b05a52ac824a710c67216b37739026a64:
>
> xen: use native disk xenbus protocol if possible (2016-08-30 15:01:01 -0700)
>
> ----------------------------------------------------------------
> Xen 2016/09/05
>
> ----------------------------------------------------------------
> Juergen Gross (1):
> xen: use native disk xenbus protocol if possible
Applied, thanks.
-- PMM
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: [PULL 0/1] xen-20160905
2016-09-05 19:02 ` Stefano Stabellini
` (2 preceding siblings ...)
(?)
@ 2016-09-06 11:41 ` Peter Maydell
-1 siblings, 0 replies; 6+ messages in thread
From: Peter Maydell @ 2016-09-06 11:41 UTC (permalink / raw)
To: Stefano Stabellini; +Cc: xen-devel, QEMU Developers
On 5 September 2016 at 20:02, Stefano Stabellini <sstabellini@kernel.org> wrote:
> The following changes since commit 12d2c4184c5ab60be3428b2bdea5ae66e8d5d960:
>
> Update version for v2.7.0-rc5 release (2016-08-30 20:39:45 +0100)
>
> are available in the git repository at:
>
> git://xenbits.xen.org/people/sstabellini/qemu-dm.git tags/xen-20160905
>
> for you to fetch changes up to 4ada797b05a52ac824a710c67216b37739026a64:
>
> xen: use native disk xenbus protocol if possible (2016-08-30 15:01:01 -0700)
>
> ----------------------------------------------------------------
> Xen 2016/09/05
>
> ----------------------------------------------------------------
> Juergen Gross (1):
> xen: use native disk xenbus protocol if possible
Applied, thanks.
-- PMM
_______________________________________________
Xen-devel mailing list
Xen-devel@lists.xen.org
https://lists.xen.org/xen-devel
^ permalink raw reply [flat|nested] 6+ messages in thread
end of thread, other threads:[~2016-09-06 11:41 UTC | newest]
Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2016-09-05 19:02 [Qemu-devel] [PULL 0/1] xen-20160905 Stefano Stabellini
2016-09-05 19:02 ` Stefano Stabellini
2016-09-05 19:03 ` [Qemu-devel] [PULL 1/1] xen: use native disk xenbus protocol if possible Stefano Stabellini
2016-09-05 19:03 ` Stefano Stabellini
2016-09-06 11:41 ` [Qemu-devel] [PULL 0/1] xen-20160905 Peter Maydell
2016-09-06 11:41 ` Peter Maydell
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.