Changeset View
Changeset View
Standalone View
Standalone View
sys/arm64/arm64/gic_v3_its.c
Show First 20 Lines • Show All 1,469 Lines • ▼ Show 20 Lines | its_get_devid_thunder(device_t pci_dev) | ||||
int pem; | int pem; | ||||
uint32_t bus; | uint32_t bus; | ||||
bus = pci_get_bus(pci_dev); | bus = pci_get_bus(pci_dev); | ||||
bsf = PCI_RID(pci_get_bus(pci_dev), pci_get_slot(pci_dev), | bsf = PCI_RID(pci_get_bus(pci_dev), pci_get_slot(pci_dev), | ||||
pci_get_function(pci_dev)); | pci_get_function(pci_dev)); | ||||
/* ECAM is on bus=0 */ | /* ECAM is on bus=0...143 */ | ||||
if (bus == 0) { | if (bus < 144) { | ||||
andrew: What is magic about 143? | |||||
emasteUnsubmitted Not Done Inline ActionsIt should be a #defined constant emaste: It should be a `#define`d constant | |||||
return ((pci_get_domain(pci_dev) << PCI_RID_DOMAIN_SHIFT) | | return ((pci_get_domain(pci_dev) << PCI_RID_DOMAIN_SHIFT) | | ||||
bsf); | bsf); | ||||
/* PEM otherwise */ | /* PEM otherwise */ | ||||
} else { | } else { | ||||
/* PEM (PCIe MAC/root complex) number is equal to domain */ | /* PEM (PCIe MAC/root complex) number is equal to domain */ | ||||
pem = pci_get_domain(pci_dev); | pem = pci_get_domain(pci_dev); | ||||
/* | /* | ||||
▲ Show 20 Lines • Show All 199 Lines • Show Last 20 Lines |
What is magic about 143?