public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: Simon Horman <horms@kernel.org>
To: Stefano Garzarella <sgarzare@redhat.com>
Cc: "Michael S. Tsirkin" <mst@redhat.com>,
	Jason Wang <jasowang@redhat.com>,
	Xuan Zhuo <xuanzhuo@linux.alibaba.com>,
	virtualization@lists.linux-foundation.org,
	linux-kernel@vger.kernel.org
Subject: Re: [PATCH v2] virtio: Add missing documentation for structure fields
Date: Fri, 19 May 2023 18:54:25 +0200	[thread overview]
Message-ID: <ZGepwedHtG62XFXP@kernel.org> (raw)
In-Reply-To: <y6kgnwu35oci7y5hx2htfobglrecjhxgpnqmtjetv52xk7hlsc@gwvfoojunl4x>

On Tue, May 16, 2023 at 10:54:49AM +0200, Stefano Garzarella wrote:
> On Thu, May 11, 2023 at 04:46:22PM +0200, Simon Horman wrote:
> > Add missing documentation for the vqs_list_lock field of struct virtio_device,
> > and the validate field of struct virtio_driver.
> > 
> > ./scripts/kernel-doc says:
> > 
> > .../virtio.h:131: warning: Function parameter or member 'vqs_list_lock' not described in 'virtio_device'
> > .../virtio.h:192: warning: Function parameter or member 'validate' not described in 'virtio_driver'
> > 2 warnings as Errors
> > 
> > No functional changes intended.
> > 
> > Signed-off-by: Simon Horman <horms@kernel.org>
> > ---
> > Changes in v2:
> > - As suggested by Michael S. Tsirkin
> >  + @validate is not called on probe
> >  + @validate does validates config space
> >  + embarrassingly, validate was misspelt
> > - Link to v1: https://lore.kernel.org/r/20230510-virtio-kdoc-v1-1-d2b1824a9a2b@kernel.org
> > ---
> > include/linux/virtio.h | 2 ++
> > 1 file changed, 2 insertions(+)
> 
> I left some minor comments, anyway this version LGTM:
> 
> Reviewed-by: Stefano Garzarella <sgarzare@redhat.com>

Thanks, and sorry for the delay.

> > diff --git a/include/linux/virtio.h b/include/linux/virtio.h
> > index b93238db94e3..3abe8e9c8090 100644
> > --- a/include/linux/virtio.h
> > +++ b/include/linux/virtio.h
> > @@ -103,6 +103,7 @@ int virtqueue_resize(struct virtqueue *vq, u32 num,
> >  * @config_enabled: configuration change reporting enabled
> >  * @config_change_pending: configuration change reported while disabled
> >  * @config_lock: protects configuration change reporting
> > + * @vqs_list_lock: protects @vqs.
> 
> Maybe we can now remove `/* Protects VQs list access */`

Yes, I think so.

> >  * @dev: underlying device.
> >  * @id: the device type identification (used to match it with a driver).
> >  * @config: the configuration ops for this device.
> > @@ -160,6 +161,7 @@ size_t virtio_max_dma_size(const struct virtio_device *vdev);
> >  * @feature_table_size: number of entries in the feature table array.
> >  * @feature_table_legacy: same as feature_table but when working in legacy mode.
> >  * @feature_table_size_legacy: number of entries in feature table legacy array.
> > + * @validate: the function to call to validate features and config space
> 
> Maybe we can add ". Returns 0 or -errno."

Sure, I'll plan to include this in v3.

 * @validate: the function to call to validate features and config space.
 *            Returns 0 or -errno.

...

      reply	other threads:[~2023-05-19 16:54 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-05-11 14:46 [PATCH v2] virtio: Add missing documentation for structure fields Simon Horman
2023-05-16  8:54 ` Stefano Garzarella
2023-05-19 16:54   ` Simon Horman [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=ZGepwedHtG62XFXP@kernel.org \
    --to=horms@kernel.org \
    --cc=jasowang@redhat.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=mst@redhat.com \
    --cc=sgarzare@redhat.com \
    --cc=virtualization@lists.linux-foundation.org \
    --cc=xuanzhuo@linux.alibaba.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox