From c0a04cc1658aea0d02c6a12cca45e67232daef1e Mon Sep 17 00:00:00 2001 From: "Leo (Sunpeng) Li" Date: Wed, 22 Nov 2017 11:05:00 -0500 Subject: [PATCH 1087/4131] drm/amdgpu: Do not ref-count on validation set The validation set is only alive for the duration of amdgpu_dm_atomic_check. Since modifications of the set are done through an interface, and only atomic_check calls those interfaces, we do not need to manage ref-counting on it. The case of another owner freeing a stream state -- and therefore freeing a reference that the validation set has -- won't happen. The set tracks the old stream states, which will not be released during atomic_check. Signed-off-by: Leo (Sunpeng) Li --- drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c | 1 - 1 file changed, 1 deletion(-) diff --git a/drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c b/drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c index 51d06df..0d95190 100644 --- a/drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c +++ b/drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c @@ -4713,7 +4713,6 @@ int amdgpu_dm_atomic_check(struct drm_device *dev, old_acrtc_state = to_dm_crtc_state(crtc->state); if (old_acrtc_state->stream) { - dc_stream_retain(old_acrtc_state->stream); set[set_count].stream = old_acrtc_state->stream; ++set_count; } -- 2.7.4