Received: by 10.192.165.148 with SMTP id m20csp3439722imm; Mon, 7 May 2018 12:18:56 -0700 (PDT) X-Google-Smtp-Source: AB8JxZqmzkHZ2OtTA4zdfgGGPj/HDwUGMQ6FBRFxMCL5HT7LSVt+1xJDxK6Hw/WsC9RbomQrSO7e X-Received: by 2002:a63:5f4f:: with SMTP id t76-v6mr30583251pgb.108.1525720736704; Mon, 07 May 2018 12:18:56 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1525720736; cv=none; d=google.com; s=arc-20160816; b=UZ06JdZYOkSZ/AEhbXA18JqjbqnS6yffVv34FshwaZ95EBkw69GJiZkkiPWQVT7hP8 q7HW2KcYaoLRNUYjZtWWK+Da1nM/ehwemwGgYAAQPV+WWwcT6EGuWAC9kcKji4ZNAx8y AN2AOoEYXt541bobusesxF7/ypkcP8MUJlgA6witC84q6C8j7B3IDoTYfI5PazURR+0b V41KTKMtr1EaA4Oanr7Oc6S0WDuyQK2Vgq5G6Dt/hbMlQyLyO5TFRuBVQ7bX8T9QdI3d dxo/TLexjKKMI1Ai1OXcqI973idZmknJYgeiiUQpp5sOlwI4s518bknTX4D9o/lL2bx0 Bfxg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding:cc:to:subject :message-id:date:from:references:in-reply-to:mime-version :dkim-signature:arc-authentication-results; bh=07pOeWolNI5CgrS7yFfm52WV5aApnOBPROdB6BVHjks=; b=ZwOZQLqZt+XFdo3ss2fxCq03GeI74FV5RMWfjRqCPtHB8yjjtfHDnEwOQeIj1Ct42a Gt0LhpfJuN+3KkmLoSEdbVZzy1CnFbY0iKgYyUYAgt0s7in2J4Tw/7E/i5Mx6/jMbQZ4 72Evk1W8ubF2DcHEy1GSdfmikcDByXUO3CboqWkXBKIzj0LdvCaUtWQTLo/EWGwoA8wg LIpMIFkQ4JtH6QMHrHkPZf0tW3sKrmeYELdoZzPEHfsbYrfSaDCaJ8L053rUIfDmAr3o DupEjXMS1t0u5pKPkPpetsX2HWHufLp5EvPbanEN5bjwOr5bAROkypijfI4Dyshb4NGw GpZw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@intel-com.20150623.gappssmtp.com header.s=20150623 header.b=Y7LBn8kz; 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 e1-v6si22262602ple.428.2018.05.07.12.18.42; Mon, 07 May 2018 12:18:56 -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=Y7LBn8kz; 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 S1752728AbeEGTRK (ORCPT + 99 others); Mon, 7 May 2018 15:17:10 -0400 Received: from mail-ot0-f170.google.com ([74.125.82.170]:42703 "EHLO mail-ot0-f170.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751976AbeEGTRI (ORCPT ); Mon, 7 May 2018 15:17:08 -0400 Received: by mail-ot0-f170.google.com with SMTP id l13-v6so33279425otk.9 for ; Mon, 07 May 2018 12:17:08 -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:content-transfer-encoding; bh=07pOeWolNI5CgrS7yFfm52WV5aApnOBPROdB6BVHjks=; b=Y7LBn8kzGv8atqXw6ayBfiTOLTxozhKtCRI+Yf/AVvtoPeZDJMQs1Y+PM7hN5fG2f+ y5aQ1c/4urZp1wV8OXzo6CRPIwP1XbYfaTlYaplcdX1U363UApvaXMDIuDNIxIewqsEv ykJ0CaU2nGtIPl2aUP7IxP0dIiguB3OxjHVmCP2HqEcJrsE7jEO2r5nuEZbIm3b4adFo 90S778MU2kJ7+O9O4XaRVUam4NMTqYNk3ml7hFyAoUckSGulkKiNT1mP+++KsqZ8qkyT +B8/ahJJPKyc0HQ5mpaL7IVbVUQTv2OTxi7nraWJjlUcEVyiIoLGh9hWXVAVTqUfsYjm BVOw== 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:content-transfer-encoding; bh=07pOeWolNI5CgrS7yFfm52WV5aApnOBPROdB6BVHjks=; b=DL9apQ6Lrm5EjqH83Y4euYgBLkwMhiZ6BKATWc/hWJe7UNSR4Vnl7lAwglmjRD6cls pzK61yXEYB7Xt0tYzcwuv2MW9dj6Ku9c30+EeHacWQJWOZ8uKyrrgUDA5btvISf9cBPo CJfwcQRrHcTozyLjLqFzpLQKZRrzvCju1QlRLU9AuwrXw2//O5JEU4UekPeLhN8mLC6n k9CGL84dnpJCpdniZyuZyifJ/2PF/+cT2hecu+6FIhMaGMRkwNWpP1ajklUUsw6esKNy EjtJVYk064LFJq3pW2ld74h6RT2xIRgyZSblZqZcfoH3T/XoXBz4NwHii6N/5z7A5qKo bMig== X-Gm-Message-State: ALKqPwerjbADW09J8P7YDJeeh0vzQGuJnSs7KRdlCDUuEdQh/5++IEaw uozRYTf+551x4PMW9yetR9MWk/d4r+XSZmqsRTqn1g== X-Received: by 2002:a9d:36ac:: with SMTP id h41-v6mr10396098otc.292.1525720625845; Mon, 07 May 2018 12:17:05 -0700 (PDT) MIME-Version: 1.0 Received: by 2002:a9d:2d36:0:0:0:0:0 with HTTP; Mon, 7 May 2018 12:17:05 -0700 (PDT) In-Reply-To: References: <1525704627-30114-1-git-send-email-yehs1@lenovo.com> <20180507184622.GB12361@bombadil.infradead.org> From: Dan Williams Date: Mon, 7 May 2018 12:17:05 -0700 Message-ID: Subject: Re: [RFC PATCH v1 0/6] use mm to manage NVDIMM (pmem) zone To: Jeff Moyer Cc: Matthew Wilcox , Michal Hocko , Huaisheng Ye , linux-nvdimm , Tetsuo Handa , chengnt@lenovo.com, Dave Hansen , Linux Kernel Mailing List , pasha.tatashin@oracle.com, Linux MM , colyli@suse.de, Johannes Weiner , Andrew Morton , Sasha Levin , Mel Gorman , Vlastimil Babka Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Mon, May 7, 2018 at 12:08 PM, Jeff Moyer wrote: > Dan Williams writes: > >> On Mon, May 7, 2018 at 11:46 AM, Matthew Wilcox wr= ote: >>> On Mon, May 07, 2018 at 10:50:21PM +0800, Huaisheng Ye wrote: >>>> Traditionally, NVDIMMs are treated by mm(memory management) subsystem = as >>>> DEVICE zone, which is a virtual zone and both its start and end of pfn >>>> are equal to 0, mm wouldn=E2=80=99t manage NVDIMM directly as DRAM, ke= rnel uses >>>> corresponding drivers, which locate at \drivers\nvdimm\ and >>>> \drivers\acpi\nfit and fs, to realize NVDIMM memory alloc and free wit= h >>>> memory hot plug implementation. >>> >>> You probably want to let linux-nvdimm know about this patch set. >>> Adding to the cc. >> >> Yes, thanks for that! >> >>> Also, I only received patch 0 and 4. What happened >>> to 1-3,5 and 6? >>> >>>> With current kernel, many mm=E2=80=99s classical features like the bud= dy >>>> system, swap mechanism and page cache couldn=E2=80=99t be supported to= NVDIMM. >>>> What we are doing is to expand kernel mm=E2=80=99s capacity to make it= to handle >>>> NVDIMM like DRAM. Furthermore we make mm could treat DRAM and NVDIMM >>>> separately, that means mm can only put the critical pages to NVDIMM > > Please define "critical pages." > >>>> zone, here we created a new zone type as NVM zone. That is to say for >>>> traditional(or normal) pages which would be stored at DRAM scope like >>>> Normal, DMA32 and DMA zones. But for the critical pages, which we hope >>>> them could be recovered from power fail or system crash, we make them >>>> to be persistent by storing them to NVM zone. > > [...] > >> I think adding yet one more mm-zone is the wrong direction. Instead, >> what we have been considering is a mechanism to allow a device-dax >> instance to be given back to the kernel as a distinct numa node >> managed by the VM. It seems it times to dust off those patches. > > What's the use case? Use NVDIMMs as System-RAM given their potentially higher capacity than DDR. The expectation in that case is that data is forfeit (not persisted) after a crash. Any persistent use case would need to go through the pmem driver, filesystem-dax or device-dax.