1
The following changes since commit 834eddf22ec762839b724538c7be1d1d3b2d9d3b:
1
The following changes since commit 768cef2974fb1fa30dd188b043ea737e13fea477:
2
2
3
Merge remote-tracking branch 'remotes/stefanha/tags/block-pull-request' into staging (2018-03-13 10:49:02 +0000)
3
Merge remote-tracking branch 'remotes/ehabkost/tags/x86-next-pull-request' into staging (2018-07-24 10:37:52 +0100)
4
4
5
are available in the git repository at:
5
are available in the Git repository at:
6
6
7
git://github.com/codyprime/qemu-kvm-jtc.git tags/block-pull-request
7
git://github.com/stefanha/qemu.git tags/block-pull-request
8
8
9
for you to fetch changes up to 44acd46f60ce6f16d369cd443e77949deca56a2c:
9
for you to fetch changes up to 042b757cc77c9580b99ef2781cfb0a2d1bf495a6:
10
10
11
block: include original filename when reporting invalid URIs (2018-03-13 08:06:55 -0400)
11
block/file-posix: add bdrv_attach_aio_context callback for host dev and cdrom (2018-07-24 14:27:41 +0100)
12
12
13
----------------------------------------------------------------
13
----------------------------------------------------------------
14
Block patch
14
Pull request
15
16
Regression fix for host block devices with the file-posix driver when aio=native is in use.
17
15
----------------------------------------------------------------
18
----------------------------------------------------------------
16
19
17
Daniel P. Berrangé (1):
20
Nishanth Aravamudan (1):
18
block: include original filename when reporting invalid URIs
21
block/file-posix: add bdrv_attach_aio_context callback for host dev
22
and cdrom
19
23
20
block/gluster.c | 2 +-
24
block/file-posix.c | 3 +++
21
block/sheepdog.c | 2 +-
25
1 file changed, 3 insertions(+)
22
2 files changed, 2 insertions(+), 2 deletions(-)
23
26
24
--
27
--
25
2.13.6
28
2.17.1
26
29
27
30
diff view generated by jsdifflib
1
From: Daniel P. Berrangé <berrange@redhat.com>
1
From: Nishanth Aravamudan <naravamudan@digitalocean.com>
2
2
3
Consider passing a JSON based block driver to "qemu-img commit"
3
In ed6e2161 ("linux-aio: properly bubble up errors from initialzation"),
4
I only added a bdrv_attach_aio_context callback for the bdrv_file
5
driver. There are several other drivers that use the shared
6
aio_plug callback, though, and they will trip the assertion added to
7
aio_get_linux_aio because they did not call aio_setup_linux_aio first.
8
Add the appropriate callback definition to the affected driver
9
definitions.
4
10
5
$ qemu-img commit 'json:{"driver":"qcow2","file":{"driver":"gluster",\
11
Fixes: ed6e2161 ("linux-aio: properly bubble up errors from initialization")
6
"volume":"gv0","path":"sn1.qcow2",
12
Reported-by: Farhan Ali <alifm@linux.ibm.com>
7
"server":[{"type":\
13
Signed-off-by: Nishanth Aravamudan <naravamudan@digitalocean.com>
8
         "tcp","host":"10.73.199.197","port":"24007"}]},}'
