Received: by 2002:a25:ad19:0:0:0:0:0 with SMTP id y25csp2747301ybi; Thu, 18 Jul 2019 13:39:52 -0700 (PDT) X-Google-Smtp-Source: APXvYqxE6flS1U/0NQc2Oe+dU+9BB1trSQN4Sk6EDYLtpIwRhj5AX4mjkzNMmNjFTMCu3Rt2YBCF X-Received: by 2002:a63:490a:: with SMTP id w10mr48807580pga.6.1563482392529; Thu, 18 Jul 2019 13:39:52 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1563482392; cv=none; d=google.com; s=arc-20160816; b=cRC9RPphOF090GxmtNnm2nCuYXrtUGhHFCxNKzsS8RYtzHggqIxCcrG62NhTCVbLD5 Lej8q2Hx9K5/Ns7sCTw0kb1zk6dV4AullqCHy6FZSG25OjFOn3bak9zVLyfrHL0MGyA9 FSBUs3CqZs9hKPlp57tlbA9M3aDtSkW5382yo+ZG1p6AMM3+ZebiLSJ7qQMjB59IwVHB fNcHCID/88H8M8BZ7I7JYcBtoO2HBkNh6Jf71gfN0IS0VO0U8qtAHUX6FErf9wlm6USw m3L5toAmietX8M8AWp3f67VvLuLR40ie5PjJQP/KcRcGa8K3u9bqklo5hC2i9Shcgn0R VLBg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:in-reply-to:content-disposition :mime-version:references:message-id:subject:cc:to:from:date; bh=qMFLEC+KYuc8hLgaovJsIk7Em0POZCTUKP8jS8Cej/c=; b=F9QLuFWLfIRQiii8SR733V2e0Y/bvlpLEugTSB85IFMI5/4exrZtitcnmGO9pZ4jWy fcP1TrmMUUsp14/rgVk44E+16A3Atos5m2WqyitvmQnvuk38pJOv1rg+90OsisWOsNEo BOdgUlxdYXZ1SlKKkPGuxInzQSRE7w9hfChSzi84ZZApvPNg0C3DqNEwDUbmmxaeG8C8 7DnsviqyRTUn1deeY1oStlw3haXez/UjU7clsOpPgUtu1Gtpkt+6uv2U+/Y06ii9BSNX wumdDvyt7rbqEruQUJdp6o3dXIYgTiDVnbLAm3scVOieJTo2AAP8dZFBkRS4oLbvJAjJ cwjg== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=redhat.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id f1si1193065pjw.100.2019.07.18.13.39.36; Thu, 18 Jul 2019 13:39:52 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=redhat.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1728179AbfGRUh6 (ORCPT + 99 others); Thu, 18 Jul 2019 16:37:58 -0400 Received: from mx1.redhat.com ([209.132.183.28]:34732 "EHLO mx1.redhat.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727685AbfGRUh6 (ORCPT ); Thu, 18 Jul 2019 16:37:58 -0400 Received: from smtp.corp.redhat.com (int-mx07.intmail.prod.int.phx2.redhat.com [10.5.11.22]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mx1.redhat.com (Postfix) with ESMTPS id E683881F0C; Thu, 18 Jul 2019 20:37:57 +0000 (UTC) Received: from redhat.com (ovpn-120-147.rdu2.redhat.com [10.10.120.147]) by smtp.corp.redhat.com (Postfix) with SMTP id 7D93B1001B35; Thu, 18 Jul 2019 20:37:45 +0000 (UTC) Date: Thu, 18 Jul 2019 16:37:44 -0400 From: "Michael S. Tsirkin" To: Alexander Duyck Cc: Nitesh Narayan Lal , kvm list , David Hildenbrand , Dave Hansen , LKML , linux-mm , Andrew Morton , Yang Zhang , pagupta@redhat.com, Rik van Riel , Konrad Rzeszutek Wilk , lcapitulino@redhat.com, wei.w.wang@intel.com, Andrea Arcangeli , Paolo Bonzini , dan.j.williams@intel.com, Alexander Duyck Subject: Re: [PATCH v1 6/6] virtio-balloon: Add support for aerating memory via hinting Message-ID: <20190718163325-mutt-send-email-mst@kernel.org> References: <20190716115535-mutt-send-email-mst@kernel.org> <20190716125845-mutt-send-email-mst@kernel.org> <20190717055804-mutt-send-email-mst@kernel.org> <20190718003211-mutt-send-email-mst@kernel.org> <20190718113548-mutt-send-email-mst@kernel.org> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: X-Scanned-By: MIMEDefang 2.84 on 10.5.11.22 X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-4.5.16 (mx1.redhat.com [10.5.110.27]); Thu, 18 Jul 2019 20:37:58 +0000 (UTC) Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Thu, Jul 18, 2019 at 01:29:14PM -0700, Alexander Duyck wrote: > So one thing that is still an issue then is that my approach would > only work on the first migration. The problem is the logic I have > implemented assumes that once we have hinted on a page we don't need > to do it again. However in order to support migration you would need > to reset the hinting entirely and start over again after doing a > migration. Well with precopy at least it's simple: just clear the dirty bit, it won't be sent, and then on destination you get a zero page and later COW on first write. Right? With precopy it is tricker as destination waits until it gets all of memory. I think we could use some trick to make source pretend it's a zero page, that is cheap to send. -- MST