History

drm/xe/uapi: Add a comment to each struct

Add a comment to each struct to complete documentation, ensure all struct appear in the kernel doc, and bind structs to IOCTLs.

Francois Dugast committed 2 years ago

Commit b0e47221 parent d3d76731 file · +40 −3Browse files

Unified · Split

include/uapi/drm/xe_drm.h+40−3
@@ -464,7 +464,8 @@ struct drm_xe_query_topology_mask { · 463 unmodified lines
464464 };
465465
466466 /**
467− * struct drm_xe_device_query - main structure to query device information
467+ * struct drm_xe_device_query - Input of &DRM_IOCTL_XE_DEVICE_QUERY - main
468+ * structure to query device information
468469 *
469470 * If size is set to 0, the driver fills it with the required size for the
470471 * requested type of data to query. If size is equal to the required size,
@@ -526,6 +527,10 @@ struct drm_xe_device_query { · 55 unmodified lines
526527 __u64 reserved[2];
527528 };
528529
530+/**
531+ * struct drm_xe_gem_create - Input of &DRM_IOCTL_XE_GEM_CREATE - A structure for
532+ * gem creation
533+ */
529534 struct drm_xe_gem_create {
530535 /** @extensions: Pointer to the first extension struct, if any */
531536 __u64 extensions;
@@ -604,6 +609,9 @@ struct drm_xe_gem_create { · 72 unmodified lines
604609 __u64 reserved[2];
605610 };
606611
612+/**
613+ * struct drm_xe_gem_mmap_offset - Input of &DRM_IOCTL_XE_GEM_MMAP_OFFSET
614+ */
607615 struct drm_xe_gem_mmap_offset {
608616 /** @extensions: Pointer to the first extension struct, if any */
609617 __u64 extensions;
@@ -621,7 +629,9 @@ struct drm_xe_gem_mmap_offset { · 11 unmodified lines
621629 __u64 reserved[2];
622630 };
623631
624−/** struct drm_xe_ext_set_property - XE set property extension */
632+/**
633+ * struct drm_xe_ext_set_property - XE set property extension
634+ */
625635 struct drm_xe_ext_set_property {
626636 /** @base: base user extension */
627637 struct drm_xe_user_extension base;
@@ -639,6 +649,9 @@ struct drm_xe_ext_set_property { · 11 unmodified lines
639649 __u64 reserved[2];
640650 };
641651
652+/**
653+ * struct drm_xe_vm_create - Input of &DRM_IOCTL_XE_VM_CREATE
654+ */
642655 struct drm_xe_vm_create {
643656 /** @extensions: Pointer to the first extension struct, if any */
644657 __u64 extensions;
@@ -677,6 +690,9 @@ struct drm_xe_vm_create { · 32 unmodified lines
677690 __u64 reserved[2];
678691 };
679692
693+/**
694+ * struct drm_xe_vm_destroy - Input of &DRM_IOCTL_XE_VM_DESTROY
695+ */
680696 struct drm_xe_vm_destroy {
681697 /** @vm_id: VM ID */
682698 __u32 vm_id;
@@ -688,6 +704,9 @@ struct drm_xe_vm_destroy { · 5 unmodified lines
688704 __u64 reserved[2];
689705 };
690706
707+/**
708+ * struct drm_xe_vm_bind_op
709+ */
691710 struct drm_xe_vm_bind_op {
692711 /** @extensions: Pointer to the first extension struct, if any */
693712 __u64 extensions;
@@ -804,6 +823,9 @@ struct drm_xe_vm_bind_op { · 110 unmodified lines
804823 __u64 reserved[3];
805824 };
806825
826+/**
827+ * struct drm_xe_vm_bind - Input of &DRM_IOCTL_XE_VM_BIND
828+ */
807829 struct drm_xe_vm_bind {
808830 /** @extensions: Pointer to the first extension struct, if any */
809831 __u64 extensions;
@@ -862,6 +884,9 @@ struct drm_xe_vm_bind { · 52 unmodified lines
862884 /* Monitor 64MB contiguous region with 2M sub-granularity */
863885 #define DRM_XE_ACC_GRANULARITY_64M 3
864886
887+/**
888+ * struct drm_xe_exec_queue_create - Input of &DRM_IOCTL_XE_EXEC_QUEUE_CREATE
889+ */
865890 struct drm_xe_exec_queue_create {
866891 #define DRM_XE_EXEC_QUEUE_EXTENSION_SET_PROPERTY 0
867892 #define DRM_XE_EXEC_QUEUE_SET_PROPERTY_PRIORITY 0
@@ -904,6 +929,9 @@ struct drm_xe_exec_queue_create { · 36 unmodified lines
904929 __u64 reserved[2];
905930 };
906931
932+/**
933+ * struct drm_xe_exec_queue_get_property - Input of &DRM_IOCTL_XE_EXEC_QUEUE_GET_PROPERTY
934+ */
907935 struct drm_xe_exec_queue_get_property {
908936 /** @extensions: Pointer to the first extension struct, if any */
909937 __u64 extensions;
@@ -922,6 +950,9 @@ struct drm_xe_exec_queue_get_property { · 12 unmodified lines
922950 __u64 reserved[2];
923951 };
924952
953+/**
954+ * struct drm_xe_exec_queue_destroy - Input of &DRM_IOCTL_XE_EXEC_QUEUE_DESTROY
955+ */
925956 struct drm_xe_exec_queue_destroy {
926957 /** @exec_queue_id: Exec queue ID */
927958 __u32 exec_queue_id;
@@ -933,6 +964,9 @@ struct drm_xe_exec_queue_destroy { · 5 unmodified lines
933964 __u64 reserved[2];
934965 };
935966
967+/**
968+ * struct drm_xe_sync
969+ */
936970 struct drm_xe_sync {
937971 /** @extensions: Pointer to the first extension struct, if any */
938972 __u64 extensions;
@@ -967,6 +1001,9 @@ struct drm_xe_sync { · 28 unmodified lines
9671001 __u64 reserved[2];
9681002 };
9691003
1004+/**
1005+ * struct drm_xe_exec - Input of &DRM_IOCTL_XE_EXEC
1006+ */
9701007 struct drm_xe_exec {
9711008 /** @extensions: Pointer to the first extension struct, if any */
9721009 __u64 extensions;
@@ -1000,7 +1037,7 @@ struct drm_xe_exec { · 27 unmodified lines
10001037 };
10011038
10021039 /**
1003− * struct drm_xe_wait_user_fence - wait user fence
1040+ * struct drm_xe_wait_user_fence - Input of &DRM_IOCTL_XE_WAIT_USER_FENCE
10041041 *
10051042 * Wait on user fence, XE will wake-up on every HW engine interrupt in the
10061043 * instances list and check if user fence is complete::