Skip to content

Commit

Permalink
drm/radeon: properly set vm fragment size for TN/RL
Browse files Browse the repository at this point in the history
Should be the same as cayman.  We don't use VM by default
on NI parts so this isn't critical.

Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
Cc: stable@vger.kernel.org
  • Loading branch information
Alex Deucher committed Feb 2, 2015
1 parent 544143f commit a124d06
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions drivers/gpu/drm/radeon/radeon_vm.c
Original file line number Diff line number Diff line change
Expand Up @@ -743,9 +743,11 @@ static void radeon_vm_frag_ptes(struct radeon_device *rdev,
*/

/* NI is optimized for 256KB fragments, SI and newer for 64KB */
uint64_t frag_flags = rdev->family == CHIP_CAYMAN ?
uint64_t frag_flags = ((rdev->family == CHIP_CAYMAN) ||
(rdev->family == CHIP_ARUBA)) ?
R600_PTE_FRAG_256KB : R600_PTE_FRAG_64KB;
uint64_t frag_align = rdev->family == CHIP_CAYMAN ? 0x200 : 0x80;
uint64_t frag_align = ((rdev->family == CHIP_CAYMAN) ||
(rdev->family == CHIP_ARUBA)) ? 0x200 : 0x80;

uint64_t frag_start = ALIGN(pe_start, frag_align);
uint64_t frag_end = pe_end & ~(frag_align - 1);
Expand Down

0 comments on commit a124d06

Please sign in to comment.