freedreno/pps: Don't re-init perfcntrs
init_perfcntr() can be called multiple times. We don't want to regenerate the list of counters (and overwrite/leak various other things), so just bail if we've already initialized. Signed-off-by: Rob Clark <robdclark@chromium.org> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/28058>
This commit is contained in:
@@ -441,6 +441,9 @@ FreedrenoDriver::init_perfcnt()
|
||||
{
|
||||
uint64_t val;
|
||||
|
||||
if (dev)
|
||||
return true;
|
||||
|
||||
dev = fd_device_new(drm_device.fd);
|
||||
pipe = fd_pipe_new2(dev, FD_PIPE_3D, 0);
|
||||
dev_id = fd_pipe_dev_id(pipe);
|
||||
|
||||
Reference in New Issue
Block a user