{
resource_validate_ctx_destruct(dc->current_context);
- dm_free(dc->temp_flip_context);
- dc->temp_flip_context = NULL;
- dm_free(dc->scratch_val_ctx);
- dc->scratch_val_ctx = NULL;
-
destroy_links(dc);
dc_destroy_resource_pool(dc);
dm_free(dc->current_context);
dc->current_context = NULL;
+ dm_free(dc->temp_flip_context);
+ dc->temp_flip_context = NULL;
+ dm_free(dc->scratch_val_ctx);
+ dc->scratch_val_ctx = NULL;
dm_free(dc->ctx);
dc->ctx = NULL;
dc->current_context = dm_alloc(sizeof(*dc->current_context));
dc->temp_flip_context = dm_alloc(sizeof(*dc->temp_flip_context));
- dc->scratch_val_ctx = dm_alloc(sizeof(*dc->temp_flip_context));
+ dc->scratch_val_ctx = dm_alloc(sizeof(*dc->scratch_val_ctx));
if (!dc->current_context || !dc->temp_flip_context) {
dm_error("%s: failed to create validate ctx\n", __func__);
goto unexpected_fail;
}
resource_validate_ctx_destruct(context);
+ ASSERT(core_dc->scratch_val_ctx == temp_context);
core_dc->scratch_val_ctx = context;
context = temp_context;
}
/* The output from BW and WM calculations. */
struct bw_calcs_output bw_results;
- /* Note: this is a big structure, do *not* put on stack! */
+ /* Note: these are big structures, do *not* put on stack! */
struct dm_pp_display_configuration pp_display_cfg;
};