mirror of
https://github.com/xen-project/xen.git
synced 2026-10-28 10:11:27 +01:00
1) If the device is PCIe endpoint and supports PCIe FLR, we use that; else 2) 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); else 3) 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; else 4) 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). Signed-off-by: Dexuan Cui <dexuan.cui@intel.com>
The file test.py here is from the Zope project, and is Copyright (c) 2001, 2002 Zope Corporation and Contributors. This file is released under the Zope Public License, version 2.0, a copy of which is in the file ZPL-2.0.