From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752307AbcKNO0K (ORCPT ); Mon, 14 Nov 2016 09:26:10 -0500 Received: from 206-15-90-246.static.twtelecom.net ([206.15.90.246]:25713 "EHLO felipe-franciosi.localdomain" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1751360AbcKNO0I (ORCPT ); Mon, 14 Nov 2016 09:26:08 -0500 X-Greylist: delayed 581 seconds by postgrey-1.27 at vger.kernel.org; Mon, 14 Nov 2016 09:26:08 EST From: Felipe Franciosi To: "Michael S. Tsirkin" , Jason Wang Cc: virtualization@lists.linux-foundation.org, linux-kernel@vger.kernel.org, Felipe Franciosi Subject: [PATCH] virtio_ring: fix description of virtqueue_get_buf Date: Mon, 14 Nov 2016 06:16:15 -0800 Message-Id: <1479132975-8517-1-git-send-email-felipe@nutanix.com> X-Mailer: git-send-email 1.9.4 Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org The device (not the driver) populates the used ring and includes the len of how much data was written. Signed-off-by: Felipe Franciosi --- drivers/virtio/virtio_ring.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/virtio/virtio_ring.c b/drivers/virtio/virtio_ring.c index 489bfc6..8a0d6a9 100644 --- a/drivers/virtio/virtio_ring.c +++ b/drivers/virtio/virtio_ring.c @@ -649,7 +649,7 @@ static inline bool more_used(const struct vring_virtqueue *vq) * @vq: the struct virtqueue we're talking about. * @len: the length written into the buffer * - * If the driver wrote data into the buffer, @len will be set to the + * If the device wrote data into the buffer, @len will be set to the * amount written. This means you don't need to clear the buffer * beforehand to ensure there's no data leakage in the case of short * writes. -- 1.9.4