lib/intel_device_info: get the xe .graphics_rel from GMD_ID
Get series with b4
b4 am [email protected]Versions newest first · linked by author and title
- v14 Latest4 patches 7 repliesIn review
- v134 patches 2 repliesSuperseded
- v124 patches 0 repliesSuperseded
Earlier versions · 10
| Version | Posted | Patches | Replies | Status |
|---|---|---|---|---|
| v11 | 4 patches | 0 replies | Superseded | |
| v10 | 2 patches | 6 replies | Superseded | |
| v9 | 2 patches | 2 replies | Superseded | |
| v8 | 2 patches | 14 replies | Superseded | |
| v7 | 2 patches | 7 replies | Superseded | |
| v6 | 2 patches | 0 replies | Superseded | |
| v5 | 2 patches | 0 replies | Superseded | |
| v4 | 2 patches | 0 replies | Superseded | |
| v3 | 6 patches | 8 replies | Superseded | |
| v2 | 6 patches | 0 replies | Superseded |
V2 from the cover letter
- set the graphics version info in xe_device_get() don't copy
the whole struct of the intel_device_info
- update the graphics_rel when the info is already in the cache
Patches in v14 No applies recorded yet
| # | Subject and files | Size | Replies | Applied |
|---|---|---|---|---|
| 1/4 | lib/igt_core: add igt_destructor helper macrolib/ | +12 | 1 reply | |
| 2/4 | lib/intel_device_info: make device info cache process-widelib/ lib/ | +101 | 1 reply | |
| 3/4 | lib/intel_device_info: allow xe_query to override graphics versionlib/ lib/ lib/ | +61 | 1 reply | |
| 4/4 | lib/intel_device_info: remove the graphics_rel from xe2+ deviceslib/ | +0 | 3 replies |
Reviews trailers per patch
All 4 patches have a Reviewed-by or Acked-by.
| Patch | Zbigniew Kempczyński |
|---|---|
| 1/4 | R-b |
| 2/4 | R-b |
| 3/4 | R-b |
| 4/4 | R-b |
Trailers given in replies are filled; those carried in the patches from earlier versions are outlined with dashes.
Cover letter [PATCH i-g-t v14 0/4] lib/intel_device_info: get the xe .graphics_rel from GMD_ID
This series enables IGT to retrieve the accurate IP minor version (graphics_rel) at runtime for xe platforms with GMD_ID support, instead of relying on hardcoded values in the PCI device table.
Background:
-----------
Current IGT uses static PCI device tables with hardcoded graphics_rel values. For Xe2+ platforms, devices sharing the same PCI ID may have different graphics_rel (minor version) values.
The kernel's GMD_ID query provides accurate runtime IP version information (ip_ver_major.ip_ver_minor) which should be used for platform-specific workarounds and feature detection.
Limitation:
-----------
The device info cache is keyed by PCI device ID. A system with multiple GPUs sharing a device ID but reporting different IP versions is not supported; the last probed device wins. This is considered unlikely in practice, while the hardcoded devid -> IP version mapping fixed here affects every such device.
Benefits:
---------
- Accurate IP version for platform-specific workarounds
- Proper feature detection for hardware variants
- Unified device info API between i915 and xe drivers
- No changes needed to existing test code
V2:
- set the graphics version info in xe_device_get() don't copy
the whole struct of the intel_device_info
- update the graphics_rel when the info is already in the cache
V3:
- Optimize the coding style
V4:
- add braces around the else statement body
V5:
- add new struct xe_device_ipver to hold the ipver info
- separate cache map to eliminate collision (Roper, Matthew D)
- changed function name to xe_ipver_cache_lookup() to avoid
confusion (Roper, Matthew D)
V6:
- optimize the coding style. (Summers, Stuart)
V7:
- rebased to latest mainline
V8:
- Reworked caching in intel_get_device_info(): replace the per-thread single-entry cache with a process-wide cache keyed by devid (igt_map + pthread mutex), with automatic init/fini via igt_constructor/igt_destructor.
- Dropped the xe_ipver_cache_lookup() weak-symbol plumbing and the separate xe_query-side ipver cache. Instead, xe_query updates the cached intel_device_info directly via xe_dev_update_graphics_ver() when MAIN GT exposes ip_ver_{major,minor} via GMD_ID.
V9:
- make xe_dev_update_graphics_ver() return error and guard NULL cache.
- assert in xe query path to avoid silently ignoring update failures.
V10:
- rebased to latest master.
- statically initialize the cache mutex and create the map lazily
instead of relying on igt_constructor ordering.
- fall back to the static table entry instead of intel_generic_info
when a cache entry cannot be allocated.
- return -ENOENT from xe_dev_update_graphics_ver() and fix coding style.
- document the devid keying and the lockless readers.
- also drop graphics_rel from WCL and NVL-P.
- reword commit messages.
V11:
- rebase to latest master.
- report allocation, map creation, and map insertion failures with fprintf() and exit(EXIT_FAILURE), rather than returning an unmodifiable static entry.
- release the cache mutex before reporting an insertion failure.
Xin Wang (4):
lib/igt_core: add igt_destructor helper macro lib/intel_device_info: make device info cache process-wide lib/intel_device_info: allow xe_query to override graphics version lib/intel_device_info: remove the graphics_rel from xe2+ devices
lib/igt_core.h | 12 +++ lib/intel_chipset.h | 1 + lib/intel_device_info.c | 164 +++++++++++++++++++++++++++++++++++----- lib/meson.build | 1 + lib/xe/xe_query.c | 17 +++++ 5 files changed, 174 insertions(+), 21 deletions(-)
Signature · 1 line
2.43.0