Signed-off-by: Anthony Koo <anthony.koo@amd.com>
Reviewed-by: Aric Cyr <Aric.Cyr@amd.com>
Acked-by: Harry Wentland <Harry.Wentland@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
for (i = 0; i < core_color->num_sinks; i++) {
if (core_color->caps[i].sink == sink) {
- if (core_color->state[i].gamma)
+ if (core_color->state[i].gamma) {
dc_gamma_release(core_color->state[i].gamma);
+ core_color->state[i].gamma = NULL;
+ }
/* To remove this sink, shift everything after down */
for (j = i; j < core_color->num_sinks - 1; j++) {