* [PATCH v3] virtio: fix virtio_config_ops kerneldocs
@ 2022-12-20 11:29 Ricardo Cañuelo
2022-12-20 11:31 ` Michael S. Tsirkin
0 siblings, 1 reply; 2+ messages in thread
From: Ricardo Cañuelo @ 2022-12-20 11:29 UTC (permalink / raw)
To: mst; +Cc: sfr, linux-next, kernel, linux-kernel, virtualization
Fixes two warning messages when building htmldocs:
warning: duplicate section name 'Note'
warning: expecting prototype for virtio_config_ops().
Prototype was for vq_callback_t() instead
Link: https://lore.kernel.org/linux-next/20221220105956.4786852d@canb.auug.org.au/
Fixes: 333723e8bc393d ("docs: driver-api: virtio: virtio on Linux")
Reported-by: Stephen Rothwell <sfr@canb.auug.org.au>
Signed-off-by: Ricardo Cañuelo <ricardo.canuelo@collabora.com>
Reviewed-by: Bagas Sanjaya <bagasdotme@gmail.com>
---
Changes in v3:
- Added a Fixes tag referencing the commit that revealed the warning
messages (suggested by Bagas Sanjaya and Michael S. Tsirkin)
Changes in v2:
- Reword the "Note" comment in the kerneldoc so that it doesn't look
like a kerneldoc "Note" section (suggested by AngeloGioacchino Del
Regno)
- Link, Reported-by and Reviewed-by tags added (suggested by Bagas
Sanjaya)
include/linux/virtio_config.h | 8 +++++---
1 file changed, 5 insertions(+), 3 deletions(-)
diff --git a/include/linux/virtio_config.h b/include/linux/virtio_config.h
index 4b517649cfe8..2b3438de2c4d 100644
--- a/include/linux/virtio_config.h
+++ b/include/linux/virtio_config.h
@@ -16,8 +16,10 @@ struct virtio_shm_region {
u64 len;
};
+typedef void vq_callback_t(struct virtqueue *);
+
/**
- * virtio_config_ops - operations for configuring a virtio device
+ * struct virtio_config_ops - operations for configuring a virtio device
* Note: Do not assume that a transport implements all of the operations
* getting/setting a value as a simple read/write! Generally speaking,
* any of @get/@set, @get_status/@set_status, or @get_features/
@@ -69,7 +71,8 @@ struct virtio_shm_region {
* vdev: the virtio_device
* This sends the driver feature bits to the device: it can change
* the dev->feature bits if it wants.
- * Note: despite the name this can be called any number of times.
+ * Note that despite the name this can be called any number of
+ * times.
* Returns 0 on success or error status
* @bus_name: return the bus name associated with the device (optional)
* vdev: the virtio_device
@@ -91,7 +94,6 @@ struct virtio_shm_region {
* If disable_vq_and_reset is set, then enable_vq_after_reset must also be
* set.
*/
-typedef void vq_callback_t(struct virtqueue *);
struct virtio_config_ops {
void (*get)(struct virtio_device *vdev, unsigned offset,
void *buf, unsigned len);
--
2.25.1
_______________________________________________
Virtualization mailing list
Virtualization@lists.linux-foundation.org
https://lists.linuxfoundation.org/mailman/listinfo/virtualization
^ permalink raw reply related [flat|nested] 2+ messages in thread* Re: [PATCH v3] virtio: fix virtio_config_ops kerneldocs
2022-12-20 11:29 [PATCH v3] virtio: fix virtio_config_ops kerneldocs Ricardo Cañuelo
@ 2022-12-20 11:31 ` Michael S. Tsirkin
0 siblings, 0 replies; 2+ messages in thread
From: Michael S. Tsirkin @ 2022-12-20 11:31 UTC (permalink / raw)
To: Ricardo Cañuelo
Cc: sfr, linux-next, kernel, linux-kernel, virtualization
On Tue, Dec 20, 2022 at 12:29:43PM +0100, Ricardo Cañuelo wrote:
> Fixes two warning messages when building htmldocs:
>
> warning: duplicate section name 'Note'
> warning: expecting prototype for virtio_config_ops().
> Prototype was for vq_callback_t() instead
>
> Link: https://lore.kernel.org/linux-next/20221220105956.4786852d@canb.auug.org.au/
> Fixes: 333723e8bc393d ("docs: driver-api: virtio: virtio on Linux")
> Reported-by: Stephen Rothwell <sfr@canb.auug.org.au>
> Signed-off-by: Ricardo Cañuelo <ricardo.canuelo@collabora.com>
> Reviewed-by: Bagas Sanjaya <bagasdotme@gmail.com>
I merged v2 already - squashed it in so Fixes isn't necessary.
I dropped Link: as well, probably going overboard for a fixup.
> ---
> Changes in v3:
> - Added a Fixes tag referencing the commit that revealed the warning
> messages (suggested by Bagas Sanjaya and Michael S. Tsirkin)
>
> Changes in v2:
> - Reword the "Note" comment in the kerneldoc so that it doesn't look
> like a kerneldoc "Note" section (suggested by AngeloGioacchino Del
> Regno)
> - Link, Reported-by and Reviewed-by tags added (suggested by Bagas
> Sanjaya)
>
> include/linux/virtio_config.h | 8 +++++---
> 1 file changed, 5 insertions(+), 3 deletions(-)
>
> diff --git a/include/linux/virtio_config.h b/include/linux/virtio_config.h
> index 4b517649cfe8..2b3438de2c4d 100644
> --- a/include/linux/virtio_config.h
> +++ b/include/linux/virtio_config.h
> @@ -16,8 +16,10 @@ struct virtio_shm_region {
> u64 len;
> };
>
> +typedef void vq_callback_t(struct virtqueue *);
> +
> /**
> - * virtio_config_ops - operations for configuring a virtio device
> + * struct virtio_config_ops - operations for configuring a virtio device
> * Note: Do not assume that a transport implements all of the operations
> * getting/setting a value as a simple read/write! Generally speaking,
> * any of @get/@set, @get_status/@set_status, or @get_features/
> @@ -69,7 +71,8 @@ struct virtio_shm_region {
> * vdev: the virtio_device
> * This sends the driver feature bits to the device: it can change
> * the dev->feature bits if it wants.
> - * Note: despite the name this can be called any number of times.
> + * Note that despite the name this can be called any number of
> + * times.
> * Returns 0 on success or error status
> * @bus_name: return the bus name associated with the device (optional)
> * vdev: the virtio_device
> @@ -91,7 +94,6 @@ struct virtio_shm_region {
> * If disable_vq_and_reset is set, then enable_vq_after_reset must also be
> * set.
> */
> -typedef void vq_callback_t(struct virtqueue *);
> struct virtio_config_ops {
> void (*get)(struct virtio_device *vdev, unsigned offset,
> void *buf, unsigned len);
> --
> 2.25.1
_______________________________________________
Virtualization mailing list
Virtualization@lists.linux-foundation.org
https://lists.linuxfoundation.org/mailman/listinfo/virtualization
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2022-12-20 11:32 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2022-12-20 11:29 [PATCH v3] virtio: fix virtio_config_ops kerneldocs Ricardo Cañuelo
2022-12-20 11:31 ` Michael S. Tsirkin
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).