Merge tag 'pci-v4.18-fixes-5' of git://git.kernel.org/pub/scm/linux/kernel/git/helgaas/pci
Pull PCI fixes from Bjorn Helgaas: - Fix integer overflow in new mobiveil driver (Dan Carpenter) - Fix race during NVMe removal/rescan (Hari Vyas) * tag 'pci-v4.18-fixes-5' of git://git.kernel.org/pub/scm/linux/kernel/git/helgaas/pci: PCI: Fix is_added/is_busmaster race condition PCI: mobiveil: Avoid integer overflow in IB_WIN_SIZE
This commit is contained in:
@@ -46,6 +46,7 @@
|
||||
|
||||
#include "powernv.h"
|
||||
#include "pci.h"
|
||||
#include "../../../../drivers/pci/pci.h"
|
||||
|
||||
#define PNV_IODA1_M64_NUM 16 /* Number of M64 BARs */
|
||||
#define PNV_IODA1_M64_SEGS 8 /* Segments per M64 BAR */
|
||||
@@ -3138,7 +3139,7 @@ static void pnv_pci_ioda_fixup_iov_resources(struct pci_dev *pdev)
|
||||
struct pci_dn *pdn;
|
||||
int mul, total_vfs;
|
||||
|
||||
if (!pdev->is_physfn || pdev->is_added)
|
||||
if (!pdev->is_physfn || pci_dev_is_added(pdev))
|
||||
return;
|
||||
|
||||
pdn = pci_get_pdn(pdev);
|
||||
|
@@ -71,6 +71,7 @@
|
||||
#include <asm/security_features.h>
|
||||
|
||||
#include "pseries.h"
|
||||
#include "../../../../drivers/pci/pci.h"
|
||||
|
||||
int CMO_PrPSP = -1;
|
||||
int CMO_SecPSP = -1;
|
||||
@@ -664,7 +665,7 @@ static void pseries_pci_fixup_iov_resources(struct pci_dev *pdev)
|
||||
const int *indexes;
|
||||
struct device_node *dn = pci_device_to_OF_node(pdev);
|
||||
|
||||
if (!pdev->is_physfn || pdev->is_added)
|
||||
if (!pdev->is_physfn || pci_dev_is_added(pdev))
|
||||
return;
|
||||
/*Firmware must support open sriov otherwise dont configure*/
|
||||
indexes = of_get_property(dn, "ibm,open-sriov-vf-bar-info", NULL);
|
||||
|
Reference in New Issue
Block a user