N V S Abhishek a3e0e896a0 tegra: nvmap: Fix nvmap_query_heap for multi numa node platform
In current implementation, when NvRmMemQueryHeapParams is
called and multiple numa nodes are online:
1. For iovmm carveout, numa_id is set to garbage value,
   and we are calling compute_memory_stat with it.
2. For gpu carveout, we are returning values for
   numa_id 0.
3. For other carveouts, we are returning params for the
   first matching entry in nvmap_dev->heaps[i].

Correct this behavior as follows:
Regardless of carveout type, return params for numa_id 0
when NvRmMemQueryHeapParams is called and multiple numa
nodes are online.

In long-term, we need to disable NvRmMemQueryHeapParams
when multiple numa nodes are online. Clients should use
NvRmMemQueryHeapParamsNuma instead.

Jira TMM-5970

Change-Id: Id49289e51eda187b1d676e5192583f320835c2f4
Signed-off-by: N V S Abhishek <nabhishek@nvidia.com>
Reviewed-on: https://git-master.nvidia.com/r/c/linux-nv-oot/+/3290730
Reviewed-by: Ketan Patil <ketanp@nvidia.com>
Reviewed-by: Pritesh Raithatha <praithatha@nvidia.com>
GVS: buildbot_gerritrpt <buildbot_gerritrpt@nvidia.com>
2025-07-24 10:19:14 +00:00
2022-12-07 23:57:14 -08:00
2025-07-24 10:19:10 +00:00
2025-07-24 10:19:10 +00:00
2024-02-24 05:24:07 -08:00
Description
No description provided
34 MiB