mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
* [PATCH] virtio: Add missing kerneldoc for virtio_dma_buf_attach
@ 2025-07-04  7:20 jiang.peng9
  2025-07-04 15:19 ` Krzysztof Kozlowski
  0 siblings, 1 reply; 3+ messages in thread
From: jiang.peng9 @ 2025-07-04  7:20 UTC (permalink / raw)
  To: jasowang, xuanzhuo
  Cc: mst, eperezma, sumit.semwal, christian.koenig, virtualization,
	linux-kernel, linux-media, dri-devel, linaro-mm-sig, xu.xin16,
	yang.yang29

From: Peng Jiang <jiang.peng9@zte.com.cn>

Add kerneldoc for 'virtio_dma_buf_attach' function to fix W=1 warnings:

drivers/virtio/virtio_dma_buf.c:41 function parameter 'dma_buf' not described in 'virtio_dma_buf_attach'
drivers/virtio/virtio_dma_buf.c:41 function parameter 'attach' not described in 'virtio_dma_buf_attach'

Signed-off-by: Peng Jiang <jiang.peng9@zte.com.cn>
---
 drivers/virtio/virtio_dma_buf.c | 11 ++++++++++-
 1 file changed, 10 insertions(+), 1 deletion(-)

diff --git a/drivers/virtio/virtio_dma_buf.c b/drivers/virtio/virtio_dma_buf.c
index 3fe1d03b0645..18d261ba5197 100644
--- a/drivers/virtio/virtio_dma_buf.c
+++ b/drivers/virtio/virtio_dma_buf.c
@@ -35,7 +35,16 @@ struct dma_buf *virtio_dma_buf_export
 EXPORT_SYMBOL(virtio_dma_buf_export);

 /**
- * virtio_dma_buf_attach - mandatory attach callback for virtio dma-bufs
+ * virtio_dma_buf_attach - Mandatory attach callback for virtio dma-bufs
+ * @dma_buf: Pointer to the shared dma-buf structure
+ * @attach: Pointer to the newly created attachment metadata
+ *
+ * Description: Implements the standard dma-buf attach operation for virtio devices.
+ *              Retrieves virtio-specific operations through container_of macro,
+ *              then invokes device-specific attach callback if present.
+ *              This enables virtio devices to participate in dma-buf sharing.
+ *
+ * Return: 0 on success, error code on failure
  */
 int virtio_dma_buf_attach(struct dma_buf *dma_buf,
                          struct dma_buf_attachment *attach)
-- 
2.25.1

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2025-07-05  2:15 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2025-07-04  7:20 [PATCH] virtio: Add missing kerneldoc for virtio_dma_buf_attach jiang.peng9
2025-07-04 15:19 ` Krzysztof Kozlowski
2025-07-05  2:14   ` jiang.peng9

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®