mirror of
https://github.com/xemu-project/xemu.git
synced 2024-11-30 06:50:57 +00:00
5fb52f6cc8
Emulation of PCIe Data Object Exchange (DOE) PCIE Base Specification r6.0 6.3 Data Object Exchange Supports multiple DOE PCIe Extended Capabilities for a single PCIe device. For each capability, a static array of DOEProtocol should be passed to pcie_doe_init(). The protocols in that array will be registered under the DOE capability structure. For each protocol, vendor ID, type, and corresponding callback function (handle_request()) should be implemented. This callback function represents how the DOE request for corresponding protocol will be handled. pcie_doe_{read/write}_config() must be appended to corresponding PCI device's config_read/write() handler to enable DOE access. In pcie_doe_read_config(), false will be returned if pci_config_read() offset is not within DOE capability range. In pcie_doe_write_config(), the function will have no affect if the address is not within the related DOE PCIE extended capability. Signed-off-by: Huai-Cheng Kuo <hchkuo@avery-design.com.tw> Signed-off-by: Chris Browy <cbrowy@avery-design.com> Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com> Message-Id: <20221014151045.24781-2-Jonathan.Cameron@huawei.com> Reviewed-by: Michael S. Tsirkin <mst@redhat.com> Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
22 lines
674 B
Meson
22 lines
674 B
Meson
pci_ss = ss.source_set()
|
|
pci_ss.add(files(
|
|
'msi.c',
|
|
'msix.c',
|
|
'pci.c',
|
|
'pci_bridge.c',
|
|
'pci_host.c',
|
|
'pcie_sriov.c',
|
|
'shpc.c',
|
|
'slotid_cap.c'
|
|
))
|
|
# The functions in these modules can be used by devices too. Since we
|
|
# allow plugging PCIe devices into PCI buses, include them even if
|
|
# CONFIG_PCI_EXPRESS=n.
|
|
pci_ss.add(files('pcie.c', 'pcie_aer.c'))
|
|
pci_ss.add(files('pcie_doe.c'))
|
|
softmmu_ss.add(when: 'CONFIG_PCI_EXPRESS', if_true: files('pcie_port.c', 'pcie_host.c'))
|
|
softmmu_ss.add_all(when: 'CONFIG_PCI', if_true: pci_ss)
|
|
|
|
softmmu_ss.add(when: 'CONFIG_PCI', if_false: files('pci-stub.c'))
|
|
softmmu_ss.add(when: 'CONFIG_ALL', if_true: files('pci-stub.c'))
|