From: Cornelia Huck <cohuck@redhat.com>
To: peter.maydell@linaro.org
Cc: qemu-devel@nongnu.org, borntraeger@de.ibm.com, agraf@suse.de,
rth@twiddle.net, thuth@redhat.com, david@redhat.com,
Dong Jia Shi <bjsdjshi@linux.vnet.ibm.com>,
Alex Williamson <alex.williamson@redhat.com>,
Cornelia Huck <cohuck@redhat.com>
Subject: [Qemu-devel] [PULL for-2.10 02/14] vfio/ccw: fix initialization of the Object DeviceState pointer in the common base-device
Date: Tue, 25 Jul 2017 11:40:14 +0200 [thread overview]
Message-ID: <20170725094026.5376-3-cohuck@redhat.com> (raw)
In-Reply-To: <20170725094026.5376-1-cohuck@redhat.com>
From: Dong Jia Shi <bjsdjshi@linux.vnet.ibm.com>
Commit 7da624e2 ("vfio: Test realized when using VFIOGroup.device_list
iterator") introduced a pointer to the Object DeviceState in the VFIO
common base-device and skipped non-realized devices as we iterate
VFIOGroup.device_list. While it missed to initialize the pointer for
the vfio-ccw case. Let's fix it.
Fixes: 7da624e2 ("vfio: Test realized when using VFIOGroup.device_list
iterator")
Cc: Alex Williamson <alex.williamson@redhat.com>
Reviewed-by: Halil Pasic <pasic@linux.vnet.ibm.com>
Signed-off-by: Dong Jia Shi <bjsdjshi@linux.vnet.ibm.com>
Reviewed-by: Alex Williamson <alex.williamson@redhat.com>
Message-Id: <20170718014926.44781-3-bjsdjshi@linux.vnet.ibm.com>
Signed-off-by: Cornelia Huck <cohuck@redhat.com>
---
hw/vfio/ccw.c | 1 +
1 file changed, 1 insertion(+)
diff --git a/hw/vfio/ccw.c b/hw/vfio/ccw.c
index 8d97b53e77..a8baadf57a 100644
--- a/hw/vfio/ccw.c
+++ b/hw/vfio/ccw.c
@@ -338,6 +338,7 @@ static void vfio_ccw_realize(DeviceState *dev, Error **errp)
vcdev->vdev.type = VFIO_DEVICE_TYPE_CCW;
vcdev->vdev.name = g_strdup_printf("%x.%x.%04x", cdev->hostid.cssid,
cdev->hostid.ssid, cdev->hostid.devid);
+ vcdev->vdev.dev = dev;
QLIST_FOREACH(vbasedev, &group->device_list, next) {
if (strcmp(vbasedev->name, vcdev->vdev.name) == 0) {
error_setg(&err, "vfio: subchannel %s has already been attached",
--
2.13.3
next prev parent reply other threads:[~2017-07-25 9:40 UTC|newest]
Thread overview: 19+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-07-25 9:40 [Qemu-devel] [PULL for-2.10 00/14] A set of s390x patches Cornelia Huck
2017-07-25 9:40 ` [Qemu-devel] [PULL for-2.10 01/14] vfio/ccw: allocate irq info with the right size Cornelia Huck
2017-07-25 9:40 ` Cornelia Huck [this message]
2017-07-25 9:40 ` [Qemu-devel] [PULL for-2.10 03/14] s390/cpumodel: remove KSS from the default model of z14 Cornelia Huck
2017-07-25 9:40 ` [Qemu-devel] [PULL for-2.10 04/14] target/s390x: drop BE_BIT() Cornelia Huck
2017-07-25 9:40 ` [Qemu-devel] [PULL for-2.10 05/14] target/s390x: indicate query subfunction in s390_fill_feat_block Cornelia Huck
2017-07-25 9:40 ` [Qemu-devel] [PULL for-2.10 06/14] target/s390x: introduce (test|set)_be_bit Cornelia Huck
2017-07-25 9:40 ` [Qemu-devel] [PULL for-2.10 07/14] s390x/kvm: better comment regarding zPCI feature availability Cornelia Huck
2017-07-25 9:40 ` [Qemu-devel] [PULL for-2.10 08/14] target/s390x: improve baselining if certain base features are missing Cornelia Huck
2017-07-25 9:40 ` [Qemu-devel] [PULL for-2.10 09/14] target/s390x: Move s390_cpu_dump_state() to helper.c Cornelia Huck
2017-07-25 9:40 ` [Qemu-devel] [PULL for-2.10 10/14] target/s390x: Move diag helpers to a separate file Cornelia Huck
2017-07-25 9:40 ` [Qemu-devel] [PULL for-2.10 11/14] target/s390x: Rework program_interrupt() and related functions Cornelia Huck
2017-07-25 9:40 ` [Qemu-devel] [PULL for-2.10 12/14] target/s390x: Move exception-related functions to a new excp_helper.c file Cornelia Huck
2017-07-25 9:40 ` [Qemu-devel] [PULL for-2.10 13/14] target/s390x: Add remaining switches to compile with --disable-tcg Cornelia Huck
2017-07-25 9:40 ` [Qemu-devel] [PULL for-2.10 14/14] s390x/css: fix ilen in IO instruction handlers Cornelia Huck
2017-07-25 9:58 ` [Qemu-devel] [PULL for-2.10 00/14] A set of s390x patches no-reply
2017-07-25 10:19 ` Cornelia Huck
2017-07-28 4:39 ` Fam Zheng
2017-07-25 12:02 ` Peter Maydell
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20170725094026.5376-3-cohuck@redhat.com \
--to=cohuck@redhat.com \
--cc=agraf@suse.de \
--cc=alex.williamson@redhat.com \
--cc=bjsdjshi@linux.vnet.ibm.com \
--cc=borntraeger@de.ibm.com \
--cc=david@redhat.com \
--cc=peter.maydell@linaro.org \
--cc=qemu-devel@nongnu.org \
--cc=rth@twiddle.net \
--cc=thuth@redhat.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).