mirror of
git://nv-tegra.nvidia.com/linux-nvgpu.git
synced 2025-12-22 17:36:20 +03:00
Hardware HWPM system should be reset when first reservation is made either for HWPM or PMA_STREAM resource. Support this with below changes - Add hwpm_refcount counter to track HWPM and PMA_STREAM resource reservation count - Increment counter on every HWPM/PMA resource reservation - Decrement counter on every resource reservation release - Reset HWPM system in MC and disable perf unit SLCG on first refcount increment - Reset HWPM system in MC and re-enable perf unit SLCG after last refcount decrement - Add nvgpu_cg_slcg_perf_load_enable() to manage perf unit SLCG Bug 2510974 Jira NVGPU-5360 Change-Id: I20d2927947c3e4d8073cd3131b7733791e9c9346 Signed-off-by: Deepak Nibade <dnibade@nvidia.com> Reviewed-on: https://git-master.nvidia.com/r/c/linux-nvgpu/+/2399594 Tested-by: mobile promotions <svcmobile_promotions@nvidia.com> Reviewed-by: mobile promotions <svcmobile_promotions@nvidia.com>