From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1754050AbcIHWtt (ORCPT ); Thu, 8 Sep 2016 18:49:49 -0400 Received: from mail.linuxfoundation.org ([140.211.169.12]:46577 "EHLO mail.linuxfoundation.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751229AbcIHWts (ORCPT ); Thu, 8 Sep 2016 18:49:48 -0400 Date: Thu, 8 Sep 2016 15:49:31 -0700 From: Andrew Morton To: Dan Williams Cc: linux-nvdimm@ml01.01.org, Toshi Kani , Matthew Wilcox , Nilesh Choudhury , linux-kernel@vger.kernel.org, stable@vger.kernel.org, linux-mm@kvack.org, dri-devel@lists.freedesktop.org, Ross Zwisler , "Kirill A. Shutemov" , Kai Zhang Subject: Re: [PATCH v2 1/2] mm: fix cache mode of dax pmd mappings Message-Id: <20160908154931.73b8c075b8c8e4702f877bd7@linux-foundation.org> In-Reply-To: <147328717393.35069.6384193370523015106.stgit@dwillia2-desk3.amr.corp.intel.com> References: <147328716869.35069.16311932814998156819.stgit@dwillia2-desk3.amr.corp.intel.com> <147328717393.35069.6384193370523015106.stgit@dwillia2-desk3.amr.corp.intel.com> X-Mailer: Sylpheed 3.4.1 (GTK+ 2.24.23; x86_64-pc-linux-gnu) Mime-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Wed, 07 Sep 2016 15:26:14 -0700 Dan Williams wrote: > track_pfn_insert() in vmf_insert_pfn_pmd() is marking dax mappings as > uncacheable rendering them impractical for application usage. DAX-pte > mappings are cached and the goal of establishing DAX-pmd mappings is to > attain more performance, not dramatically less (3 orders of magnitude). > > track_pfn_insert() relies on a previous call to reserve_memtype() to > establish the expected page_cache_mode for the range. While memremap() > arranges for reserve_memtype() to be called, devm_memremap_pages() does > not. So, teach track_pfn_insert() and untrack_pfn() how to handle > tracking without a vma, and arrange for devm_memremap_pages() to > establish the write-back-cache reservation in the memtype tree. Acked-by: Andrew Morton I'll grab [2/2].