History

drm/xe/uapi: Document use of size in drm_xe_device_query

Document the behavior of the driver for IOCTL DRM_IOCTL_XE_DEVICE_QUERY depending on the size value provided in struct drm_xe_device_query.

Francois Dugast committed 2 years ago

Commit ff6c6bc1 parent 4efaadd1 file · +9 −3Browse files

Showing the changes to include/uapi (1 of 1 file). Show all

Unified · Split

include/uapi/drm/xe_drm.h+9−3
@@ -467,9 +467,15 @@ struct drm_xe_query_topology_mask { · 466 unmodified lines
467 * struct drm_xe_device_query - Input of &DRM_IOCTL_XE_DEVICE_QUERY - main467 * struct drm_xe_device_query - Input of &DRM_IOCTL_XE_DEVICE_QUERY - main
468 * structure to query device information468 * structure to query device information
469 *469 *
470 * If size is set to 0, the driver fills it with the required size for the470 * The user selects the type of data to query among DRM_XE_DEVICE_QUERY_*
471 * requested type of data to query. If size is equal to the required size,471 * and sets the value in the query member. This determines the type of
472 * the queried information is copied into data.472 * the structure provided by the driver in data, among struct drm_xe_query_*.
473 *
474 * If size is set to 0, the driver fills it with the required size for
475 * the requested type of data to query. If size is equal to the required
476 * size, the queried information is copied into data. If size is set to
477 * a value different from 0 and different from the required size, the
478 * IOCTL call returns -EINVAL.
473 *479 *
474 * For example the following code snippet allows retrieving and printing480 * For example the following code snippet allows retrieving and printing
475 * information about the device engines with DRM_XE_DEVICE_QUERY_ENGINES:481 * information about the device engines with DRM_XE_DEVICE_QUERY_ENGINES:

Keyboard shortcuts

General

Show keyboard shortcuts
?
Focus the current search
/

Issues and pull requests

Open filters
f

Issues, pull requests and Inbox

Select next item
j↓
Select previous item
k↑
Open selected item
Enter
Dismiss filters or clear selection
Esc

Repository code

Go to file
t