14
Reviewed-by: John Snow <jsnow@redhat.com>
15
Message-id: 20180718211256.29774-1-naravamudan@digitalocean.com
16
Cc: Eric Blake <eblake@redhat.com>
17
Cc: Kevin Wolf <kwolf@redhat.com>
18
Cc: John Snow <jsnow@redhat.com>
19
Cc: Max Reitz <mreitz@redhat.com>
20
Cc: Stefan Hajnoczi <stefanha@redhat.com>
21
Cc: Fam Zheng <famz@redhat.com>
22
Cc: Paolo Bonzini <pbonzini@redhat.com>
23
Cc: qemu-block@nongnu.org
24
Cc: qemu-devel@nongnu.org
25
Signed-off-by: Stefan Hajnoczi <stefanha@redhat.com>
26
---
27
block/file-posix.c | 3 +++
28
1 file changed, 3 insertions(+)
9
29
10
Currently it will commit the content and then report an incredibly
30
diff --git a/block/file-posix.c b/block/file-posix.c
11
useless error message when trying to re-open the committed image:
12
13
qemu-img: invalid URI
14
Usage: file=gluster[+transport]://[host[:port]]volume/path[?socket=...][,file.debug=N][,file.logfile=/path/filename.log]
15
16
With this fix we get:
17
18
qemu-img: invalid URI json:{"server.0.host": "10.73.199.197",
19
"driver": "gluster", "path": "luks.qcow2", "server.0.type":
20
"tcp", "server.0.port": "24007", "volume": "gv0"}
21
22
Of course the root cause problem still exists, but now we know
23
what actually needs fixing.
24
25
Signed-off-by: Daniel P. Berrangé <berrange@redhat.com>
26
Reviewed-by: Eric Blake <eblake@redhat.com>
27
Message-id: 20180206105204.14817-1-berrange@redhat.com
28
Signed-off-by: Jeff Cody <jcody@redhat.com>
29
---
30
block/gluster.c | 2 +-
31
block/sheepdog.c | 2 +-
32
2 files changed, 2 insertions(+), 2 deletions(-)
33
34
diff --git a/block/gluster.c b/block/gluster.c
35
index XXXXXXX..XXXXXXX 100644
31
index XXXXXXX..XXXXXXX 100644
36
--- a/block/gluster.c
32
--- a/block/file-posix.c
37
+++ b/block/gluster.c
33
+++ b/block/file-posix.c
38
@@ -XXX,XX +XXX,XX @@ static int qemu_gluster_parse(BlockdevOptionsGluster *gconf,
34
@@ -XXX,XX +XXX,XX @@ static BlockDriver bdrv_host_device = {
39
if (filename) {
35
.bdrv_refresh_limits = raw_refresh_limits,
40
ret = qemu_gluster_parse_uri(gconf, filename);
36
.bdrv_io_plug = raw_aio_plug,
41
if (ret < 0) {
37
.bdrv_io_unplug = raw_aio_unplug,
42
- error_setg(errp, "invalid URI");
38
+ .bdrv_attach_aio_context = raw_aio_attach_aio_context,
43
+ error_setg(errp, "invalid URI %s", filename);
39
44
error_append_hint(errp, "Usage: file=gluster[+transport]://"
40
.bdrv_co_truncate = raw_co_truncate,
45
"[host[:port]]volume/path[?socket=...]"
41
.bdrv_getlength    = raw_getlength,
46
"[,file.debug=N]"
42
@@ -XXX,XX +XXX,XX @@ static BlockDriver bdrv_host_cdrom = {
47
diff --git a/block/sheepdog.c b/block/sheepdog.c
43
.bdrv_refresh_limits = raw_refresh_limits,
48
index XXXXXXX..XXXXXXX 100644
44
.bdrv_io_plug = raw_aio_plug,
49
--- a/block/sheepdog.c
45
.bdrv_io_unplug = raw_aio_unplug,
50
+++ b/block/sheepdog.c
46
+ .bdrv_attach_aio_context = raw_aio_attach_aio_context,
51
@@ -XXX,XX +XXX,XX @@ static void sd_parse_uri(SheepdogConfig *cfg, const char *filename,
47
52
48
.bdrv_co_truncate = raw_co_truncate,
53
cfg->uri = uri = uri_parse(filename);
49
.bdrv_getlength = raw_getlength,
54
if (!uri) {
50
@@ -XXX,XX +XXX,XX @@ static BlockDriver bdrv_host_cdrom = {
55
- error_setg(&err, "invalid URI");
51
.bdrv_refresh_limits = raw_refresh_limits,
56
+ error_setg(&err, "invalid URI '%s'", filename);
52
.bdrv_io_plug = raw_aio_plug,
57
goto out;
53
.bdrv_io_unplug = raw_aio_unplug,
58
}
54
+ .bdrv_attach_aio_context = raw_aio_attach_aio_context,
59
55
56
.bdrv_co_truncate = raw_co_truncate,
57
.bdrv_getlength = raw_getlength,
60
--
58
--
61
2.13.6
59
2.17.1
62
60
63
61
diff view generated by jsdifflib