staticint__pci_enable_msix_range(struct pci_dev*dev,struct msix_entry*entries,int minvec,int maxvec,struct irq_affinity*affd,int flags) 这个函数的作用是,给定的pci设备,以及一些msix表的entry,申请向量号位于一个范围的中断向量。配置设备的MSI-X Capability结构体。 struct msix_entry 代码语言:javascri...
Linux 4.8 replaced it with pci_enable_msix_range. You can fix it like this:#if LINUX_VERSION...
;if(flags&PCI_IRQ_AFFINITY){if(!affd)affd=&msi_default_affd;}else{if(WARN_ON(affd))affd=NULL;}if(flags&PCI_IRQ_MSIX){nvecs=__pci_enable_msix_range(dev,NULL,min_vecs,max_vecs,affd,flags);if(nvecs>0)returnnvecs;}if(flags&PCI_IRQ_MSI){nvecs=__pci_enable_msi_range(dev,mi...
static inline int pci_enable_msix_range(struct pci_dev *dev, struct msix_entry *entries, int minvec, int maxvec) { return -ENOSYS; } #endif #endif #endif #if LINUX_VERSION_CODE < KERNEL_VERSION(3,13,0) #define pci_device_is_present LINUX_BACKPORT(pci_device_is_present) bool pci_...
static int __pci_enable_msix_range(struct pci_dev *dev,...该函数原型如下: int pci_msi_setup_msi_irqs(struct pci_dev *dev, int nvec, int type) 该函数首先获取msi的domain,校验是否为继承的...(我还不明白这里是干啥意思的) 然后就会去调用pci_msi_legacy_setup_msi_irqs函数,去设置msix。....
CONFTEST: pci_enable_msix_range CONFTEST: do_gettimeofday CONFTEST: kernel_read CONFTEST: kernel_write CONFTEST: kthread_create_on_node CONFTEST: of_find_matching_node CONFTEST: dev_is_pci CONFTEST: tegra_get_platform CONFTEST: dma_direct_map_resource ...
pci_iomap_range(dev, bar, offset, length) if (flags & IORESOURCE_IO) // 如果BAR空间实现的是IO空间,将其映射到CPU的IO地址空间 return __pci_ioport_map(dev, start, len); if (flags & IORESOURCE_MEM) // 如果BAR空间实现的内存空间,将其映射到CPU的内存地址空间 ...
u16 aer_cap;/*AER capability offset*/#endifu8 pcie_cap;/*PCIe capability offset*/u8 msi_cap;/*MSI capability offset*/u8 msix_cap;/*MSI-X capability offset*/u8 pcie_mpss:3;/*PCIe Max Payload Size Supported*/u8 rom_base_reg;/*which config register controls the ROM*/u8 pin;/*which ...
msi_set_enabled(pdev->msix.guest_state, enable);if (enable && vfio_pci_enable_msis(kvm, vdev, true)) vfio_dev_err(vdev, "cannot enable MSIX"); @@ -382,7 +402,7 @@ static int vfio_pci_msi_vector_write(struct kvm *kvm, struct vfio_device *vdev, ...
vfio_res->msix_table.bar_index = -1; } }for(i =0; i < (int) vfio_res->nb_maps; i++) {structvfio_region_info *reg =NULL;void*bar_addr; ret= pci_vfio_get_region_info(vfio_dev_fd, , i);if(ret <0) { RTE_LOG(ERR, EAL,"%s cannot get device region info""error %i (...