summaryrefslogtreecommitdiff
path: root/drivers/gpu/drm/amd/include/kgd_kfd_interface.h
diff options
context:
space:
mode:
authorYong Zhao <Yong.Zhao@amd.com>2019-09-18 18:17:57 -0400
committerAlex Deucher <alexander.deucher@amd.com>2019-10-03 09:11:01 -0500
commitc637b36aeac11685a8258f9bcd667dcc06f6951a (patch)
treefb7927907e07fd4bef072eb10c33a1bbe132bd72 /drivers/gpu/drm/amd/include/kgd_kfd_interface.h
parent424b5442a2a67ba369839455c3b1fb1b00c6d861 (diff)
drm/amdkfd: Fix NULL pointer dereference for set_scratch_backing_va()
Currently this function pointer is missing for GFX10. Considering it is a void function since GFX9, fix it by checking the function pointer before dereferencing it. Signed-off-by: Yong Zhao <Yong.Zhao@amd.com> Reviewed-by: Alex Deucher <alexander.deucher@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
Diffstat (limited to 'drivers/gpu/drm/amd/include/kgd_kfd_interface.h')
-rw-r--r--drivers/gpu/drm/amd/include/kgd_kfd_interface.h5
1 files changed, 5 insertions, 0 deletions
diff --git a/drivers/gpu/drm/amd/include/kgd_kfd_interface.h b/drivers/gpu/drm/amd/include/kgd_kfd_interface.h
index 98b9533e672b..e4f7bba11a3a 100644
--- a/drivers/gpu/drm/amd/include/kgd_kfd_interface.h
+++ b/drivers/gpu/drm/amd/include/kgd_kfd_interface.h
@@ -298,8 +298,13 @@ struct kfd2kgd_calls {
struct kgd_dev *kgd,
uint8_t vmid);
+ /* No longer needed from GFXv9 onward. The scratch base address is
+ * passed to the shader by the CP. It's the user mode driver's
+ * responsibility.
+ */
void (*set_scratch_backing_va)(struct kgd_dev *kgd,
uint64_t va, uint32_t vmid);
+
int (*get_tile_config)(struct kgd_dev *kgd, struct tile_config *config);
void (*set_vm_context_page_table_base)(struct kgd_dev *kgd,