History

drm/amdkfd: allow debug subscription to lds violations on gfx 1250

GFX 1250 allows the debugger to subcribe to LDS out-of-range read/write memory violations. Bump IOCTL minor version and flag KFD capabilities for enablement hint.

Jonathan Kim committed 1 year ago

Commit e83f63d1 parent bf2951e4 files · +16 −2Browse files

Showing the changes to include/uapi (2 of 4 files). Show all

Unified · Split

2 files
  1. include/uapi/linux/kfd_ioctl.h +3 −1
  2. include/uapi/linux/kfd_sysfs.h +2 −1
include/uapi/linux/kfd_ioctl.h+3−1
@@ -46,9 +46,10 @@ · 45 unmodified lines
46 * - 1.18 - Rename pad in set_memory_policy_args to misc_process_flag46 * - 1.18 - Rename pad in set_memory_policy_args to misc_process_flag
47 * - 1.19 - Add a new ioctl to craete secondary kfd processes47 * - 1.19 - Add a new ioctl to craete secondary kfd processes
48 * - 1.20 - Trap handler support for expert scheduling mode available48 * - 1.20 - Trap handler support for expert scheduling mode available
49 * - 1.21 - Debugger support to subscribe to LDS out-of-address exceptions
49 */50 */
50#define KFD_IOCTL_MAJOR_VERSION 151#define KFD_IOCTL_MAJOR_VERSION 1
51#define KFD_IOCTL_MINOR_VERSION 2052#define KFD_IOCTL_MINOR_VERSION 21
52 53
53struct kfd_ioctl_get_version_args {54struct kfd_ioctl_get_version_args {
54 __u32 major_version; /* from KFD */55 __u32 major_version; /* from KFD */
@@ -947,6 +948,7 @@ enum kfd_dbg_trap_address_watch_mode { · 892 unmodified lines
947enum kfd_dbg_trap_flags {948enum kfd_dbg_trap_flags {
948 KFD_DBG_TRAP_FLAG_SINGLE_MEM_OP = 1,949 KFD_DBG_TRAP_FLAG_SINGLE_MEM_OP = 1,
949 KFD_DBG_TRAP_FLAG_SINGLE_ALU_OP = 2,950 KFD_DBG_TRAP_FLAG_SINGLE_ALU_OP = 2,
951 KFD_DBG_TRAP_FLAG_LDS_OUT_OF_ADDR_RANGE = 4
950};952};
951 953
952/* Trap exceptions */954/* Trap exceptions */
include/uapi/linux/kfd_sysfs.h+2−1
@@ -64,7 +64,8 @@ · 63 unmodified lines
64#define HSA_CAP_RESERVED 0x000f800064#define HSA_CAP_RESERVED 0x000f8000
65 65
66#define HSA_CAP2_PER_SDMA_QUEUE_RESET_SUPPORTED 0x0000000166#define HSA_CAP2_PER_SDMA_QUEUE_RESET_SUPPORTED 0x00000001
67#define HSA_CAP2_RESERVED 0xfffffffe67#define HSA_CAP2_TRAP_DEBUG_LDS_OUT_OF_ADDR_RANGE_SUPPORTED 0x00000002
68#define HSA_CAP2_RESERVED 0xfffffffc
68 69
69/* debug_prop bits in node properties */70/* debug_prop bits in node properties */
70#define HSA_DBG_WATCH_ADDR_MASK_LO_BIT_MASK 0x0000000f71#define HSA_DBG_WATCH_ADDR_MASK_LO_BIT_MASK 0x0000000f