mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
synced 2026-05-16 05:31:37 -04:00
Merge branch 'pci/p2pdma'
- Allow wildcards in list of host bridges that support peer-to-peer DMA between hierarchy domains and add all Google SoCs (Jacob Moroni) * pci/p2pdma: PCI/P2PDMA: Add Google SoCs to the P2P DMA host bridge list PCI/P2PDMA: Allow wildcard Device IDs in host bridge list
This commit is contained in:
@@ -530,7 +530,7 @@ static bool cpu_supports_p2pdma(void)
|
||||
|
||||
static const struct pci_p2pdma_whitelist_entry {
|
||||
unsigned short vendor;
|
||||
unsigned short device;
|
||||
int device;
|
||||
enum {
|
||||
REQ_SAME_HOST_BRIDGE = 1 << 0,
|
||||
} flags;
|
||||
@@ -548,6 +548,8 @@ static const struct pci_p2pdma_whitelist_entry {
|
||||
{PCI_VENDOR_ID_INTEL, 0x2033, 0},
|
||||
{PCI_VENDOR_ID_INTEL, 0x2020, 0},
|
||||
{PCI_VENDOR_ID_INTEL, 0x09a2, 0},
|
||||
/* Google SoCs. */
|
||||
{PCI_VENDOR_ID_GOOGLE, PCI_ANY_ID, 0},
|
||||
{}
|
||||
};
|
||||
|
||||
@@ -601,8 +603,12 @@ static bool __host_bridge_whitelist(struct pci_host_bridge *host,
|
||||
device = root->device;
|
||||
|
||||
for (entry = pci_p2pdma_whitelist; entry->vendor; entry++) {
|
||||
if (vendor != entry->vendor || device != entry->device)
|
||||
if (vendor != entry->vendor)
|
||||
continue;
|
||||
|
||||
if (entry->device != PCI_ANY_ID && device != entry->device)
|
||||
continue;
|
||||
|
||||
if (entry->flags & REQ_SAME_HOST_BRIDGE && !same_host_bridge)
|
||||
return false;
|
||||
|
||||
|
||||
@@ -2586,6 +2586,8 @@
|
||||
|
||||
#define PCI_VENDOR_ID_AZWAVE 0x1a3b
|
||||
|
||||
#define PCI_VENDOR_ID_GOOGLE 0x1ae0
|
||||
|
||||
#define PCI_VENDOR_ID_REDHAT_QUMRANET 0x1af4
|
||||
#define PCI_SUBVENDOR_ID_REDHAT_QUMRANET 0x1af4
|
||||
#define PCI_SUBDEVICE_ID_QEMU 0x1100
|
||||
|
||||
Reference in New Issue
Block a user