1
The following changes since commit 64175afc695c0672876fbbfc31b299c86d562cb4:
1
The following changes since commit b38df311c174c98ef8cce7dec9f46603b083018e:
2
2
3
arm_gicv3: Fix ICC_BPR1 reset value when EL3 not implemented (2017-06-07 17:21:44 +0100)
3
Merge remote-tracking branch 'remotes/dgibson/tags/ppc-for-2.10-20170809' into staging (2017-08-10 11:12:36 +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 56faeb9bb6872b3f926b3b3e0452a70beea10af2:
9
for you to fetch changes up to 17d0bc01bfcce0ad4fb5105d4502595224569ff0:
10
10
11
block/gluster.c: Handle qdict_array_entries() failure (2017-06-09 08:41:29 -0400)
11
virtio-blk: handle blk_getlength() errors (2017-08-10 14:33:43 +0100)
12
12
13
----------------------------------------------------------------
13
----------------------------------------------------------------
14
Gluster patch
14
15
----------------------------------------------------------------
15
----------------------------------------------------------------
16
16
17
Peter Maydell (1):
17
Kevin Wolf (1):
18
block/gluster.c: Handle qdict_array_entries() failure
18
IDE: test flush on empty CDROM
19
19
20
block/gluster.c | 3 +--
20
Stefan Hajnoczi (2):
21
1 file changed, 1 insertion(+), 2 deletions(-)
21
IDE: Do not flush empty CDROM drives
22
virtio-blk: handle blk_getlength() errors
23
24
hw/block/virtio-blk.c | 4 +++-
25
hw/ide/core.c | 10 +++++++++-
26
tests/ide-test.c | 19 +++++++++++++++++++
27
3 files changed, 31 insertions(+), 2 deletions(-)
22
28
23
--
29
--
24
2.9.3
30
2.13.4
25
31
26
32
diff view generated by jsdifflib
New patch
1
The block backend changed in a way that flushing empty CDROM drives now
2
crashes. Amend IDE to avoid doing so until the root problem can be
3
addressed for 2.11.
1
4
5
Original patch by John Snow <jsnow@redhat.com>.
6
7
Reported-by: Kieron Shorrock <kshorrock@paloaltonetworks.com>
8
Signed-off-by: Stefan Hajnoczi <stefanha@redhat.com>
9
Reviewed-by: Eric Blake <eblake@redhat.com>
10
Message-id: 20170809160212.29976-2-stefanha@redhat.com
11
Signed-off-by: Stefan Hajnoczi <stefanha@redhat.com>
12
---
13
hw/ide/core.c | 10 +++++++++-
14
1 file changed, 9 insertions(+), 1 deletion(-)
15
16
diff --git a/hw/ide/core.c b/hw/ide/core.c
17
index XXXXXXX..XXXXXXX 100644
18
--- a/hw/ide/core.c
19
+++ b/hw/ide/core.c
20
@@ -XXX,XX +XXX,XX @@ static void ide_flush_cache(IDEState *s)
21
s->status |= BUSY_STAT;
22
ide_set_retry(s);
23
block_acct_start(blk_get_stats(s->blk), &s->acct, 0, BLOCK_ACCT_FLUSH);
24
- s->pio_aiocb = blk_aio_flush(s->blk, ide_flush_cb, s);
25
+
26
+ if (blk_bs(s->blk)) {
27
+ s->pio_aiocb = blk_aio_flush(s->blk, ide_flush_cb, s);
28
+ } else {
29
+ /* XXX blk_aio_flush() crashes when blk_bs(blk) is NULL, remove this
30
+ * temporary workaround when blk_aio_*() functions handle NULL blk_bs.
31
+ */
32
+ ide_flush_cb(s, 0);
33
+ }
34
}
35
36
static void ide_cfata_metadata_inquiry(IDEState *s)
37
--
38
2.13.4
39
40
diff view generated by jsdifflib
New patch
1
From: Kevin Wolf <kwolf@redhat.com>
1
2
3
Signed-off-by: Kevin Wolf <kwolf@redhat.com>
4
Signed-off-by: John Snow <jsnow@redhat.com>
5
Reviewed-by: Eric Blake <eblake@redhat.com>
6
Signed-off-by: Stefan Hajnoczi <stefanha@redhat.com>
7
Message-id: 20170809160212.29976-3-stefanha@redhat.com
8
Signed-off-by: Stefan Hajnoczi <stefanha@redhat.com>
9
---
10
tests/ide-test.c | 19 +++++++++++++++++++
11
1 file changed, 19 insertions(+)
12
13
diff --git a/tests/ide-test.c b/tests/ide-test.c
14
index XXXXXXX..XXXXXXX 100644
15
--- a/tests/ide-test.c
16
+++ b/tests/ide-test.c
17
@@ -XXX,XX +XXX,XX @@ static void test_flush_nodev(void)
18
ide_test_quit();
19
}
20
21
+static void test_flush_empty_drive(void)
22
+{
23
+ QPCIDevice *dev;
24
+ QPCIBar bmdma_bar, ide_bar;
25
+
26
+ ide_test_start("-device ide-cd,bus=ide.0");
27
+ dev = get_pci_device(&bmdma_bar, &ide_bar);
28
+
29
+ /* FLUSH CACHE command on device 0 */
30
+ qpci_io_writeb(dev, ide_bar, reg_device, 0);
31
+ qpci_io_writeb(dev, ide_bar, reg_command, CMD_FLUSH_CACHE);
32
+
33
+ /* Just testing that qemu doesn't crash... */
34
+
35
+ free_pci_device(dev);
36
+ ide_test_quit();
37
+}
38
+
39
static void test_pci_retry_flush(void)
40
{
41
test_retry_flush("pc");
42
@@ -XXX,XX +XXX,XX @@ int main(int argc, char **argv)
43
44
qtest_add_func("/ide/flush", test_flush);
45
qtest_add_func("/ide/flush/nodev", test_flush_nodev);
46
+ qtest_add_func("/ide/flush/empty_drive", test_flush_empty_drive);
47
qtest_add_func("/ide/flush/retry_pci", test_pci_retry_flush);
48
qtest_add_func("/ide/flush/retry_isa", test_isa_retry_flush);
49
50
--
51
2.13.4
52
53
diff view generated by jsdifflib
1
From: Peter Maydell <peter.maydell@linaro.org>
1
If blk_getlength() fails in virtio_blk_update_config() consider the disk
2
image length to be 0 bytes.
2
3
3
In qemu_gluster_parse_json(), the call to qdict_array_entries()
4
Signed-off-by: Stefan Hajnoczi <stefanha@redhat.com>
4
could return a negative error code, which we were ignoring
5
Reviewed-by: Fam Zheng <famz@redhat.com>
5
because we assigned the result to an unsigned variable.
6
Message-id: 20170808122251.29815-1-stefanha@redhat.com
6
Fix this by using the 'int' type instead, which matches the
7
Signed-off-by: Stefan Hajnoczi <stefanha@redhat.com>
7
return type of qdict_array_entries() and also the type
8
---
8
we use for the loop enumeration variable 'i'.
9
hw/block/virtio-blk.c | 4 +++-
10
1 file changed, 3 insertions(+), 1 deletion(-)
9
11
10
(Spotted by Coverity, CID 1360960.)
12
diff --git a/hw/block/virtio-blk.c b/hw/block/virtio-blk.c
11
12
Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
13
Reviewed-by: Eric Blake <eblake@redhat.com>
14
Reviewed-by: Jeff Cody <jcody@redhat.com>
15
Message-id: 1496682098-1540-1-git-send-email-peter.maydell@linaro.org
16
Signed-off-by: Jeff Cody <jcody@redhat.com>
17
---
18
block/gluster.c | 3 +--
19
1 file changed, 1 insertion(+), 2 deletions(-)
20
21
diff --git a/block/gluster.c b/block/gluster.c
22
index XXXXXXX..XXXXXXX 100644
13
index XXXXXXX..XXXXXXX 100644
23
--- a/block/gluster.c
14
--- a/hw/block/virtio-blk.c
24
+++ b/block/gluster.c
15
+++ b/hw/block/virtio-blk.c
25
@@ -XXX,XX +XXX,XX @@ static int qemu_gluster_parse_json(BlockdevOptionsGluster *gconf,
16
@@ -XXX,XX +XXX,XX @@ static void virtio_blk_update_config(VirtIODevice *vdev, uint8_t *config)
26
Error *local_err = NULL;
17
BlockConf *conf = &s->conf.conf;
27
char *str = NULL;
18
struct virtio_blk_config blkcfg;
28
const char *ptr;
19
uint64_t capacity;
29
- size_t num_servers;
20
+ int64_t length;
30
- int i, type;
21
int blk_size = conf->logical_block_size;
31
+ int i, type, num_servers;
22
32
23
blk_get_geometry(s->blk, &capacity);
33
/* create opts info from runtime_json_opts list */
24
@@ -XXX,XX +XXX,XX @@ static void virtio_blk_update_config(VirtIODevice *vdev, uint8_t *config)
34
opts = qemu_opts_create(&runtime_json_opts, NULL, 0, &error_abort);
25
* divided by 512 - instead it is the amount of blk_size blocks
26
* per track (cylinder).
27
*/
28
- if (blk_getlength(s->blk) / conf->heads / conf->secs % blk_size) {
29
+ length = blk_getlength(s->blk);
30
+ if (length > 0 && length / conf->heads / conf->secs % blk_size) {
31
blkcfg.geometry.sectors = conf->secs & ~s->sector_mask;
32
} else {
33
blkcfg.geometry.sectors = conf->secs;
35
--
34
--
36
2.9.3
35
2.13.4
37
36
38
37
diff view generated by jsdifflib