Patch "drm/amd/display: Fix dc_sink kref count in emulated_link_detect" has been added to the 5.10-stable tree

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



This is a note to let you know that I've just added the patch titled

    drm/amd/display: Fix dc_sink kref count in emulated_link_detect

to the 5.10-stable tree which can be found at:
    http://www.kernel.org/git/?p=linux/kernel/git/stable/stable-queue.git;a=summary

The filename of the patch is:
     drm-amd-display-fix-dc_sink-kref-count-in-emulated_l.patch
and it can be found in the queue-5.10 subdirectory.

If you, or anyone else, feels it should not be added to the stable tree,
please let <stable@xxxxxxxxxxxxxxx> know about it.



commit 96a839ab6b46380f003bc0e49967fa2165cb352a
Author: Victor Lu <victorchengchi.lu@xxxxxxx>
Date:   Thu Jan 14 22:24:14 2021 -0500

    drm/amd/display: Fix dc_sink kref count in emulated_link_detect
    
    [ Upstream commit 3ddc818d9bb877c64f5c649beab97af86c403702 ]
    
    [why]
    prev_sink is not used anywhere else in the function and the reference to
    it from dc_link is replaced with a new dc_sink.
    
    [how]
    Change dc_sink_retain(prev_sink) to dc_sink_release(prev_sink).
    
    Signed-off-by: Victor Lu <victorchengchi.lu@xxxxxxx>
    Reviewed-by: Nicholas Kazlauskas <Nicholas.Kazlauskas@xxxxxxx>
    Acked-by: Anson Jacob <Anson.Jacob@xxxxxxx>
    Tested-by: Daniel Wheeler <daniel.wheeler@xxxxxxx>
    Signed-off-by: Alex Deucher <alexander.deucher@xxxxxxx>
    Signed-off-by: Sasha Levin <sashal@xxxxxxxxxx>

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 580880212e551..e5e05a6cb62ab 100644
--- a/drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c
+++ b/drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c
@@ -1792,8 +1792,8 @@ static void emulated_link_detect(struct dc_link *link)
 	link->type = dc_connection_none;
 	prev_sink = link->local_sink;
 
-	if (prev_sink != NULL)
-		dc_sink_retain(prev_sink);
+	if (prev_sink)
+		dc_sink_release(prev_sink);
 
 	switch (link->connector_signal) {
 	case SIGNAL_TYPE_HDMI_TYPE_A: {



[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux