STRUCT KFD_IOCTL_DBG_TRAP_SEND_RUNTIME_EVENT_ARGS(9)

πŸ“¦ version 7.3.1, in nixpkgs unstable

πŸ’… struct kfd_ioctl_dbg_trap_send_runtime_event_args(9) πŸ’…

okay so bestie, welcome to the Kernel API Manual ✨ β€” this one's a struct page, and it's lowkey a whole vibe. It's the args struct for KFD_IOC_DBG_TRAP_SEND_RUNTIME_EVENT, and yes, she's got main character energy πŸŽ€


🌸 NAME 🌸

struct kfd_ioctl_dbg_trap_send_runtime_event_args β€” literally the arguments for KFD_IOC_DBG_TRAP_SEND_RUNTIME_EVENT. that's the whole name, no notes πŸ’…


✨ SYNOPSIS ✨

struct kfd_ioctl_dbg_trap_send_runtime_event_args {
    __u64 exception_mask;
    __u32 gpu_id;
    __u32 queue_id;
 };

like, three fields. short king 🫢


πŸŽ€ Members πŸŽ€

  • exception_mask β€” (IN) β€” the exceptions you wanna raise to runtime, packed into a mask πŸ›
  • gpu_id β€” (IN) β€” the target device id, iykyk which GPU you're talking to πŸ”₯
  • queue_id β€” (IN) β€” the target queue id, so she knows exactly which queue is the moment ✨

πŸ’– Description πŸ’–

So what does she do? She raises exceptions to runtime πŸŽ€ periodt.

Generic errors apply (see kfd_dbg_trap_operations). Return: 0 on SUCCESS πŸ’–

  • ENODEV if gpu_id not found 😭. And listen β€” if exception_mask contains EC_PROCESS_RUNTIME, that unblocks the pending AMDKFD_IOC_RUNTIME_ENABLE call β€” see kfd_ioctl_runtime_enable_args. All the other exceptions get raised to runtime through err_payload_addr β€” see kfd_context_save_area_header πŸ‘‘
ngl, the EC_PROCESS_RUNTIME path is the little special-case that ate πŸ’€ don't sleep on it.

πŸ¦‹ SEE ALSO πŸ¦‹

Kernel file ./include/uapi/linux/kfd_ioctl.h struct β€” and the whole friend group πŸ’œ:

  • struct kfd_ioctl_criu_args(9)
  • enum kfd_ioctl_svm_op(9)
  • enum kfd_ioctl_svm_attr_type(9)
  • struct kfd_ioctl_svm_attribute(9)
  • struct kfd_ioctl_svm_args(9)
  • struct kfd_ioctl_set_xnack_mode_args(9)
  • struct kfd_ioctl_runtime_enable_args(9)
  • struct kfd_ioctl_dbg_trap_enable_args(9)
  • struct kfd_ioctl_dbg_trap_set_exceptions_enabled_args(9)
  • struct kfd_ioctl_dbg_trap_set_wave_launch_override_args(9)
  • struct kfd_ioctl_dbg_trap_set_wave_launch_mode_args(9)
  • struct kfd_ioctl_dbg_trap_suspend_queues_args(9)
  • struct kfd_ioctl_dbg_trap_resume_queues_args(9)
  • struct kfd_ioctl_dbg_trap_set_node_address_watch_args(9)
  • struct kfd_ioctl_dbg_trap_clear_node_address_watch_args(9)
  • struct kfd_ioctl_dbg_trap_set_flags_args(9)
  • struct kfd_ioctl_dbg_trap_query_debug_event_args(9)
  • struct kfd_ioctl_dbg_trap_query_exception_info_args(9)
  • struct kfd_ioctl_dbg_trap_queue_snapshot_args(9)
  • struct kfd_ioctl_dbg_trap_device_snapshot_args(9)
  • struct kfd_ioctl_dbg_trap_args(9)
  • struct kfd_ioctl_pmc_settings(9)

and that's the page, bestie 🫢 shoutout to ./include/uapi/linux for the source, October 2026 for the date, and struct kfd_...e_event_args(9) for the footer β€” slay, iconic, no cap πŸŒˆβœ¨πŸ’…

πŸ“¦ where this page comes from