]> www.infradead.org Git - users/hch/misc.git/commitdiff
drm: Move drm_gem ioctl kerneldoc to uapi file
authorDavid Francis <David.Francis@amd.com>
Thu, 17 Jul 2025 14:35:56 +0000 (10:35 -0400)
committerChristian König <christian.koenig@amd.com>
Fri, 18 Jul 2025 07:18:48 +0000 (09:18 +0200)
The drm_gem ioctls were documented in internal file drm_gem.c
instead of uapi header drm.h. Move them there and change to
appropriate kerneldoc formatting.

Signed-off-by: David Francis <David.Francis@amd.com>
Reviewed-by: Simona Vetter <simona.vetter@ffwll.ch>
Signed-off-by: Christian König <christian.koenig@amd.com>
Link: https://lore.kernel.org/r/20250717143556.857893-3-David.Francis@amd.com
drivers/gpu/drm/drm_gem.c
include/uapi/drm/drm.h

index 480f91db2e159e1e5ad691544985443d57bfad61..9b621a94c2a9467eda195eaa6c61237a55e4f7e5 100644 (file)
@@ -821,14 +821,6 @@ long drm_gem_dma_resv_wait(struct drm_file *filep, u32 handle,
 }
 EXPORT_SYMBOL(drm_gem_dma_resv_wait);
 
-/**
- * drm_gem_close_ioctl - implementation of the GEM_CLOSE ioctl
- * @dev: drm_device
- * @data: ioctl data
- * @file_priv: drm file-private structure
- *
- * Releases the handle to an mm object.
- */
 int
 drm_gem_close_ioctl(struct drm_device *dev, void *data,
                    struct drm_file *file_priv)
@@ -844,17 +836,6 @@ drm_gem_close_ioctl(struct drm_device *dev, void *data,
        return ret;
 }
 
-/**
- * drm_gem_flink_ioctl - implementation of the GEM_FLINK ioctl
- * @dev: drm_device
- * @data: ioctl data
- * @file_priv: drm file-private structure
- *
- * Create a global name for an object, returning the name.
- *
- * Note that the name does not hold a reference; when the object
- * is freed, the name goes away.
- */
 int
 drm_gem_flink_ioctl(struct drm_device *dev, void *data,
                    struct drm_file *file_priv)
@@ -894,17 +875,6 @@ err:
        return ret;
 }
 
-/**
- * drm_gem_open_ioctl - implementation of the GEM_OPEN ioctl
- * @dev: drm_device
- * @data: ioctl data
- * @file_priv: drm file-private structure
- *
- * Open an object using the global name, returning a handle and the size.
- *
- * This handle (of course) holds a reference to the object, so the object
- * will not go away until the handle is deleted.
- */
 int
 drm_gem_open_ioctl(struct drm_device *dev, void *data,
                   struct drm_file *file_priv)
index 7fa123e11c3f559a055b48f5b0a3e08ccb391b2b..3cd5cf15e3c9ce220aa3171ec1342ba7ef61d273 100644 (file)
@@ -597,31 +597,47 @@ struct drm_set_version {
        int drm_dd_minor;
 };
 
-/* DRM_IOCTL_GEM_CLOSE ioctl argument type */
+/**
+ * struct drm_gem_close - Argument for &DRM_IOCTL_GEM_CLOSE ioctl.
+ * @handle: Handle of the object to be closed.
+ * @pad: Padding.
+ *
+ * Releases the handle to an mm object.
+ */
 struct drm_gem_close {
-       /** Handle of the object to be closed. */
        __u32 handle;
        __u32 pad;
 };
 
-/* DRM_IOCTL_GEM_FLINK ioctl argument type */
+/**
+ * struct drm_gem_flink - Argument for &DRM_IOCTL_GEM_FLINK ioctl.
+ * @handle: Handle for the object being named.
+ * @name: Returned global name.
+ *
+ * Create a global name for an object, returning the name.
+ *
+ * Note that the name does not hold a reference; when the object
+ * is freed, the name goes away.
+ */
 struct drm_gem_flink {
-       /** Handle for the object being named */
        __u32 handle;
-
-       /** Returned global name */
        __u32 name;
 };
 
-/* DRM_IOCTL_GEM_OPEN ioctl argument type */
+/**
+ * struct drm_gem_open - Argument for &DRM_IOCTL_GEM_OPEN ioctl.
+ * @name: Name of object being opened.
+ * @handle: Returned handle for the object.
+ * @size: Returned size of the object
+ *
+ * Open an object using the global name, returning a handle and the size.
+ *
+ * This handle (of course) holds a reference to the object, so the object
+ * will not go away until the handle is deleted.
+ */
 struct drm_gem_open {
-       /** Name of object being opened */
        __u32 name;
-
-       /** Returned handle for the object */
        __u32 handle;
-
-       /** Returned size of the object */
        __u64 size;
 };