]> asedeno.scripts.mit.edu Git - linux.git/commitdiff
drm/amd/display: add pp_smu NULL pointer check
authorCharlene Liu <charlene.liu@amd.com>
Fri, 7 Sep 2018 17:31:34 +0000 (13:31 -0400)
committerAlex Deucher <alexander.deucher@amd.com>
Thu, 27 Sep 2018 02:09:05 +0000 (21:09 -0500)
add pp_smu NULL ptr check

Signed-off-by: Charlene Liu <charlene.liu@amd.com>
Reviewed-by: Dmytro Laktyushkin <Dmytro.Laktyushkin@amd.com>
Acked-by: Bhawanpreet Lakha <Bhawanpreet.Lakha@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
drivers/gpu/drm/amd/display/dc/core/dc.c

index 7d9be87140cc9e4b700681cbc17e6b870fdd4840..61bb3d52641c3a6b6a82c0615e9903c5d5f6c3ee 100644 (file)
@@ -1395,7 +1395,7 @@ static void notify_display_count_to_smu(
         * sent as part of pplib_apply_display_requirements.
         * So just return.
         */
-       if (!pp_smu->set_display_count)
+       if (!pp_smu || !pp_smu->set_display_count)
                return;
 
        display_count = 0;