drm/amdkfd: Add SMI add event helper
authorPhilip Yang <Philip.Yang@amd.com>
Fri, 25 Feb 2022 17:33:51 +0000 (12:33 -0500)
committerAlex Deucher <alexander.deucher@amd.com>
Wed, 2 Mar 2022 23:40:05 +0000 (18:40 -0500)
commitd58b8a99cbb84c1eb3b3613d23c1a328695a9455
tree70647117a827841885c7e795e9df7069e5426964
parent38abd56bed580c98e4284a578380f5f70634a0fd
drm/amdkfd: Add SMI add event helper

To remove duplicate code, unify event message format and simplify new
event add in the following patches.

Use KFD_SMI_EVENT_MSG_SIZE to define msg size, the same size will be
used in user space to alloc the msg receive buffer.

Signed-off-by: Philip Yang <Philip.Yang@amd.com>
Reviewed-by: Felix Kuehling <Felix.Kuehling@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
drivers/gpu/drm/amd/amdkfd/kfd_smi_events.c
include/uapi/linux/kfd_ioctl.h