From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail-oi0-x242.google.com (mail-oi0-x242.google.com [IPv6:2607:f8b0:4003:c06::242]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by ml01.01.org (Postfix) with ESMTPS id 66DCB2034714B for ; Fri, 20 Oct 2017 08:19:24 -0700 (PDT) Received: by mail-oi0-x242.google.com with SMTP id v132so20553728oie.1 for ; Fri, 20 Oct 2017 08:23:03 -0700 (PDT) MIME-Version: 1.0 In-Reply-To: <20171020075735.GA14378@lst.de> References: <150846713528.24336.4459262264611579791.stgit@dwillia2-desk3.amr.corp.intel.com> <150846714747.24336.14704246566580871364.stgit@dwillia2-desk3.amr.corp.intel.com> <20171020075735.GA14378@lst.de> From: Dan Williams Date: Fri, 20 Oct 2017 08:23:02 -0700 Message-ID: Subject: Re: [PATCH v3 02/13] dax: require 'struct page' for filesystem dax List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Errors-To: linux-nvdimm-bounces@lists.01.org Sender: "Linux-nvdimm" To: Christoph Hellwig Cc: Jan Kara , "linux-nvdimm@lists.01.org" , Benjamin Herrenschmidt , Heiko Carstens , "linux-kernel@vger.kernel.org" , linux-xfs@vger.kernel.org, Linux MM , Paul Mackerras , Michael Ellerman , Martin Schwidefsky , linux-fsdevel , Andrew Morton , Gerald Schaefer List-ID: On Fri, Oct 20, 2017 at 12:57 AM, Christoph Hellwig wrote: >> --- a/arch/powerpc/sysdev/axonram.c >> +++ b/arch/powerpc/sysdev/axonram.c >> @@ -172,6 +172,7 @@ static size_t axon_ram_copy_from_iter(struct dax_device *dax_dev, pgoff_t pgoff, >> >> static const struct dax_operations axon_ram_dax_ops = { >> .direct_access = axon_ram_dax_direct_access, >> + >> .copy_from_iter = axon_ram_copy_from_iter, > > Unrelated whitespace change. That being said - I don't think axonram has > devmap support in any form, so this basically becomes dead code, doesn't > it? > >> diff --git a/drivers/s390/block/dcssblk.c b/drivers/s390/block/dcssblk.c >> index 7abb240847c0..e7e5db07e339 100644 >> --- a/drivers/s390/block/dcssblk.c >> +++ b/drivers/s390/block/dcssblk.c >> @@ -52,6 +52,7 @@ static size_t dcssblk_dax_copy_from_iter(struct dax_device *dax_dev, >> >> static const struct dax_operations dcssblk_dax_ops = { >> .direct_access = dcssblk_dax_direct_access, >> + >> .copy_from_iter = dcssblk_dax_copy_from_iter, > > Same comments apply here. Yes, however it seems these drivers / platforms have been living with the lack of struct page for a long time. So they either don't use DAX, or they have a constrained use case that never triggers get_user_pages(). If it is the latter then they could introduce a new configuration option that bypasses the pfn_t_devmap() check in bdev_dax_supported() and fix up the get_user_pages() paths to fail. So, I'd like to understand how these drivers have been using DAX support without struct page to see if we need a workaround or we can go ahead delete this support. If the usage is limited to execute-in-place perhaps we can do a constrained ->direct_access() for just that case. _______________________________________________ Linux-nvdimm mailing list Linux-nvdimm@lists.01.org https://lists.01.org/mailman/listinfo/linux-nvdimm From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752125AbdJTPXG (ORCPT ); Fri, 20 Oct 2017 11:23:06 -0400 Received: from mail-oi0-f65.google.com ([209.85.218.65]:45187 "EHLO mail-oi0-f65.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752022AbdJTPXD (ORCPT ); Fri, 20 Oct 2017 11:23:03 -0400 X-Google-Smtp-Source: ABhQp+Qo8FESq642jOrnH+WW4v4oAR09wf3paHfT8aa0d4kuwuJBg2eteEQBiJP9m7Vijb395zShRNGYsq8MwyLLILA= MIME-Version: 1.0 In-Reply-To: <20171020075735.GA14378@lst.de> References: <150846713528.24336.4459262264611579791.stgit@dwillia2-desk3.amr.corp.intel.com> <150846714747.24336.14704246566580871364.stgit@dwillia2-desk3.amr.corp.intel.com> <20171020075735.GA14378@lst.de> From: Dan Williams Date: Fri, 20 Oct 2017 08:23:02 -0700 Message-ID: Subject: Re: [PATCH v3 02/13] dax: require 'struct page' for filesystem dax To: Christoph Hellwig Cc: Andrew Morton , Jan Kara , "linux-nvdimm@lists.01.org" , Benjamin Herrenschmidt , Heiko Carstens , "linux-kernel@vger.kernel.org" , linux-xfs@vger.kernel.org, Linux MM , Jeff Moyer , Paul Mackerras , Michael Ellerman , Martin Schwidefsky , linux-fsdevel , Ross Zwisler , Gerald Schaefer Content-Type: text/plain; charset="UTF-8" Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Fri, Oct 20, 2017 at 12:57 AM, Christoph Hellwig wrote: >> --- a/arch/powerpc/sysdev/axonram.c >> +++ b/arch/powerpc/sysdev/axonram.c >> @@ -172,6 +172,7 @@ static size_t axon_ram_copy_from_iter(struct dax_device *dax_dev, pgoff_t pgoff, >> >> static const struct dax_operations axon_ram_dax_ops = { >> .direct_access = axon_ram_dax_direct_access, >> + >> .copy_from_iter = axon_ram_copy_from_iter, > > Unrelated whitespace change. That being said - I don't think axonram has > devmap support in any form, so this basically becomes dead code, doesn't > it? > >> diff --git a/drivers/s390/block/dcssblk.c b/drivers/s390/block/dcssblk.c >> index 7abb240847c0..e7e5db07e339 100644 >> --- a/drivers/s390/block/dcssblk.c >> +++ b/drivers/s390/block/dcssblk.c >> @@ -52,6 +52,7 @@ static size_t dcssblk_dax_copy_from_iter(struct dax_device *dax_dev, >> >> static const struct dax_operations dcssblk_dax_ops = { >> .direct_access = dcssblk_dax_direct_access, >> + >> .copy_from_iter = dcssblk_dax_copy_from_iter, > > Same comments apply here. Yes, however it seems these drivers / platforms have been living with the lack of struct page for a long time. So they either don't use DAX, or they have a constrained use case that never triggers get_user_pages(). If it is the latter then they could introduce a new configuration option that bypasses the pfn_t_devmap() check in bdev_dax_supported() and fix up the get_user_pages() paths to fail. So, I'd like to understand how these drivers have been using DAX support without struct page to see if we need a workaround or we can go ahead delete this support. If the usage is limited to execute-in-place perhaps we can do a constrained ->direct_access() for just that case. From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: MIME-Version: 1.0 In-Reply-To: <20171020075735.GA14378@lst.de> References: <150846713528.24336.4459262264611579791.stgit@dwillia2-desk3.amr.corp.intel.com> <150846714747.24336.14704246566580871364.stgit@dwillia2-desk3.amr.corp.intel.com> <20171020075735.GA14378@lst.de> From: Dan Williams Date: Fri, 20 Oct 2017 08:23:02 -0700 Message-ID: Subject: Re: [PATCH v3 02/13] dax: require 'struct page' for filesystem dax To: Christoph Hellwig Cc: Andrew Morton , Jan Kara , "linux-nvdimm@lists.01.org" , Benjamin Herrenschmidt , Heiko Carstens , "linux-kernel@vger.kernel.org" , linux-xfs@vger.kernel.org, Linux MM , Jeff Moyer , Paul Mackerras , Michael Ellerman , Martin Schwidefsky , linux-fsdevel , Ross Zwisler , Gerald Schaefer Content-Type: text/plain; charset="UTF-8" Sender: owner-linux-mm@kvack.org List-ID: On Fri, Oct 20, 2017 at 12:57 AM, Christoph Hellwig wrote: >> --- a/arch/powerpc/sysdev/axonram.c >> +++ b/arch/powerpc/sysdev/axonram.c >> @@ -172,6 +172,7 @@ static size_t axon_ram_copy_from_iter(struct dax_device *dax_dev, pgoff_t pgoff, >> >> static const struct dax_operations axon_ram_dax_ops = { >> .direct_access = axon_ram_dax_direct_access, >> + >> .copy_from_iter = axon_ram_copy_from_iter, > > Unrelated whitespace change. That being said - I don't think axonram has > devmap support in any form, so this basically becomes dead code, doesn't > it? > >> diff --git a/drivers/s390/block/dcssblk.c b/drivers/s390/block/dcssblk.c >> index 7abb240847c0..e7e5db07e339 100644 >> --- a/drivers/s390/block/dcssblk.c >> +++ b/drivers/s390/block/dcssblk.c >> @@ -52,6 +52,7 @@ static size_t dcssblk_dax_copy_from_iter(struct dax_device *dax_dev, >> >> static const struct dax_operations dcssblk_dax_ops = { >> .direct_access = dcssblk_dax_direct_access, >> + >> .copy_from_iter = dcssblk_dax_copy_from_iter, > > Same comments apply here. Yes, however it seems these drivers / platforms have been living with the lack of struct page for a long time. So they either don't use DAX, or they have a constrained use case that never triggers get_user_pages(). If it is the latter then they could introduce a new configuration option that bypasses the pfn_t_devmap() check in bdev_dax_supported() and fix up the get_user_pages() paths to fail. So, I'd like to understand how these drivers have been using DAX support without struct page to see if we need a workaround or we can go ahead delete this support. If the usage is limited to execute-in-place perhaps we can do a constrained ->direct_access() for just that case. -- To unsubscribe, send a message with 'unsubscribe linux-mm' in the body to majordomo@kvack.org. For more info on Linux MM, see: http://www.linux-mm.org/ . Don't email: email@kvack.org