aboutsummaryrefslogtreecommitdiffstats
path: root/common/recipes-kernel/linux/files/0343-drm-amdgpu-Switch-to-drm_vblank_on-off-v2.patch
diff options
context:
space:
mode:
Diffstat (limited to 'common/recipes-kernel/linux/files/0343-drm-amdgpu-Switch-to-drm_vblank_on-off-v2.patch')
-rw-r--r--common/recipes-kernel/linux/files/0343-drm-amdgpu-Switch-to-drm_vblank_on-off-v2.patch90
1 files changed, 90 insertions, 0 deletions
diff --git a/common/recipes-kernel/linux/files/0343-drm-amdgpu-Switch-to-drm_vblank_on-off-v2.patch b/common/recipes-kernel/linux/files/0343-drm-amdgpu-Switch-to-drm_vblank_on-off-v2.patch
new file mode 100644
index 00000000..927417c9
--- /dev/null
+++ b/common/recipes-kernel/linux/files/0343-drm-amdgpu-Switch-to-drm_vblank_on-off-v2.patch
@@ -0,0 +1,90 @@
+From 7736faea95570291857765c25646204a9c9a8fdd Mon Sep 17 00:00:00 2001
+From: Daniel Vetter <daniel.vetter@ffwll.ch>
+Date: Thu, 21 Jan 2016 11:08:58 +0100
+Subject: [PATCH 0343/1110] drm/amdgpu: Switch to drm_vblank_on/off (v2)
+MIME-Version: 1.0
+Content-Type: text/plain; charset=UTF-8
+Content-Transfer-Encoding: 8bit
+
+Equivalent change to the radeon driver.
+
+Note that with radeon this caught a bug in the dri3 DDX
+implementation, which asked for vblank interrupts when the pipe is
+off. That bug needs to be fixed before we can merge this patch (if
+amdgpu is affected too). Michel discovered this one.
+
+v2: agd: switch dce8 as well.
+
+Acked-by: Michel Dänzer <michel.daenzer@amd.com>
+Cc: Michel Dänzer <michel.daenzer@amd.com>
+Signed-off-by: Daniel Vetter <daniel.vetter@intel.com>
+Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
+---
+ drivers/gpu/drm/amd/amdgpu/dce_v10_0.c | 4 ++--
+ drivers/gpu/drm/amd/amdgpu/dce_v11_0.c | 4 ++--
+ drivers/gpu/drm/amd/amdgpu/dce_v8_0.c | 4 ++--
+ 3 files changed, 6 insertions(+), 6 deletions(-)
+
+diff --git a/drivers/gpu/drm/amd/amdgpu/dce_v10_0.c b/drivers/gpu/drm/amd/amdgpu/dce_v10_0.c
+index a8ac8a3..25b4680 100644
+--- a/drivers/gpu/drm/amd/amdgpu/dce_v10_0.c
++++ b/drivers/gpu/drm/amd/amdgpu/dce_v10_0.c
+@@ -2700,13 +2700,13 @@ static void dce_v10_0_crtc_dpms(struct drm_crtc *crtc, int mode)
+ type = amdgpu_crtc_idx_to_irq_type(adev, amdgpu_crtc->crtc_id);
+ amdgpu_irq_update(adev, &adev->crtc_irq, type);
+ amdgpu_irq_update(adev, &adev->pageflip_irq, type);
+- drm_vblank_post_modeset(dev, amdgpu_crtc->crtc_id);
++ drm_vblank_on(dev, amdgpu_crtc->crtc_id);
+ dce_v10_0_crtc_load_lut(crtc);
+ break;
+ case DRM_MODE_DPMS_STANDBY:
+ case DRM_MODE_DPMS_SUSPEND:
+ case DRM_MODE_DPMS_OFF:
+- drm_vblank_pre_modeset(dev, amdgpu_crtc->crtc_id);
++ drm_vblank_off(dev, amdgpu_crtc->crtc_id);
+ if (amdgpu_crtc->enabled) {
+ dce_v10_0_vga_enable(crtc, true);
+ amdgpu_atombios_crtc_blank(crtc, ATOM_ENABLE);
+diff --git a/drivers/gpu/drm/amd/amdgpu/dce_v11_0.c b/drivers/gpu/drm/amd/amdgpu/dce_v11_0.c
+index a7699be..41e94d4 100644
+--- a/drivers/gpu/drm/amd/amdgpu/dce_v11_0.c
++++ b/drivers/gpu/drm/amd/amdgpu/dce_v11_0.c
+@@ -2691,13 +2691,13 @@ static void dce_v11_0_crtc_dpms(struct drm_crtc *crtc, int mode)
+ type = amdgpu_crtc_idx_to_irq_type(adev, amdgpu_crtc->crtc_id);
+ amdgpu_irq_update(adev, &adev->crtc_irq, type);
+ amdgpu_irq_update(adev, &adev->pageflip_irq, type);
+- drm_vblank_post_modeset(dev, amdgpu_crtc->crtc_id);
++ drm_vblank_on(dev, amdgpu_crtc->crtc_id);
+ dce_v11_0_crtc_load_lut(crtc);
+ break;
+ case DRM_MODE_DPMS_STANDBY:
+ case DRM_MODE_DPMS_SUSPEND:
+ case DRM_MODE_DPMS_OFF:
+- drm_vblank_pre_modeset(dev, amdgpu_crtc->crtc_id);
++ drm_vblank_off(dev, amdgpu_crtc->crtc_id);
+ if (amdgpu_crtc->enabled) {
+ dce_v11_0_vga_enable(crtc, true);
+ amdgpu_atombios_crtc_blank(crtc, ATOM_ENABLE);
+diff --git a/drivers/gpu/drm/amd/amdgpu/dce_v8_0.c b/drivers/gpu/drm/amd/amdgpu/dce_v8_0.c
+index 628d7b2..a220711 100644
+--- a/drivers/gpu/drm/amd/amdgpu/dce_v8_0.c
++++ b/drivers/gpu/drm/amd/amdgpu/dce_v8_0.c
+@@ -2612,13 +2612,13 @@ static void dce_v8_0_crtc_dpms(struct drm_crtc *crtc, int mode)
+ type = amdgpu_crtc_idx_to_irq_type(adev, amdgpu_crtc->crtc_id);
+ amdgpu_irq_update(adev, &adev->crtc_irq, type);
+ amdgpu_irq_update(adev, &adev->pageflip_irq, type);
+- drm_vblank_post_modeset(dev, amdgpu_crtc->crtc_id);
++ drm_vblank_on(dev, amdgpu_crtc->crtc_id);
+ dce_v8_0_crtc_load_lut(crtc);
+ break;
+ case DRM_MODE_DPMS_STANDBY:
+ case DRM_MODE_DPMS_SUSPEND:
+ case DRM_MODE_DPMS_OFF:
+- drm_vblank_pre_modeset(dev, amdgpu_crtc->crtc_id);
++ drm_vblank_off(dev, amdgpu_crtc->crtc_id);
+ if (amdgpu_crtc->enabled) {
+ dce_v8_0_vga_enable(crtc, true);
+ amdgpu_atombios_crtc_blank(crtc, ATOM_ENABLE);
+--
+2.7.4
+