OSDN Git Service

drm/amd/display: fix crash caused by incorrect index being used for array
authorDmytro Laktyushkin <Dmytro.Laktyushkin@amd.com>
Wed, 26 Apr 2017 14:54:45 +0000 (10:54 -0400)
committerAlex Deucher <alexander.deucher@amd.com>
Tue, 26 Sep 2017 22:06:42 +0000 (18:06 -0400)
Signed-off-by: Dmytro Laktyushkin <Dmytro.Laktyushkin@amd.com>
Acked-by: Harry Wentland <Harry.Wentland@amd.com>
Reviewed-by: Anthony Koo <Anthony.Koo@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
drivers/gpu/drm/amd/display/modules/freesync/freesync.c

index f6223e6..d3d5700 100644 (file)
@@ -1122,7 +1122,7 @@ void mod_freesync_notify_mode_change(struct mod_freesync *mod_freesync,
                         * current mode
                         */
                        calc_freesync_range(core_freesync, *streams, state,
-                               core_freesync->map[stream_index].caps->
+                               core_freesync->map[map_index].caps->
                                min_refresh_in_micro_hz,
                                state->nominal_refresh_rate_in_micro_hz);
                }