提交 005a83f1 编写于 作者: A Alex Deucher 提交者: Dave Airlie

drm/radeon/kms: set DMA mask properly on newer PCI asics

If a card wasn't PCIE, we always set the DMA mask to 32 bits.
This is only applies to the old rage128/r1xx gart block on
early radeon asics (~r1xx-r4xx).  Newer PCI and IGP cards
can handle 40 bits just fine.
Signed-off-by: NAlex Deucher <alexander.deucher@amd.com>
Cc: Chen Jie <chenj@lemote.com>
Signed-off-by: NDave Airlie <airlied@redhat.com>
上级 c245cb9e
...@@ -750,14 +750,15 @@ int radeon_device_init(struct radeon_device *rdev, ...@@ -750,14 +750,15 @@ int radeon_device_init(struct radeon_device *rdev,
/* set DMA mask + need_dma32 flags. /* set DMA mask + need_dma32 flags.
* PCIE - can handle 40-bits. * PCIE - can handle 40-bits.
* IGP - can handle 40-bits (in theory) * IGP - can handle 40-bits
* AGP - generally dma32 is safest * AGP - generally dma32 is safest
* PCI - only dma32 * PCI - dma32 for legacy pci gart, 40 bits on newer asics
*/ */
rdev->need_dma32 = false; rdev->need_dma32 = false;
if (rdev->flags & RADEON_IS_AGP) if (rdev->flags & RADEON_IS_AGP)
rdev->need_dma32 = true; rdev->need_dma32 = true;
if (rdev->flags & RADEON_IS_PCI) if ((rdev->flags & RADEON_IS_PCI) &&
(rdev->family < CHIP_RS400))
rdev->need_dma32 = true; rdev->need_dma32 = true;
dma_bits = rdev->need_dma32 ? 32 : 40; dma_bits = rdev->need_dma32 ? 32 : 40;
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册