Received: by 10.192.165.148 with SMTP id m20csp791751imm; Wed, 25 Apr 2018 07:45:35 -0700 (PDT) X-Google-Smtp-Source: AIpwx49VEWeyWKH3sGFj5xhkMJxUTD2I7JRMB0VrXrCxPanUYRr/zyUXgOYL/hO0tIlzCHL4rPWV X-Received: by 10.98.89.89 with SMTP id n86mr28299929pfb.158.1524667535580; Wed, 25 Apr 2018 07:45:35 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1524667535; cv=none; d=google.com; s=arc-20160816; b=IRQtNh6FvUcVYJ+KTyg8pqDvNWVEi0N2fMSMXpNN3N6PIRaDNrtYUYtMqzPbgFYAzy Zmwdslvo3v+ZiHEQVe+xuBGgwjjj8c1gi+RuE7PptOr3/lcGmHFA4DVkTixifcN+oQrx bATQ6M74I9+jDB6Dz7LyslaWjaTDbPO1L31I6e5fdlhoxFnOqg+pgv2ZYxprzfGZZy/4 y25zTW0yqTFo0kmxUoIQm2kTHfjwUxRP+ewDP9ejEzWbuOFBAWH5tGB1GRqAOhoz46xH bfms69k72e1X83ppPDd8m/yKKsUxuwY6t+DyqT/kVUWSSTvOtTMK0tI0thR/YSc+Akm1 4hhQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:cc:to:subject:message-id:date:from :references:in-reply-to:mime-version:dkim-signature :arc-authentication-results; bh=jiSrAHwHeXZ5qNhRfrua36R9BR4F2/JwzQw56CHUPDY=; b=C61BlOTtZw2G5wDctLxrXRQZunsGl/y+nAapRK48qBbzrWAQjCXpgqhNlREnYZK9wC 0r/lbMzNKl+cBz9rqwy955l3CG2aN4wSd3Fr1DgmajpJq/N5gFKBMSInC16pwTqnthPt K9rbf7ecz90qsHuJ1WKwRKoWnCRx2V3UcOTZ4P+g/Ecze/JiCCZwJ2gmKbXNpWIkLmcS a1V2rKAWeC2b4XjpQXb9zwTmuZPc3XM87okX3Qehs0sQX1YOBQ3KIOp5vjApNDjcoRwM MmMfTP3RYM9DtRigS4IXAzeTgymkB+PIP8n765rVozY/xf6sqdXVJcr2nloQXwug0IO/ vUKg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@intel-com.20150623.gappssmtp.com header.s=20150623 header.b=Mh9WkI1v; 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 Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id b2si13894050pgn.131.2018.04.25.07.45.20; Wed, 25 Apr 2018 07:45:35 -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; dkim=pass header.i=@intel-com.20150623.gappssmtp.com header.s=20150623 header.b=Mh9WkI1v; 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 Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1754718AbeDYOnz (ORCPT + 99 others); Wed, 25 Apr 2018 10:43:55 -0400 Received: from mail-oi0-f65.google.com ([209.85.218.65]:35249 "EHLO mail-oi0-f65.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1754517AbeDYOnx (ORCPT ); Wed, 25 Apr 2018 10:43:53 -0400 Received: by mail-oi0-f65.google.com with SMTP id a6-v6so12042571oia.2 for ; Wed, 25 Apr 2018 07:43:53 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=intel-com.20150623.gappssmtp.com; s=20150623; h=mime-version:in-reply-to:references:from:date:message-id:subject:to :cc; bh=jiSrAHwHeXZ5qNhRfrua36R9BR4F2/JwzQw56CHUPDY=; b=Mh9WkI1vUBYhGpW3BteDM5aEcVadfX2KVHibVdPYvkqejoLLAWG6Wsm8xnNxqmIIoh a3T6XEIGyMl3dZWh4r8IE8/flkrVx15KOTUKqDfixQCWoY0mUl3yTF8cQkmxPo62SBuC 0NYSBfFOm38QZsrnOqC61oqLYn8CnpsQ/5dRQDuTa/vsl57q9trSyZb6LXkSkESC53zf 9GadHxsMtSRit166F64fvyMs9951puh68UUWaAhMJ8PPnsBwnq8CTko5LoSIVkz5EzCt OHyaF0DGVVIBxrvY/fwflyIU4b5BXatvJdXpTCcccO5pZbpBVop0528rpeAVYS3TNUe5 Z2YQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:in-reply-to:references:from:date :message-id:subject:to:cc; bh=jiSrAHwHeXZ5qNhRfrua36R9BR4F2/JwzQw56CHUPDY=; b=sgF2JWTuVmJsaPbT2xpbTwDavcyleJJErTV0u6s6iXoDN8FRXWjdCuny8x7MyA5L5c bfiaDElZEu6Q64v55ZuIJCJiZ2qbKJNbb/tIYaft3okXycia4RlVEqowQYsudlDeZREP 8JkRDMPFGanNZS7NN958SbGUFfY0HEEFeRmL3Fy/ZlVQtZDehO6AmcPHXk3Co1B/gvl0 Wp+90kjBVchClYle7DtjJoh9X2T5lq+/OnpYVsXLQWYQZcOqaBz9oOrONz+6pAoZnEY/ yNUAXN4yH8G4yTr1ox+ki+6siRPJpOxeeeCvWlspSQ23XUdDtz+4GjCcd/GjNv2PkcsJ Fj+w== X-Gm-Message-State: ALQs6tCmdyjwolGrndNaG7N5Cv7Ulj3t8Sbbify+QT/f+dJTbCisYnhO /T3tw4hfv+ooOewk7n5q4Gy8SxW/zvxI2gGGWkFvog== X-Received: by 2002:aca:b80a:: with SMTP id i10-v6mr18609194oif.72.1524667432932; Wed, 25 Apr 2018 07:43:52 -0700 (PDT) MIME-Version: 1.0 Received: by 2002:a9d:2d36:0:0:0:0:0 with HTTP; Wed, 25 Apr 2018 07:43:52 -0700 (PDT) In-Reply-To: References: <20180425112415.12327-1-pagupta@redhat.com> <20180425112415.12327-2-pagupta@redhat.com> From: Dan Williams Date: Wed, 25 Apr 2018 07:43:52 -0700 Message-ID: Subject: Re: [RFC v2 1/2] virtio: add pmem driver To: Pankaj Gupta Cc: Linux Kernel Mailing List , KVM list , Qemu Developers , linux-nvdimm , Linux MM , Jan Kara , Stefan Hajnoczi , Rik van Riel , Haozhong Zhang , Nitesh Narayan Lal , Kevin Wolf , Paolo Bonzini , "Zwisler, Ross" , David Hildenbrand , Xiao Guangrong , Christoph Hellwig , Marcel Apfelbaum , "Michael S. Tsirkin" , niteshnarayanlal@hotmail.com, Igor Mammedov , lcapitulino@redhat.com, jmoyer Content-Type: text/plain; charset="UTF-8" Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org [ adding Jeff directly since he has also been looking at infrastructure to track when MAP_SYNC should be disabled ] On Wed, Apr 25, 2018 at 7:21 AM, Dan Williams wrote: > On Wed, Apr 25, 2018 at 4:24 AM, Pankaj Gupta wrote: >> This patch adds virtio-pmem driver for KVM >> guest. > > Minor nit, please expand your changelog line wrapping to 72 columns. > >> >> Guest reads the persistent memory range >> information from Qemu over VIRTIO and registers >> it on nvdimm_bus. It also creates a nd_region >> object with the persistent memory range >> information so that existing 'nvdimm/pmem' >> driver can reserve this into system memory map. >> This way 'virtio-pmem' driver uses existing >> functionality of pmem driver to register persistent >> memory compatible for DAX capable filesystems. > > We need some additional enabling to disable MAP_SYNC for this > configuration. In other words, if fsync() is required then we must > disable the MAP_SYNC optimization. I think this should be a struct > dax_device property looked up at mmap time in each MAP_SYNC capable > ->mmap() file operation implementation.