From: Laurent Vivier <lvivier@redhat.com>
To: qemu-ppc@nongnu.org, qemu-devel@nongnu.org,
Michael Roth <mdroth@linux.vnet.ibm.com>
Cc: dgibson@redhat.com, Alexander Graf <agraf@suse.de>
Subject: Re: [Qemu-devel] [Qemu-ppc] [PATCH RFC] pseries: define coldplugged devices as "configured"
Date: Fri, 14 Aug 2015 14:33:47 +0200 [thread overview]
Message-ID: <55CDE02B.6010409@redhat.com> (raw)
In-Reply-To: <1439470382-17540-1-git-send-email-lvivier@redhat.com>
I'd like to know if it is the good way to fix the problem: are there
more comments on this patch ? People from IBM ?
Laurent
On 13/08/2015 14:53, Laurent Vivier wrote:
> When a device is hotplugged, attach() sets "configured" to
> false, waiting an action from the OS to configure it and then
> to call ibm,configure-connector. On ibm,configure-connector,
> the hypervisor sets "configured" to true.
>
> In case of coldplugged device, attach() sets "configured" to
> false, but firmware and OS never call the ibm,configure-connector
> in this case, so it remains set to false.
>
> It could be harmless, but when we unplug a device, hypervisor
> waits the device becomes configured because for it, a not configured
> device is a device being configured, so it waits the end of configuration
> to unplug it... and it never happens, so it is never unplugged.
>
> This patch set by default coldplugged device to "configured=true",
> hotplugged device to "configured=false".
>
> Signed-off-by: Laurent Vivier <lvivier@redhat.com>
> ---
> hw/ppc/spapr_drc.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/hw/ppc/spapr_drc.c b/hw/ppc/spapr_drc.c
> index ee87432..e86babf 100644
> --- a/hw/ppc/spapr_drc.c
> +++ b/hw/ppc/spapr_drc.c
> @@ -310,7 +310,7 @@ static void attach(sPAPRDRConnector *drc, DeviceState *d, void *fdt,
> drc->dev = d;
> drc->fdt = fdt;
> drc->fdt_start_offset = fdt_start_offset;
> - drc->configured = false;
> + drc->configured = coldplug;
>
> object_property_add_link(OBJECT(drc), "device",
> object_get_typename(OBJECT(drc->dev)),
>
next prev parent reply other threads:[~2015-08-14 12:33 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-08-13 12:53 [Qemu-devel] [PATCH RFC] pseries: define coldplugged devices as "configured" Laurent Vivier
2015-08-14 5:20 ` Bharata B Rao
2015-08-14 7:16 ` Laurent Vivier
2015-08-14 7:44 ` Bharata B Rao
2015-08-14 7:46 ` Laurent Vivier
2015-08-23 19:08 ` Michael Roth
2015-08-26 13:04 ` Laurent Vivier
2015-08-14 12:33 ` Laurent Vivier [this message]
2015-09-01 5:00 ` [Qemu-devel] [Qemu-ppc] " David Gibson
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=55CDE02B.6010409@redhat.com \
--to=lvivier@redhat.com \
--cc=agraf@suse.de \
--cc=dgibson@redhat.com \
--cc=mdroth@linux.vnet.ibm.com \
--cc=qemu-devel@nongnu.org \
--cc=qemu-ppc@nongnu.org \
/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 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.