diff options
Diffstat (limited to 'drivers/gpu/drm/radeon/evergreen.c')
-rw-r--r-- | drivers/gpu/drm/radeon/evergreen.c | 28 |
1 files changed, 9 insertions, 19 deletions
diff --git a/drivers/gpu/drm/radeon/evergreen.c b/drivers/gpu/drm/radeon/evergreen.c index 941080a77940..3453910ee0f3 100644 --- a/drivers/gpu/drm/radeon/evergreen.c +++ b/drivers/gpu/drm/radeon/evergreen.c | |||
@@ -43,17 +43,6 @@ static void evergreen_pcie_gen2_enable(struct radeon_device *rdev); | |||
43 | 43 | ||
44 | void evergreen_pre_page_flip(struct radeon_device *rdev, int crtc) | 44 | void evergreen_pre_page_flip(struct radeon_device *rdev, int crtc) |
45 | { | 45 | { |
46 | struct radeon_crtc *radeon_crtc = rdev->mode_info.crtcs[crtc]; | ||
47 | u32 tmp; | ||
48 | |||
49 | /* make sure flip is at vb rather than hb */ | ||
50 | tmp = RREG32(EVERGREEN_GRPH_FLIP_CONTROL + radeon_crtc->crtc_offset); | ||
51 | tmp &= ~EVERGREEN_GRPH_SURFACE_UPDATE_H_RETRACE_EN; | ||
52 | WREG32(EVERGREEN_GRPH_FLIP_CONTROL + radeon_crtc->crtc_offset, tmp); | ||
53 | |||
54 | /* set pageflip to happen anywhere in vblank interval */ | ||
55 | WREG32(EVERGREEN_MASTER_UPDATE_MODE + radeon_crtc->crtc_offset, 0); | ||
56 | |||
57 | /* enable the pflip int */ | 46 | /* enable the pflip int */ |
58 | radeon_irq_kms_pflip_irq_get(rdev, crtc); | 47 | radeon_irq_kms_pflip_irq_get(rdev, crtc); |
59 | } | 48 | } |
@@ -131,11 +120,16 @@ void evergreen_pm_misc(struct radeon_device *rdev) | |||
131 | struct radeon_power_state *ps = &rdev->pm.power_state[req_ps_idx]; | 120 | struct radeon_power_state *ps = &rdev->pm.power_state[req_ps_idx]; |
132 | struct radeon_voltage *voltage = &ps->clock_info[req_cm_idx].voltage; | 121 | struct radeon_voltage *voltage = &ps->clock_info[req_cm_idx].voltage; |
133 | 122 | ||
134 | if ((voltage->type == VOLTAGE_SW) && voltage->voltage) { | 123 | if (voltage->type == VOLTAGE_SW) { |
135 | if (voltage->voltage != rdev->pm.current_vddc) { | 124 | if (voltage->voltage && (voltage->voltage != rdev->pm.current_vddc)) { |
136 | radeon_atom_set_voltage(rdev, voltage->voltage); | 125 | radeon_atom_set_voltage(rdev, voltage->voltage, SET_VOLTAGE_TYPE_ASIC_VDDC); |
137 | rdev->pm.current_vddc = voltage->voltage; | 126 | rdev->pm.current_vddc = voltage->voltage; |
138 | DRM_DEBUG("Setting: v: %d\n", voltage->voltage); | 127 | DRM_DEBUG("Setting: vddc: %d\n", voltage->voltage); |
128 | } | ||
129 | if (voltage->vddci && (voltage->vddci != rdev->pm.current_vddci)) { | ||
130 | radeon_atom_set_voltage(rdev, voltage->vddci, SET_VOLTAGE_TYPE_ASIC_VDDCI); | ||
131 | rdev->pm.current_vddci = voltage->vddci; | ||
132 | DRM_DEBUG("Setting: vddci: %d\n", voltage->vddci); | ||
139 | } | 133 | } |
140 | } | 134 | } |
141 | } | 135 | } |
@@ -3047,9 +3041,6 @@ int evergreen_init(struct radeon_device *rdev) | |||
3047 | { | 3041 | { |
3048 | int r; | 3042 | int r; |
3049 | 3043 | ||
3050 | r = radeon_dummy_page_init(rdev); | ||
3051 | if (r) | ||
3052 | return r; | ||
3053 | /* This don't do much */ | 3044 | /* This don't do much */ |
3054 | r = radeon_gem_init(rdev); | 3045 | r = radeon_gem_init(rdev); |
3055 | if (r) | 3046 | if (r) |
@@ -3161,7 +3152,6 @@ void evergreen_fini(struct radeon_device *rdev) | |||
3161 | radeon_atombios_fini(rdev); | 3152 | radeon_atombios_fini(rdev); |
3162 | kfree(rdev->bios); | 3153 | kfree(rdev->bios); |
3163 | rdev->bios = NULL; | 3154 | rdev->bios = NULL; |
3164 | radeon_dummy_page_fini(rdev); | ||
3165 | } | 3155 | } |
3166 | 3156 | ||
3167 | static void evergreen_pcie_gen2_enable(struct radeon_device *rdev) | 3157 | static void evergreen_pcie_gen2_enable(struct radeon_device *rdev) |