This is an archived copy of the Xen.org mailing list, which we have preserved to ensure that existing links to archives are not broken. The live archive, which contains the latest emails, can be found at http://lists.xen.org/
Home Products Support Community News


Re: [Xen-devel] [PATCH 0/3][RFC] PV Passthrough PCI Device Hotplug Suppo

To: Yosuke Iwamatsu <y-iwamatsu@xxxxxxxxxxxxx>
Subject: Re: [Xen-devel] [PATCH 0/3][RFC] PV Passthrough PCI Device Hotplug Support
From: Keir Fraser <Keir.Fraser@xxxxxxxxxxxx>
Date: Thu, 21 Feb 2008 13:45:24 +0000
Cc: xen-devel@xxxxxxxxxxxxxxxxxxx
Delivery-date: Thu, 21 Feb 2008 05:46:06 -0800
Envelope-to: www-data@xxxxxxxxxxxxxxxxxx
In-reply-to: <47BD7BD7.4020604@xxxxxxxxxxxxx>
List-help: <mailto:xen-devel-request@lists.xensource.com?subject=help>
List-id: Xen developer discussion <xen-devel.lists.xensource.com>
List-post: <mailto:xen-devel@lists.xensource.com>
List-subscribe: <http://lists.xensource.com/cgi-bin/mailman/listinfo/xen-devel>, <mailto:xen-devel-request@lists.xensource.com?subject=subscribe>
List-unsubscribe: <http://lists.xensource.com/cgi-bin/mailman/listinfo/xen-devel>, <mailto:xen-devel-request@lists.xensource.com?subject=unsubscribe>
Sender: xen-devel-bounces@xxxxxxxxxxxxxxxxxxx
Thread-index: Ach0kAIiQOr9vOCDEdyH3gAX8io7RQ==
Thread-topic: [Xen-devel] [PATCH 0/3][RFC] PV Passthrough PCI Device Hotplug Support
User-agent: Microsoft-Entourage/
On 21/2/08 13:25, "Yosuke Iwamatsu" <y-iwamatsu@xxxxxxxxxxxxx> wrote:

> Keir Fraser wrote:
>> I mean have an extra global node called e.g., reconfigure. Set to 1 when
>> pciback has updated hotplug info, causes pcifront to set reconfigure back to
>> 0 and then re-scan the xenstore directory. Would that work?
> Understood. Perhaps I'll give it a try in that manner.

> dev-#, vdev-# and state-# are all backend nodes.
> Xend writes physical names on dev-# to let pciback know which device
> should be exported (This is the original behaviour).
> Then pciback publishes the corresponding virtul name on vdev-#.
> At the time of detachment, pcifront scans backend nodes and finds
> which device should be removed by seeing vdev-#.
> pcifront doesn't need to know the physical name indeed.

This seems a bit different from how initial probe happens (by reading the
root-%d xenstore nodes). Could we not just watch those in pcifront and
re-parse them for changes?

Your state machine was also quite complicated, perhaps primarily so that
pcifront could handshake when devices are removed. Is this handshake
necessary? (e.g., in particular, is there any equivalent notion for real PCI
hot-unplug?). If not, we can get equivalent hotplug functionality between
HVM and PV without needing a complicated xend->frontend->backend->xend
handshaking ring:
 * xend updates dev-% nodes
 * pciback sees this and updates root-%d nodes
 * pcifront sees this and re-parses root-%d nodes

 -- Keir

Xen-devel mailing list