drm/amdkfd: Add thermal throttling SMI event

Add support for reporting thermal throttling events through SMI.
Also, add a counter to count the number of throttling interrupts
observed and report the count in the SMI event message.

Signed-off-by: Mukul Joshi <mukul.joshi@amd.com>
Reviewed-by: Felix Kuehling <Felix.Kuehling@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
This commit is contained in:
Mukul Joshi
2020-07-23 23:09:57 -04:00
committed by Alex Deucher
parent df9c8d1aa2
commit 2c2b0d880f
10 changed files with 74 additions and 18 deletions

View File

@@ -450,7 +450,8 @@ struct kfd_ioctl_import_dmabuf_args {
* KFD SMI(System Management Interface) events
*/
/* Event type (defined by bitmask) */
#define KFD_SMI_EVENT_VMFAULT 0x0000000000000001
#define KFD_SMI_EVENT_VMFAULT 0x0000000000000001
#define KFD_SMI_EVENT_THERMAL_THROTTLE 0x0000000000000002
struct kfd_ioctl_smi_events_args {
__u32 gpuid; /* to KFD */