Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753395AbdFSCFB (ORCPT ); Sun, 18 Jun 2017 22:05:01 -0400 Received: from mail-oi0-f49.google.com ([209.85.218.49]:35591 "EHLO mail-oi0-f49.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1753298AbdFSCE5 (ORCPT ); Sun, 18 Jun 2017 22:04:57 -0400 MIME-Version: 1.0 In-Reply-To: <20170618083702.GB26456@lst.de> References: <149703982465.20620.14881139332926778446.stgit@dwillia2-desk3.amr.corp.intel.com> <149703983692.20620.3787021839815275819.stgit@dwillia2-desk3.amr.corp.intel.com> <20170618083702.GB26456@lst.de> From: Dan Williams Date: Sun, 18 Jun 2017 19:04:56 -0700 Message-ID: Subject: Re: [PATCH v3 02/14] dm: add ->copy_from_iter() dax operation support To: Christoph Hellwig Cc: "linux-nvdimm@lists.01.org" , Mike Snitzer , Toshi Kani , X86 ML , "linux-kernel@vger.kernel.org" , dm-devel@redhat.com, Al Viro , linux-fsdevel Content-Type: text/plain; charset="UTF-8" Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 749 Lines: 19 On Sun, Jun 18, 2017 at 1:37 AM, Christoph Hellwig wrote: >> +size_t dax_copy_from_iter(struct dax_device *dax_dev, pgoff_t pgoff, void *addr, >> + size_t bytes, struct iov_iter *i) >> +{ >> + if (!dax_alive(dax_dev)) >> + return 0; >> + >> + if (!dax_dev->ops->copy_from_iter) >> + return copy_from_iter(addr, bytes, i); >> + return dax_dev->ops->copy_from_iter(dax_dev, pgoff, addr, bytes, i); >> +} >> +EXPORT_SYMBOL_GPL(dax_copy_from_iter); > > Can you remove the fallbacks after this series so that we have > a clean abstraction? You mean update all implementations to register copy_from_iter() as their default op rather than workaround a NULL op in the core? Yeah, I can do that.