]> git.proxmox.com Git - mirror_ubuntu-disco-kernel.git/commitdiff
drm/amd/display: Return success when enabling interrupt
authorHarry Wentland <harry.wentland@amd.com>
Tue, 13 Feb 2018 16:03:01 +0000 (11:03 -0500)
committerAlex Deucher <alexander.deucher@amd.com>
Wed, 7 Mar 2018 21:28:15 +0000 (16:28 -0500)
Signed-off-by: Harry Wentland <harry.wentland@amd.com>
Reviewed-by: Roman Li <Roman.Li@amd.com>
Acked-by: Harry Wentland <harry.wentland@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c
drivers/gpu/drm/amd/display/dc/core/dc.c
drivers/gpu/drm/amd/display/dc/dc.h

index 79c11acdbea1b5bae3b723365421ecf8eab53e55..710286b69cba8c2bc8c38eef7462dfb872982e8b 100644 (file)
@@ -2507,8 +2507,7 @@ static inline int dm_set_vblank(struct drm_crtc *crtc, bool enable)
        struct amdgpu_device *adev = crtc->dev->dev_private;
 
        irq_source = IRQ_TYPE_VBLANK + acrtc->otg_inst;
-       dc_interrupt_set(adev->dm.dc, irq_source, enable);
-       return 0;
+       return dc_interrupt_set(adev->dm.dc, irq_source, enable) ? 0 : -EBUSY;
 }
 
 static int dm_enable_vblank(struct drm_crtc *crtc)
index 35e84ed031de08f5edfadbfb71e550291ae8ebef..12868c769606b8de546b193412d5c28052353dd5 100644 (file)
@@ -1358,13 +1358,13 @@ enum dc_irq_source dc_interrupt_to_irq_source(
        return dal_irq_service_to_irq_source(dc->res_pool->irqs, src_id, ext_id);
 }
 
-void dc_interrupt_set(struct dc *dc, enum dc_irq_source src, bool enable)
+bool dc_interrupt_set(struct dc *dc, enum dc_irq_source src, bool enable)
 {
 
        if (dc == NULL)
-               return;
+               return false;
 
-       dal_irq_service_set(dc->res_pool->irqs, src, enable);
+       return dal_irq_service_set(dc->res_pool->irqs, src, enable);
 }
 
 void dc_interrupt_ack(struct dc *dc, enum dc_irq_source src)
index b5c8f510adb0544ee77ee576162743f2273c67f9..d6d56611604eb417e47d009e1f0119305cb2ab91 100644 (file)
@@ -673,7 +673,7 @@ enum dc_irq_source dc_interrupt_to_irq_source(
                struct dc *dc,
                uint32_t src_id,
                uint32_t ext_id);
-void dc_interrupt_set(struct dc *dc, enum dc_irq_source src, bool enable);
+bool dc_interrupt_set(struct dc *dc, enum dc_irq_source src, bool enable);
 void dc_interrupt_ack(struct dc *dc, enum dc_irq_source src);
 enum dc_irq_source dc_get_hpd_irq_source_at_index(
                struct dc *dc, uint32_t link_index);