diff options
Diffstat (limited to 'meta-amd-bsp/recipes-kernel/linux-6.6/linux-yocto-6.6/0006-ntb-set-the-dma-mask-to-48-bit-addressing-capability.patch')
-rw-r--r-- | meta-amd-bsp/recipes-kernel/linux-6.6/linux-yocto-6.6/0006-ntb-set-the-dma-mask-to-48-bit-addressing-capability.patch | 31 |
1 files changed, 31 insertions, 0 deletions
diff --git a/meta-amd-bsp/recipes-kernel/linux-6.6/linux-yocto-6.6/0006-ntb-set-the-dma-mask-to-48-bit-addressing-capability.patch b/meta-amd-bsp/recipes-kernel/linux-6.6/linux-yocto-6.6/0006-ntb-set-the-dma-mask-to-48-bit-addressing-capability.patch new file mode 100644 index 00000000..0065ab7d --- /dev/null +++ b/meta-amd-bsp/recipes-kernel/linux-6.6/linux-yocto-6.6/0006-ntb-set-the-dma-mask-to-48-bit-addressing-capability.patch @@ -0,0 +1,31 @@ +From 9e22c76dc45ed7514995615c0c5cd2fa3c8ce977 Mon Sep 17 00:00:00 2001 +From: Basavaraj Natikar <Basavaraj.Natikar@amd.com> +Date: Thu, 28 Mar 2024 22:13:19 +0530 +Subject: [PATCH 6/6] ntb: set the dma mask to 48-bit addressing capability + +Even though the NTB HW supports 64-bit addressing, +the MPDMA HW is only capable of 48-bit addressing. +So if a 64-bit address is assigned to NTB via IOMMU, +the MPDMA will not be able to access that range. We +need to make sure the addressability mask is correctly +set for NTB HW. +--- + drivers/ntb/hw/amd/ntb_hw_amd.c | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/drivers/ntb/hw/amd/ntb_hw_amd.c b/drivers/ntb/hw/amd/ntb_hw_amd.c +index d687e8c2cc78..2bfa0aea241d 100644 +--- a/drivers/ntb/hw/amd/ntb_hw_amd.c ++++ b/drivers/ntb/hw/amd/ntb_hw_amd.c +@@ -1173,7 +1173,7 @@ static int amd_ntb_init_pci(struct amd_ntb_dev *ndev, + + pci_set_master(pdev); + +- rc = dma_set_mask_and_coherent(&pdev->dev, DMA_BIT_MASK(64)); ++ rc = dma_set_mask_and_coherent(&pdev->dev, DMA_BIT_MASK(48)); + if (rc) { + rc = dma_set_mask_and_coherent(&pdev->dev, DMA_BIT_MASK(32)); + if (rc) +-- +2.34.1 + |