diff options
author | Philip Yang <Philip.Yang@amd.com> | 2024-06-26 21:52:28 +0300 |
---|---|---|
committer | Alex Deucher <alexander.deucher@amd.com> | 2024-07-24 21:45:58 +0300 |
commit | 517fff221c1e6b8a8db69e7a440116caee120ff5 (patch) | |
tree | f8ed69f364866806bb6b3b90fe6605e2f34e4de0 /drivers/gpu/drm/amd/amdkfd/kfd_topology.c | |
parent | 47c0388b0589cb481c294dcb857d25a214c46eb3 (diff) | |
download | linux-517fff221c1e6b8a8db69e7a440116caee120ff5.tar.xz |
drm/amdkfd: Store queue cwsr area size to node properties
Use the queue eop buffer size, cwsr area size, ctl stack size
calculation from Thunk, store the value to KFD node properties.
Those will be used to validate queue eop buffer size, cwsr area size,
ctl stack size when creating KFD user compute queue.
Those will be exposed to user space via sysfs KFD node properties, to
remove the duplicate calculation code from Thunk.
Signed-off-by: Philip Yang <Philip.Yang@amd.com>
Reviewed-by: Felix Kuehling <felix.kuehling@amd.com>
Acked-by: Christian König <christian.koenig@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
Diffstat (limited to 'drivers/gpu/drm/amd/amdkfd/kfd_topology.c')
-rw-r--r-- | drivers/gpu/drm/amd/amdkfd/kfd_topology.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/drivers/gpu/drm/amd/amdkfd/kfd_topology.c b/drivers/gpu/drm/amd/amdkfd/kfd_topology.c index 6f89b06f89d3..a9b3eda65a2c 100644 --- a/drivers/gpu/drm/amd/amdkfd/kfd_topology.c +++ b/drivers/gpu/drm/amd/amdkfd/kfd_topology.c @@ -2120,6 +2120,8 @@ int kfd_topology_add_device(struct kfd_node *gpu) dev->gpu->adev->gmc.xgmi.connected_to_cpu) dev->node_props.capability |= HSA_CAP_FLAGS_COHERENTHOSTACCESS; + kfd_queue_ctx_save_restore_size(dev); + kfd_debug_print_topology(); kfd_notify_gpu_change(gpu_id, 1); |