lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <20100519223707.GD4111@redhat.com>
Date:	Thu, 20 May 2010 01:37:07 +0300
From:	"Michael S. Tsirkin" <mst@...hat.com>
To:	Jes.Sorensen@...hat.com
Cc:	rusty@...tcorp.com.au, linux-kernel@...r.kernel.org
Subject: Re: [PATCH] virtio_blk.c: Add documentation for vring_enable_cb()

On Wed, May 19, 2010 at 05:50:49PM +0200, Jes.Sorensen@...hat.com wrote:
> From: Jes Sorensen <Jes.Sorensen@...hat.com>
> 
> Add documentation for vring_enable_cb() as return logic may not be
> obvious for the caller.
> 
> Signed-off-by: Jes Sorensen <Jes.Sorensen@...hat.com>

Yes. Confused me too.
Acked-by: Michael S. Tsirkin <mst@...hat.com>

> ---
>  drivers/virtio/virtio_ring.c |    5 +++++
>  1 files changed, 5 insertions(+), 0 deletions(-)
> 
> diff --git a/drivers/virtio/virtio_ring.c b/drivers/virtio/virtio_ring.c
> index 0f90634..2cdcdca 100644
> --- a/drivers/virtio/virtio_ring.c
> +++ b/drivers/virtio/virtio_ring.c
> @@ -333,6 +333,11 @@ static void vring_disable_cb(struct virtqueue *_vq)
>  	vq->vring.avail->flags |= VRING_AVAIL_F_NO_INTERRUPT;
>  }
>  
> +/*
> + * Enable interrupts and check whether there is anything in the queue.
> + * Note, vring_enable_cb() returns TRUE if the queue is empty,  and
> + * FALSE if the queue is not empty and there is work to do.
> + */
>  static bool vring_enable_cb(struct virtqueue *_vq)
>  {
>  	struct vring_virtqueue *vq = to_vvq(_vq);
> -- 
> 1.6.5.2
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