From mboxrd@z Thu Jan 1 00:00:00 1970 From: Yuanhan Liu Subject: Re: [PATCH 3/4] vhost: log vring changes Date: Thu, 3 Dec 2015 10:31:19 +0800 Message-ID: <20151203023119.GX2325@yliu-dev.sh.intel.com> References: <1449027793-30975-1-git-send-email-yuanhan.liu@linux.intel.com> <1449027793-30975-4-git-send-email-yuanhan.liu@linux.intel.com> <20151202155405-mutt-send-email-victork@redhat.com> <20151202143802.GT2325@yliu-dev.sh.intel.com> <20151202170233-mutt-send-email-victork@redhat.com> <20151202180824-mutt-send-email-mst@redhat.com> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Cc: dev@dpdk.org, Victor Kaplansky To: "Michael S. Tsirkin" Return-path: Received: from mga02.intel.com (mga02.intel.com [134.134.136.20]) by dpdk.org (Postfix) with ESMTP id 44BDA11C5 for ; Thu, 3 Dec 2015 03:27:47 +0100 (CET) Content-Disposition: inline In-Reply-To: <20151202180824-mutt-send-email-mst@redhat.com> List-Id: patches and discussions about DPDK List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dev-bounces@dpdk.org Sender: "dev" On Wed, Dec 02, 2015 at 06:26:37PM +0200, Michael S. Tsirkin wrote: > On Wed, Dec 02, 2015 at 05:58:24PM +0200, Victor Kaplansky wrote: > > On Wed, Dec 02, 2015 at 10:38:02PM +0800, Yuanhan Liu wrote: > > > On Wed, Dec 02, 2015 at 04:07:02PM +0200, Victor Kaplansky wrote: > > > > On Wed, Dec 02, 2015 at 11:43:12AM +0800, Yuanhan Liu wrote: > > > > > Invoking vhost_log_write() to mark corresponding page as dirty while > > > > > updating used vring. > > > > > > > > Looks good, thanks! > > > > > > > > I didn't find where you log the dirty pages in result of data > > > > written to the buffers pointed by the descriptors in RX vring. > > > > AFAIU, the buffers of RX queue reside in guest's memory and have > > > > to be marked as dirty if they are written. What do you say? > > > > > > Yeah, we should. I got a question then: why log_guest_addr is set > > > to the physical address of used vring in guest? I mean, apparently, > > > we need log more changes other than used vring only. > > > > The physical address of used vring sent to the back-end, since > > otherwise back-end has to perform virtual to physical > > translation, and we want to avoid this. The dirty buffers has to > > be marked as well, but their guest's physical address is known > > directly from the descriptors. > > Yes, people wanted to be able to do multiple physical > addresses to one virtual so you do not want to translate > virt to phys. Thank you both, it's clear to me then. --yliu