WARNING - OLD ARCHIVES

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/
   
 
 
Xen 
 
Home Products Support Community News
 
   
 

xen-devel

RE: [Xen-devel] [PATCH] Improve the current FLR logic

To: "Yosuke Iwamatsu" <y-iwamatsu@xxxxxxxxxxxxx>
Subject: RE: [Xen-devel] [PATCH] Improve the current FLR logic
From: "Cui, Dexuan" <dexuan.cui@xxxxxxxxx>
Date: Thu, 17 Jul 2008 18:21:53 +0800
Cc: xen-devel@xxxxxxxxxxxxxxxxxxx, Keir Fraser <keir.fraser@xxxxxxxxxxxxx>
Delivery-date: Thu, 17 Jul 2008 03:22:42 -0700
Envelope-to: www-data@xxxxxxxxxxxxxxxxxxx
In-reply-to: <487C2222.5030703@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/mailman/listinfo/xen-devel>, <mailto:xen-devel-request@lists.xensource.com?subject=subscribe>
List-unsubscribe: <http://lists.xensource.com/mailman/listinfo/xen-devel>, <mailto:xen-devel-request@lists.xensource.com?subject=unsubscribe>
References: <FE7BBCFBB500984A9A7922EBC95F516E0169A036@xxxxxxxxxxxxxxxxxxxxxxxxxxxx> <487C2222.5030703@xxxxxxxxxxxxx>
Sender: xen-devel-bounces@xxxxxxxxxxxxxxxxxxx
Thread-index: AcjmMB2gscfmQzh6SAmO2qo6KzOMKQBxGxHw
Thread-topic: [Xen-devel] [PATCH] Improve the current FLR logic
Thanks for your comments! 

For case 2) or 4), I think we might as well force the domain config file 
specifying all the related devices.

xm_pci_list_assignable_devices() does access to sysfs and invoke hypercall 
directly.
With respect to xmlrpc, I'm trying to move most of the function to xend.

I think xm_pci_list_assignable_devices only considers iommu devices. Maybe we 
can extend  it to non-iommu devices in future.

Thanks,
-- Dexuan


-----Original Message-----
From: Yosuke Iwamatsu [mailto:y-iwamatsu@xxxxxxxxxxxxx] 
Sent: 2008年7月15日 12:06
To: Cui, Dexuan
Cc: Keir Fraser; xen-devel@xxxxxxxxxxxxxxxxxxx
Subject: Re: [Xen-devel] [PATCH] Improve the current FLR logic

Hi,

Cui, Dexuan wrote:
> [PATCH3] do_FLR_in_control_panel.patch:  the improved FLR logic in
> Control Panel: 1) If the device is PCIe endpoint and supports PCIe FLR,
> we use that; 2) Else, if the device is PCIe endpoint, and all functions
> on the device are assigned to the same guest, we use the immediate
> parent bus's Secondary Bus Reset to reset all functions of the device
> (here, actually we require all the functions of the device be assigned
> to the same guest); 3) Else, if the device is PCI endpoint and is on a
> host bus (e.g. integrated devices) and if the device supports PCI
> Advanced Capabilities, we use that for FLR; 4) Else, we use the
> Secondary Bus Reset (if the PCI device is behind a PCI/PCI-X bridge,
> then all devices behind the uppermost such PCI/PCI-X bridge above this
> device must be co-assigned)

In case 2) or 4), I think multfunction devices or sibling devices need
not be actually assigned to the same guest, if they are just owned by
pciback and not used by other guests.

> [PATCH4] list_assignable_devices.patch: a command "xm
> pci-list-assignable-devices" which can list all the assignable devices
> in the system. It is useful for end users.

It looks like xm_pci_list_assignable_devices() directly accesses to
sysfs and invokes hypercall without going through xend. Since xm
commands can be executed by a remote server through xmlrpc, most of
this function should be implemented in xend.
Also please note that test_assign_device() excludes the case of
non-iommu device assignment for pv.

Thanks,
-- Yosuke Iwamatsu

_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-devel