STRUCT DRM_I915_QUERY_PERF_CONFIG(9)

πŸ“¦ version 7.3.1, in nixpkgs unstable

πŸ’… struct drm_i915_query_perf_config(9) β€” the Kernel API Manual, bestie edition

okay so real talk, this is a page out of the Kernel API Manual and it's all about struct drm_i915_query_perf_config. She's a vibe, she's a struct, and she's here to tell you what the kernel hands back when you go asking about performance configs. Buckle up πŸŽ€


✨ NAME ✨

struct drm_i915_query_perf_config β€” literally the struct, that's the whole name, the manpage didn't even give us a description line and honestly? iconic minimalism πŸ’…


πŸ¦‹ SYNOPSIS πŸ¦‹

struct drm_i915_query_perf_config {
    union {
      __u64 n_configs;
      __u64 config;
      char uuid[36];
    };
    __u32 flags;
    __u8 data[];
};

look at her. a union, a flags field, and a lil flexible array at the end. she's got range ✨


🌸 Members 🌸

  • {unnamed_union} β€” she's anonymous, no name, no notes, we respect her privacy πŸ™ˆ
  • n_configs β€” when drm_i915_query_item.flags == DRM_I915_QUERY_PERF_CONFIG_LIST, i915 sets this field to the number of configurations available. basically the count, the headcount, the how-many-are-there πŸ’…
  • config β€” when drm_i915_query_item.flags == DRM_I915_QUERY_PERF_CONFIG_DATA_FOR_ID, i915 will use the value in this field as the configuration identifier to decide what data to write into config_ptr. so she's the ID, the ✨ main character identifier ✨
  • uuid β€” when drm_i915_query_item.flags == DRM_I915_QUERY_PERF_CONFIG_DATA_FOR_UUID, i915 will use the value in this field as the configuration identifier to decide what data to write into config_ptr.

String formatted like "08x-04x-04x-04x-012x" β€” yes bestie, that exact format, copy it character for character, no freestyling 🫢

  • flags β€” unused for now. must be cleared to zero. that's it. that's the whole job. zero it out and move on 😭
  • data β€” when drm_i915_query_item.flags == DRM_I915_QUERY_PERF_CONFIG_LIST, i915 will write an array of __u64 of configuration identifiers.

When drm_i915_query_item.flags == DRM_I915_QUERY_PERF_CONFIG_DATA, i915 will write a struct drm_i915_perf_oa_config. If the following fields of struct drm_i915_perf_oa_config are not set to 0, i915 will write into the associated pointers the values of submitted when the configuration was created:

  • drm_i915_perf_oa_config.n_mux_regs
  • drm_i915_perf_oa_config.n_boolean_regs
  • drm_i915_perf_oa_config.n_flex_regs

so like… if you leave those three at 0, nothing gets pointed at. if you don't, i915 fills in the pointers with the values that were submitted when the config was created. the way that works is lowkey elegant ngl πŸ”₯


πŸ‘‘ Description πŸ‘‘

Data written by the kernel with query DRM_I915_QUERY_PERF_CONFIG and DRM_I915_QUERY_GEOMETRY_SUBSLICES.

that's literally it. the kernel writes the data, you receive the data. slay πŸ’–


🌈 SEE ALSO 🌈

the whole group chat, fr fr β€” go read these next:

  • Kernel file ./tools/perf/trace/beauty/include/uapi/drm/i915_drm.h
  • uevents generated by i915 on its device node(9)
  • struct i915_user_extension(9)
  • enum drm_i915_gem_engine_class(9)
  • struct i915_engine_class_instance(9)
  • perf_events exposed by i915 through /sys/bus/event_sources/drivers/i915(9)
  • struct drm_i915_getparam(9)
  • drm_i915_getparam_t(9)
  • struct drm_i915_gem_mmap_offset(9)
  • struct drm_i915_gem_set_domain(9)
  • struct drm_i915_gem_exec_fence(9)
  • struct drm_i915_gem_execbuffer_ext_timeline_fences(9)
  • struct drm_i915_gem_execbuffer2(9)
  • struct drm_i915_gem_caching(9)
  • struct drm_i915_gem_context_create_ext(9)
  • struct drm_i915_gem_context_param(9)
  • Virtual Engine uAPI(9)
  • struct i915_context_engines_parallel_submit(9)
  • Context Engine Map uAPI(9)
  • struct drm_i915_gem_context_create_ext_setparam(9)
  • struct drm_i915_gem_vm_control(9)
  • struct drm_i915_gem_userptr(9)
  • struct drm_i915_perf_oa_config(9)
  • struct drm_i915_query_item(9)
  • struct drm_i915_query(9)
  • struct drm_i915_query_topology_info(9)
  • Engine Discovery uAPI(9)
  • struct drm_i915_engine_info(9)
  • struct drm_i915_query_engine_info(9)
  • enum drm_i915_gem_memory_class(9)
  • struct drm_i915_gem_memory_class_instance(9)
  • struct drm_i915_memory_region_info(9)
  • struct drm_i915_query_memory_regions(9)
  • struct drm_i915_query_guc_submission_version(9)
  • GuC HWCONFIG blob uAPI(9)
  • struct drm_i915_gem_create_ext(9)
  • struct drm_i915_gem_create_ext_memory_regions(9)
  • struct drm_i915_gem_create_ext_protected_content(9)
  • struct drm_i915_gem_create_ext_set_pat(9)

bestie note: that flags field? clear it to zero. i mean it. that's not a suggestion, that's the spec πŸ’€

and that's the page!! sourced from ./tools/perf/trace/beauty/incl..., dated October 2026, and it's the struct drm_..._perf_config(9) moment we all deserved. mwah πŸ’‹βœ¨ go query something cute today πŸŽ€

πŸ“¦ where this page comes from