mirror of
https://github.com/Fishwaldo/Star64_linux.git
synced 2025-06-29 10:01:25 +00:00
Merge branch 'drm-fixes-4.20' of git://people.freedesktop.org/~agd5f/linux into drm-fixes
Fixes for 4.20. Nothing major. - DC DP MST fix - GPUVM fix for huge page mapping - RLC fix for vega20 Signed-off-by: Dave Airlie <airlied@redhat.com> From: Alex Deucher <alexdeucher@gmail.com> Link: https://patchwork.freedesktop.org/patch/msgid/20181128195905.2897-1-alexander.deucher@amd.com
This commit is contained in:
commit
50c1877127
3 changed files with 14 additions and 12 deletions
|
@ -181,7 +181,7 @@ static unsigned amdgpu_vm_num_entries(struct amdgpu_device *adev,
|
||||||
|
|
||||||
if (level == adev->vm_manager.root_level)
|
if (level == adev->vm_manager.root_level)
|
||||||
/* For the root directory */
|
/* For the root directory */
|
||||||
return round_up(adev->vm_manager.max_pfn, 1 << shift) >> shift;
|
return round_up(adev->vm_manager.max_pfn, 1ULL << shift) >> shift;
|
||||||
else if (level != AMDGPU_VM_PTB)
|
else if (level != AMDGPU_VM_PTB)
|
||||||
/* Everything in between */
|
/* Everything in between */
|
||||||
return 512;
|
return 512;
|
||||||
|
@ -1656,9 +1656,11 @@ static int amdgpu_vm_update_ptes(struct amdgpu_pte_update_params *params,
|
||||||
if (!amdgpu_vm_pt_descendant(adev, &cursor))
|
if (!amdgpu_vm_pt_descendant(adev, &cursor))
|
||||||
return -ENOENT;
|
return -ENOENT;
|
||||||
continue;
|
continue;
|
||||||
} else if (frag >= parent_shift) {
|
} else if (frag >= parent_shift &&
|
||||||
|
cursor.level - 1 != adev->vm_manager.root_level) {
|
||||||
/* If the fragment size is even larger than the parent
|
/* If the fragment size is even larger than the parent
|
||||||
* shift we should go up one level and check it again.
|
* shift we should go up one level and check it again
|
||||||
|
* unless one level up is the root level.
|
||||||
*/
|
*/
|
||||||
if (!amdgpu_vm_pt_ancestor(&cursor))
|
if (!amdgpu_vm_pt_ancestor(&cursor))
|
||||||
return -ENOENT;
|
return -ENOENT;
|
||||||
|
@ -1666,10 +1668,10 @@ static int amdgpu_vm_update_ptes(struct amdgpu_pte_update_params *params,
|
||||||
}
|
}
|
||||||
|
|
||||||
/* Looks good so far, calculate parameters for the update */
|
/* Looks good so far, calculate parameters for the update */
|
||||||
incr = AMDGPU_GPU_PAGE_SIZE << shift;
|
incr = (uint64_t)AMDGPU_GPU_PAGE_SIZE << shift;
|
||||||
mask = amdgpu_vm_entries_mask(adev, cursor.level);
|
mask = amdgpu_vm_entries_mask(adev, cursor.level);
|
||||||
pe_start = ((cursor.pfn >> shift) & mask) * 8;
|
pe_start = ((cursor.pfn >> shift) & mask) * 8;
|
||||||
entry_end = (mask + 1) << shift;
|
entry_end = (uint64_t)(mask + 1) << shift;
|
||||||
entry_end += cursor.pfn & ~(entry_end - 1);
|
entry_end += cursor.pfn & ~(entry_end - 1);
|
||||||
entry_end = min(entry_end, end);
|
entry_end = min(entry_end, end);
|
||||||
|
|
||||||
|
@ -1682,7 +1684,7 @@ static int amdgpu_vm_update_ptes(struct amdgpu_pte_update_params *params,
|
||||||
flags | AMDGPU_PTE_FRAG(frag));
|
flags | AMDGPU_PTE_FRAG(frag));
|
||||||
|
|
||||||
pe_start += nptes * 8;
|
pe_start += nptes * 8;
|
||||||
dst += nptes * AMDGPU_GPU_PAGE_SIZE << shift;
|
dst += (uint64_t)nptes * AMDGPU_GPU_PAGE_SIZE << shift;
|
||||||
|
|
||||||
frag_start = upd_end;
|
frag_start = upd_end;
|
||||||
if (frag_start >= frag_end) {
|
if (frag_start >= frag_end) {
|
||||||
|
|
|
@ -2440,12 +2440,13 @@ static void gfx_v9_0_rlc_start(struct amdgpu_device *adev)
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
WREG32_FIELD15(GC, 0, RLC_CNTL, RLC_ENABLE_F32, 1);
|
WREG32_FIELD15(GC, 0, RLC_CNTL, RLC_ENABLE_F32, 1);
|
||||||
|
udelay(50);
|
||||||
|
|
||||||
/* carrizo do enable cp interrupt after cp inited */
|
/* carrizo do enable cp interrupt after cp inited */
|
||||||
if (!(adev->flags & AMD_IS_APU))
|
if (!(adev->flags & AMD_IS_APU)) {
|
||||||
gfx_v9_0_enable_gui_idle_interrupt(adev, true);
|
gfx_v9_0_enable_gui_idle_interrupt(adev, true);
|
||||||
|
|
||||||
udelay(50);
|
udelay(50);
|
||||||
|
}
|
||||||
|
|
||||||
#ifdef AMDGPU_RLC_DEBUG_RETRY
|
#ifdef AMDGPU_RLC_DEBUG_RETRY
|
||||||
/* RLC_GPM_GENERAL_6 : RLC Ucode version */
|
/* RLC_GPM_GENERAL_6 : RLC Ucode version */
|
||||||
|
|
|
@ -342,10 +342,9 @@ dm_dp_add_mst_connector(struct drm_dp_mst_topology_mgr *mgr,
|
||||||
master->connector_id);
|
master->connector_id);
|
||||||
|
|
||||||
aconnector->mst_encoder = dm_dp_create_fake_mst_encoder(master);
|
aconnector->mst_encoder = dm_dp_create_fake_mst_encoder(master);
|
||||||
|
drm_connector_attach_encoder(&aconnector->base,
|
||||||
|
&aconnector->mst_encoder->base);
|
||||||
|
|
||||||
/*
|
|
||||||
* TODO: understand why this one is needed
|
|
||||||
*/
|
|
||||||
drm_object_attach_property(
|
drm_object_attach_property(
|
||||||
&connector->base,
|
&connector->base,
|
||||||
dev->mode_config.path_property,
|
dev->mode_config.path_property,
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue