| From 9d5cbffd8c19965493f494e6b2622c1855e34831 Mon Sep 17 00:00:00 2001 |
| From: Sasha Levin <sashal@kernel.org> |
| Date: Wed, 27 Oct 2021 13:26:19 -0400 |
| Subject: drm/amdgpu/gmc6: fix DMA mask from 44 to 40 bits |
| MIME-Version: 1.0 |
| Content-Type: text/plain; charset=UTF-8 |
| Content-Transfer-Encoding: 8bit |
| |
| From: Alex Deucher <alexander.deucher@amd.com> |
| |
| [ Upstream commit 403475be6d8b122c3e6b8a47e075926d7299e5ef ] |
| |
| The DMA mask on SI parts is 40 bits not 44. Copy |
| paste typo. |
| |
| Fixes: 244511f386ccb9 ("drm/amdgpu: simplify and cleanup setting the dma mask") |
| Bug: https://gitlab.freedesktop.org/drm/amd/-/issues/1762 |
| Acked-by: Christian Kรถnig <christian.koenig@amd.com> |
| Tested-by: Paul Menzel <pmenzel@molgen.mpg.de> |
| Signed-off-by: Alex Deucher <alexander.deucher@amd.com> |
| Signed-off-by: Sasha Levin <sashal@kernel.org> |
| --- |
| drivers/gpu/drm/amd/amdgpu/gmc_v6_0.c | 4 ++-- |
| 1 file changed, 2 insertions(+), 2 deletions(-) |
| |
| diff --git a/drivers/gpu/drm/amd/amdgpu/gmc_v6_0.c b/drivers/gpu/drm/amd/amdgpu/gmc_v6_0.c |
| index 9fb1765e92d15..e9f5de35f7953 100644 |
| --- a/drivers/gpu/drm/amd/amdgpu/gmc_v6_0.c |
| +++ b/drivers/gpu/drm/amd/amdgpu/gmc_v6_0.c |
| @@ -863,12 +863,12 @@ static int gmc_v6_0_sw_init(void *handle) |
| |
| adev->gmc.mc_mask = 0xffffffffffULL; |
| |
| - r = dma_set_mask_and_coherent(adev->dev, DMA_BIT_MASK(44)); |
| + r = dma_set_mask_and_coherent(adev->dev, DMA_BIT_MASK(40)); |
| if (r) { |
| dev_warn(adev->dev, "amdgpu: No suitable DMA available.\n"); |
| return r; |
| } |
| - adev->need_swiotlb = drm_need_swiotlb(44); |
| + adev->need_swiotlb = drm_need_swiotlb(40); |
| |
| r = gmc_v6_0_init_microcode(adev); |
| if (r) { |
| -- |
| 2.33.0 |
| |