mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2026-03-20 22:50:36 +01:00
intel/ds: Nuke ralloc_ctx and ralloc_cfg
Now that perf config and context are freed we don't need this rallocs contexts. Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com> Signed-off-by: José Roberto de Souza <jose.souza@intel.com> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/29077>
This commit is contained in:
parent
6c3ebff569
commit
4b179e7bea
2 changed files with 2 additions and 15 deletions
|
|
@ -19,9 +19,7 @@ namespace pps
|
|||
{
|
||||
IntelPerf::IntelPerf(const int drm_fd)
|
||||
: drm_fd {drm_fd}
|
||||
, ralloc_ctx {ralloc_context(nullptr)}
|
||||
, ralloc_cfg {ralloc_context(nullptr)}
|
||||
, cfg {intel_perf_new(ralloc_cfg)}
|
||||
, cfg {intel_perf_new(NULL)}
|
||||
{
|
||||
assert(drm_fd >= 0 && "DRM fd is not valid");
|
||||
|
||||
|
|
@ -41,14 +39,6 @@ IntelPerf::~IntelPerf()
|
|||
{
|
||||
close();
|
||||
|
||||
if (ralloc_ctx) {
|
||||
ralloc_free(ralloc_ctx);
|
||||
}
|
||||
|
||||
if (ralloc_cfg) {
|
||||
ralloc_free(ralloc_cfg);
|
||||
}
|
||||
|
||||
intel_perf_free(cfg);
|
||||
}
|
||||
|
||||
|
|
@ -83,7 +73,7 @@ bool IntelPerf::open(const uint64_t sampling_period_ns,
|
|||
{
|
||||
assert(!ctx && "Perf context should not be initialized at this point");
|
||||
|
||||
ctx = intel_perf_new_context(ralloc_ctx);
|
||||
ctx = intel_perf_new_context(NULL);
|
||||
intel_perf_init_context(ctx, cfg, nullptr, nullptr, nullptr, &devinfo, 0, drm_fd);
|
||||
|
||||
auto oa_exponent = get_oa_exponent(&devinfo, sampling_period_ns);
|
||||
|
|
|
|||
|
|
@ -33,9 +33,6 @@ class IntelPerf
|
|||
|
||||
int drm_fd = -1;
|
||||
|
||||
void *ralloc_ctx = nullptr;
|
||||
void *ralloc_cfg = nullptr;
|
||||
|
||||
struct intel_perf_context *ctx = nullptr;
|
||||
struct intel_perf_config *cfg = nullptr;
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue