drm/radeon: do not reenable crtc after moving vram start address
It seems we can not update the crtc scanout address. After disabling crtc, update to base address do not take effect after crtc being reenable leading to at least frame being scanout from the old crtc base address. Disabling crtc display request lead to same behavior. So after changing the vram address if we don't keep crtc disabled we will have the GPU trying to read some random system memory address with some iommu this will broke the crtc engine and will lead to broken display and iommu error message. So to avoid this, disable crtc. For flicker less boot we will need to avoid moving the vram start address. This patch should also fix : https://bugs.freedesktop.org/show_bug.cgi?id=42373 Cc: <stable@vger.kernel.org> Signed-off-by: Jerome Glisse <jglisse@redhat.com>
This commit is contained in:

committed by
Alex Deucher

parent
5b23c9045a
commit
81ee8fb6b5
@@ -281,12 +281,8 @@ int rv515_debugfs_ga_info_init(struct radeon_device *rdev)
|
||||
|
||||
void rv515_mc_stop(struct radeon_device *rdev, struct rv515_mc_save *save)
|
||||
{
|
||||
save->d1vga_control = RREG32(R_000330_D1VGA_CONTROL);
|
||||
save->d2vga_control = RREG32(R_000338_D2VGA_CONTROL);
|
||||
save->vga_render_control = RREG32(R_000300_VGA_RENDER_CONTROL);
|
||||
save->vga_hdp_control = RREG32(R_000328_VGA_HDP_CONTROL);
|
||||
save->d1crtc_control = RREG32(R_006080_D1CRTC_CONTROL);
|
||||
save->d2crtc_control = RREG32(R_006880_D2CRTC_CONTROL);
|
||||
|
||||
/* Stop all video */
|
||||
WREG32(R_0068E8_D2CRTC_UPDATE_LOCK, 0);
|
||||
@@ -311,15 +307,6 @@ void rv515_mc_resume(struct radeon_device *rdev, struct rv515_mc_save *save)
|
||||
/* Unlock host access */
|
||||
WREG32(R_000328_VGA_HDP_CONTROL, save->vga_hdp_control);
|
||||
mdelay(1);
|
||||
/* Restore video state */
|
||||
WREG32(R_000330_D1VGA_CONTROL, save->d1vga_control);
|
||||
WREG32(R_000338_D2VGA_CONTROL, save->d2vga_control);
|
||||
WREG32(R_0060E8_D1CRTC_UPDATE_LOCK, 1);
|
||||
WREG32(R_0068E8_D2CRTC_UPDATE_LOCK, 1);
|
||||
WREG32(R_006080_D1CRTC_CONTROL, save->d1crtc_control);
|
||||
WREG32(R_006880_D2CRTC_CONTROL, save->d2crtc_control);
|
||||
WREG32(R_0060E8_D1CRTC_UPDATE_LOCK, 0);
|
||||
WREG32(R_0068E8_D2CRTC_UPDATE_LOCK, 0);
|
||||
WREG32(R_000300_VGA_RENDER_CONTROL, save->vga_render_control);
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user