[PATCH 0/2] VF: Avoid reading inaccessible RING_TIMESTAMP

Marcin Bernatowicz marcin.bernatowicz at linux.intel.com
Wed Feb 5 19:16:42 UTC 2025


RING_TIMESTAMP registers are not available for VF (Virtual Function)
drivers. Return -EOPNOTSUPP when the DRM_XE_DEVICE_QUERY_ENGINE_CYCLES
ioctl is invoked on a VF device.

RING_TIMESTAMP registers populate drm-total-cycles-* fdinfo keys.  
Without drm-total-cycles-*, other keys provide little value. Skip all  
optional "run_ticks" keys if unable to read the timestamp.

v2:
  - Drop "drm/xe/vf: Return error code from xe_hw_engine_read_timestamp()"
    patch. (Michal)
  - Skip "run_ticks" keys if unable to read timestamp. (Lucas)

Cc: Lucas De Marchi <lucas.demarchi at intel.com>
Cc: Michal Wajdeczko <michal.wajdeczko at intel.com>
Cc: Michał Winiarski <michal.winiarski at intel.com>
Cc: Umesh Nerlige Ramappa <umesh.nerlige.ramappa at intel.com>

Marcin Bernatowicz (2):
  drm/xe/vf: Return EOPNOTSUPP for DRM_XE_DEVICE_QUERY_ENGINE_CYCLES if
    VF
  drm/xe/client: Skip show_run_ticks if unable to read timestamp

 drivers/gpu/drm/xe/xe_drm_client.c | 8 ++++++++
 drivers/gpu/drm/xe/xe_query.c      | 3 +++
 2 files changed, 11 insertions(+)

-- 
2.31.1



More information about the Intel-xe mailing list