diff mbox series

[PATCHv2,AWS-{F,G}] UBUNTU: SAUCE: arm64: Enable PCI write-combine resources under sysfs

Message ID 20201007201120.12793-3-kamal@canonical.com
State New
Headers show
Series [PATCHv2,AWS-{F,G}] UBUNTU: SAUCE: arm64: Enable PCI write-combine resources under sysfs | expand

Commit Message

Kamal Mostafa Oct. 7, 2020, 8:11 p.m. UTC
From: Clint Sbisa <csbisa@amazon.com>

BugLink: https://bugs.launchpad.net/bugs/1893817

Using write-combine is crucial for performance of PCI devices where
significant amounts of transactions go over PCI BARs.

arm64 supports write-combine PCI mappings, so the appropriate define
has been added which will expose write-combine mappings under sysfs
for prefetchable PCI resources.

Signed-off-by: Clint Sbisa <csbisa@amazon.com>
Reference: https://lore.kernel.org/linux-pci/20200831151827.pumm2p54fyj7fz5s@amazon.com/
Signed-off-by: Kamal Mostafa <kamal@canonical.com>
Acked-by: Stefan Bader <stefan.bader@canonical.com>                             
Acked-by: Andrea Righi <andrea.righi@canonical.com>                             
---
 arch/arm64/include/asm/pci.h | 1 +
 1 file changed, 1 insertion(+)

Comments

Ian May Oct. 9, 2020, 7 p.m. UTC | #1
Applied to aws-focal.  

Thanks!
Ian

On 2020-10-07 13:11:20 , Kamal Mostafa wrote:
> From: Clint Sbisa <csbisa@amazon.com>
> 
> BugLink: https://bugs.launchpad.net/bugs/1893817
> 
> Using write-combine is crucial for performance of PCI devices where
> significant amounts of transactions go over PCI BARs.
> 
> arm64 supports write-combine PCI mappings, so the appropriate define
> has been added which will expose write-combine mappings under sysfs
> for prefetchable PCI resources.
> 
> Signed-off-by: Clint Sbisa <csbisa@amazon.com>
> Reference: https://lore.kernel.org/linux-pci/20200831151827.pumm2p54fyj7fz5s@amazon.com/
> Signed-off-by: Kamal Mostafa <kamal@canonical.com>
> Acked-by: Stefan Bader <stefan.bader@canonical.com>                             
> Acked-by: Andrea Righi <andrea.righi@canonical.com>                             
> ---
>  arch/arm64/include/asm/pci.h | 1 +
>  1 file changed, 1 insertion(+)
> 
> diff --git a/arch/arm64/include/asm/pci.h b/arch/arm64/include/asm/pci.h
> index 70b323cf8300..b33ca260e3c9 100644
> --- a/arch/arm64/include/asm/pci.h
> +++ b/arch/arm64/include/asm/pci.h
> @@ -17,6 +17,7 @@
>  #define pcibios_assign_all_busses() \
>  	(pci_has_flag(PCI_REASSIGN_ALL_BUS))
>  
> +#define arch_can_pci_mmap_wc() 1
>  #define ARCH_GENERIC_PCI_MMAP_RESOURCE	1
>  
>  extern int isa_dma_bridge_buggy;
> -- 
> 2.17.1
> 
> -- 
> kernel-team mailing list
> kernel-team@lists.ubuntu.com
> https://lists.ubuntu.com/mailman/listinfo/kernel-team
diff mbox series

Patch

diff --git a/arch/arm64/include/asm/pci.h b/arch/arm64/include/asm/pci.h
index 70b323cf8300..b33ca260e3c9 100644
--- a/arch/arm64/include/asm/pci.h
+++ b/arch/arm64/include/asm/pci.h
@@ -17,6 +17,7 @@ 
 #define pcibios_assign_all_busses() \
 	(pci_has_flag(PCI_REASSIGN_ALL_BUS))
 
+#define arch_can_pci_mmap_wc() 1
 #define ARCH_GENERIC_PCI_MMAP_RESOURCE	1
 
 extern int isa_dma_bridge_buggy;