linux-next: manual merge of the drm tree with the drm-fixes tree
Mark Brown
maintainerHi all,
Today's linux-next merge of the drm tree got a conflict in:
drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm_crtc.c
between commits:
8382cd234981a ("drm/amd/display: consolidate DCN vblank/flip handling onto vupdate_no_lock") 82730dba0cf9d ("drm/amd/display: Fix flip-done timeouts on mode1 reset")
from the drm-fixes tree and commit:
c87e6635d2db0 ("drm/amd/display: consolidate DCN vblank/flip handling onto vupdate_no_lock")
from the drm tree.
I fixed it up (see below) and can carry the fix as necessary. This is now fixed as far as linux-next is concerned, but any non trivial conflicts should be mentioned to your upstream maintainer when your tree is submitted for merging. You may also want to consider cooperating with the maintainer of the conflicting tree to minimise any particularly complex conflicts.
drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm_crtc.c +0 -0
@@@ -34,6 -34,7 +34,7 @@@#include "amdgpu_dm_plane.h" #include "amdgpu_dm_trace.h" #include "amdgpu_dm_debugfs.h" +#include "amdgpu_dm_kunit_helpers.h" #include "modules/inc/mod_power.h" #define HPD_DETECTION_PERIOD_uS 2000000 {return crtc_state->active &&drm_atomic_crtc_needs_modeset (crtc_state); } +EXPORT_IF_KUNIT (amdgpu_dm_crtc_modeset_required); bool amdgpu_dm_crtc_vrr_active_irq(struct amdgpu_crtc *acrtc) acrtc->dm_irq_params.freesync_config.state == VRR_STATE_ACTIVE_FIXED; } +EXPORT_IF_KUNIT (amdgpu_dm_crtc_vrr_active_irq);int amdgpu_dm_crtc_set_vupdate_irq (struct drm_crtc *crtc,bool enable) { acrtc->crtc_id, enable ? "en" : "dis", rc);return rc; } +EXPORT_IF_KUNIT (amdgpu_dm_crtc_set_vupdate_irq);bool amdgpu_dm_crtc_vrr_active (const struct dm_crtc_state *dm_state) {return dm_state->freesync_config.state ==VRR_STATE_ACTIVE_VARIABLE || dm_state->freesync_config.state ==VRR_STATE_ACTIVE_FIXED ; } +EXPORT_IF_KUNIT (amdgpu_dm_crtc_vrr_active);/** * amdgpu_dm_crtc_set_static_screen_optimze() - Toggle static screen optimizations. drm_connector_list_iter_end(&iter); return is_headless; } +EXPORT_IF_KUNIT(amdgpu_dm_is_headless); static void amdgpu_dm_idle_worker(struct work_struct *work) { return idle_work; } +EXPORT_IF_KUNIT(idle_create_workqueue); static void amdgpu_dm_crtc_vblank_control_worker(struct work_struct *work) { * is enabled. On DCE, vupdate is only needed in VRR mode. */ if (amdgpu_ip_version (adev,DCE_HWIP ,0 ) !=0 ) { + rc =amdgpu_dm_crtc_set_vupdate_irq (crtc, enable); + }else if (dc_supports_vrr (dm->dc->ctx->dce_version)) {if (enable) { -/* vblank irq on -> Only need vupdate irq in vrr mode */ + rc =amdgpu_irq_get (adev, &adev->vupdate_irq, irq_type); +drm_dbg_vbl (crtc->dev,"Get vupdate_irq ret=%d\n" , rc); + } else { + rc =amdgpu_irq_put (adev, &adev->vupdate_irq, irq_type); +drm_dbg_vbl (crtc->dev,"Put vupdate_irq ret=%d\n" , rc); + } + } else if (dc_supports_vrr(dm->dc->ctx->dce_version)) { + if (enable) { +/* vblank irq on -> Only need vupdate irq in vrr mode + * Not ref-counted since we need explicit enable/disable + * for DCE VRR handling + */ if (amdgpu_dm_crtc_vrr_active(acrtc_state)) rc = amdgpu_dm_crtc_set_vupdate_irq(crtc, true); }else { {struct dm_crtc_state *state; + state =kzalloc_obj (*state); +if (!state) +return ; +if (crtc->state)amdgpu_dm_crtc_destroy_state (crtc, crtc->state); - state =kzalloc_obj (*state); -if (WARN_ON (!state)) -return ; -__drm_atomic_helper_crtc_reset (crtc, &state->base); }amdgpu_dm_crtc_count_crtc_active_planes (new_crtc_state); } -static bool amdgpu_dm_crtc_helper_mode_fixup (struct drm_crtc *crtc, -const struct drm_display_mode *mode, -struct drm_display_mode *adjusted_mode) + STATIC_IFN_KUNIT bool amdgpu_dm_crtc_helper_mode_fixup(struct drm_crtc *crtc, +const struct drm_display_mode *mode, +struct drm_display_mode *adjusted_mode) {return true; } +EXPORT_IF_KUNIT (amdgpu_dm_crtc_helper_mode_fixup);static int amdgpu_dm_crtc_helper_atomic_check (struct drm_crtc *crtc,struct drm_atomic_commit *state)