diff options
author | Yongji Xie <elohimes@gmail.com> | 2017-04-10 19:58:13 +0800 |
---|---|---|
committer | Bjorn Helgaas <bhelgaas@google.com> | 2017-04-19 12:51:26 -0500 |
commit | 382746376993cfa6d6c4e546c67384201c0f3a82 (patch) | |
tree | f51dc2c2c9130559dd400eeed5c08304c0c371dc /arch/powerpc/include/asm/machdep.h | |
parent | 0a701aa6378496ea54fb065c68b41d918e372e94 (diff) | |
download | op-kernel-dev-382746376993cfa6d6c4e546c67384201c0f3a82.zip op-kernel-dev-382746376993cfa6d6c4e546c67384201c0f3a82.tar.gz |
powerpc/powernv: Override pcibios_default_alignment() to force PCI devices to be page aligned
Override pcibios_default_alignment() to set default alignment to PAGE_SIZE
for all PCI devices on PowerNV platform. Thus sub-page BARs would not
share a page and could be mapped into guest when VFIO passthrough them.
Signed-off-by: Yongji Xie <elohimes@gmail.com>
Signed-off-by: Bjorn Helgaas <bhelgaas@google.com>
Diffstat (limited to 'arch/powerpc/include/asm/machdep.h')
-rw-r--r-- | arch/powerpc/include/asm/machdep.h | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/arch/powerpc/include/asm/machdep.h b/arch/powerpc/include/asm/machdep.h index 5011b69..f90b22c 100644 --- a/arch/powerpc/include/asm/machdep.h +++ b/arch/powerpc/include/asm/machdep.h @@ -173,6 +173,8 @@ struct machdep_calls { /* Called after scan and before resource survey */ void (*pcibios_fixup_phb)(struct pci_controller *hose); + resource_size_t (*pcibios_default_alignment)(void); + #ifdef CONFIG_PCI_IOV void (*pcibios_fixup_sriov)(struct pci_dev *pdev); resource_size_t (*pcibios_iov_resource_alignment)(struct pci_dev *, int resno); |