From 3565394ee482207cee9f82d4af7f905e0731834d Mon Sep 17 00:00:00 2001 From: Jerome Glisse Date: Wed, 20 Feb 2013 11:28:45 -0500 Subject: [PATCH] EG PPC DEBUG HACK This should not be necessary as we already update this in evergreen_mc_stop but never know --- drivers/gpu/drm/radeon/evergreen.c | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+) diff --git a/drivers/gpu/drm/radeon/evergreen.c b/drivers/gpu/drm/radeon/evergreen.c index a2d478e..8b2d084 100644 --- a/drivers/gpu/drm/radeon/evergreen.c +++ b/drivers/gpu/drm/radeon/evergreen.c @@ -3514,6 +3514,25 @@ static int evergreen_startup(struct radeon_device *rdev) return r; } + /* HACK DUMP VARIOUS CRTC REGISTER BASE ADDRESS VALUE */ + { + unsigned i; + for (i = 0; i < rdev->num_crtc; i++) { + uint64_t addr; + + addr = ((unsigned long long) RREG32(EVERGREEN_GRPH_PRIMARY_SURFACE_ADDRESS_HIGH + crtc_offsets[i])) << 32ULL; + addr |= RREG32(EVERGREEN_GRPH_PRIMARY_SURFACE_ADDRESS + crtc_offsets[i]); + DRM_INFO("GRPH_PRIMARY_SURFACE[%2d] 0x%016llx\n", i, addr); + addr = ((unsigned long long) RREG32(EVERGREEN_GRPH_SECONDARY_SURFACE_ADDRESS_HIGH + crtc_offsets[i])) << 32ULL; + addr |= RREG32(EVERGREEN_GRPH_SECONDARY_SURFACE_ADDRESS + crtc_offsets[i]); + DRM_INFO("GRPH_SECONDARY_SURFACE[%2d] 0x%016llx\n", i, addr); + WREG32(EVERGREEN_GRPH_PRIMARY_SURFACE_ADDRESS_HIGH + crtc_offsets[i], 0); + WREG32(EVERGREEN_GRPH_PRIMARY_SURFACE_ADDRESS + crtc_offsets[i], 0); + WREG32(EVERGREEN_GRPH_SECONDARY_SURFACE_ADDRESS_HIGH + crtc_offsets[i], 0); + WREG32(EVERGREEN_GRPH_SECONDARY_SURFACE_ADDRESS + crtc_offsets[i], 0); + } + } + return 0; } -- 1.7.11.7