From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from us-smtp-delivery-124.mimecast.com (us-smtp-delivery-124.mimecast.com [170.10.133.124]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 4E54FC433F5 for ; Tue, 23 Nov 2021 23:03:55 +0000 (UTC) Received: from mimecast-mx01.redhat.com (mimecast-mx01.redhat.com [209.132.183.4]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id us-mta-328-PpgOfCRhMKi1Pe-vP_dixg-1; Tue, 23 Nov 2021 18:03:52 -0500 X-MC-Unique: PpgOfCRhMKi1Pe-vP_dixg-1 Received: from smtp.corp.redhat.com (int-mx07.intmail.prod.int.phx2.redhat.com [10.5.11.22]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mimecast-mx01.redhat.com (Postfix) with ESMTPS id 05BEC1030C20; Tue, 23 Nov 2021 23:03:48 +0000 (UTC) Received: from colo-mx.corp.redhat.com (colo-mx02.intmail.prod.int.phx2.redhat.com [10.5.11.21]) by smtp.corp.redhat.com (Postfix) with ESMTPS id B03451042B7F; Tue, 23 Nov 2021 23:03:47 +0000 (UTC) Received: from lists01.pubmisc.prod.ext.phx2.redhat.com (lists01.pubmisc.prod.ext.phx2.redhat.com [10.5.19.33]) by colo-mx.corp.redhat.com (Postfix) with ESMTP id 34BCF4A703; Tue, 23 Nov 2021 23:03:47 +0000 (UTC) Received: from smtp.corp.redhat.com (int-mx06.intmail.prod.int.rdu2.redhat.com [10.11.54.6]) by lists01.pubmisc.prod.ext.phx2.redhat.com (8.13.8/8.13.8) with ESMTP id 1ANN2Ucm026506 for ; Tue, 23 Nov 2021 18:02:30 -0500 Received: by smtp.corp.redhat.com (Postfix) id 611F72166B3F; Tue, 23 Nov 2021 23:02:30 +0000 (UTC) Received: from mimecast-mx02.redhat.com (mimecast05.extmail.prod.ext.rdu2.redhat.com [10.11.55.21]) by smtp.corp.redhat.com (Postfix) with ESMTPS id 5C6382166B2D for ; Tue, 23 Nov 2021 23:02:27 +0000 (UTC) Received: from us-smtp-1.mimecast.com (us-smtp-delivery-1.mimecast.com [207.211.31.120]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mimecast-mx02.redhat.com (Postfix) with ESMTPS id 6921480A0AB for ; Tue, 23 Nov 2021 23:02:27 +0000 (UTC) Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id us-mta-487-8T1rku49MpSPhGDfYplWLg-1; Tue, 23 Nov 2021 18:02:23 -0500 X-MC-Unique: 8T1rku49MpSPhGDfYplWLg-1 Received: by mail.kernel.org (Postfix) with ESMTPSA id 8792A60F9F; Tue, 23 Nov 2021 23:02:22 +0000 (UTC) Date: Tue, 23 Nov 2021 15:02:22 -0800 From: "Darrick J. Wong" To: Christoph Hellwig Message-ID: <20211123230222.GS266024@magnolia> References: <20211109083309.584081-1-hch@lst.de> <20211109083309.584081-25-hch@lst.de> MIME-Version: 1.0 In-Reply-To: <20211109083309.584081-25-hch@lst.de> X-Mimecast-Impersonation-Protect: Policy=CLT - Impersonation Protection Definition; Similar Internal Domain=false; Similar Monitored External Domain=false; Custom External Domain=false; Mimecast External Domain=false; Newly Observed Domain=false; Internal User Name=false; Custom Display Name List=false; Reply-to Address Mismatch=false; Targeted Threat Dictionary=false; Mimecast Threat Dictionary=false; Custom Threat Dictionary=false X-Scanned-By: MIMEDefang 2.78 on 10.11.54.6 X-loop: dm-devel@redhat.com Cc: nvdimm@lists.linux.dev, Mike Snitzer , linux-s390@vger.kernel.org, linux-erofs@lists.ozlabs.org, virtualization@lists.linux-foundation.org, linux-xfs@vger.kernel.org, dm-devel@redhat.com, linux-fsdevel@vger.kernel.org, Dan Williams , linux-ext4@vger.kernel.org, Ira Weiny Subject: Re: [dm-devel] [PATCH 24/29] xfs: use xfs_direct_write_iomap_ops for DAX zeroing X-BeenThere: dm-devel@redhat.com X-Mailman-Version: 2.1.12 Precedence: junk List-Id: device-mapper development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: dm-devel-bounces@redhat.com Errors-To: dm-devel-bounces@redhat.com X-Scanned-By: MIMEDefang 2.84 on 10.5.11.22 Authentication-Results: relay.mimecast.com; auth=pass smtp.auth=CUSA124A263 smtp.mailfrom=dm-devel-bounces@redhat.com X-Mimecast-Spam-Score: 0 X-Mimecast-Originator: redhat.com Content-Disposition: inline Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit On Tue, Nov 09, 2021 at 09:33:04AM +0100, Christoph Hellwig wrote: > While the buffered write iomap ops do work due to the fact that zeroing > never allocates blocks, the DAX zeroing should use the direct ops just > like actual DAX I/O. > > Signed-off-by: Christoph Hellwig Heh. I've wanted to fix this for a long time, but I like your surrounding cleanups better than anything I had time to work on. :) Reviewed-by: Darrick J. Wong --D > --- > fs/xfs/xfs_iomap.c | 4 ++-- > 1 file changed, 2 insertions(+), 2 deletions(-) > > diff --git a/fs/xfs/xfs_iomap.c b/fs/xfs/xfs_iomap.c > index 8cef3b68cba78..704292c6ce0c7 100644 > --- a/fs/xfs/xfs_iomap.c > +++ b/fs/xfs/xfs_iomap.c > @@ -1324,7 +1324,7 @@ xfs_zero_range( > > if (IS_DAX(inode)) > return dax_zero_range(inode, pos, len, did_zero, > - &xfs_buffered_write_iomap_ops); > + &xfs_direct_write_iomap_ops); > return iomap_zero_range(inode, pos, len, did_zero, > &xfs_buffered_write_iomap_ops); > } > @@ -1339,7 +1339,7 @@ xfs_truncate_page( > > if (IS_DAX(inode)) > return dax_truncate_page(inode, pos, did_zero, > - &xfs_buffered_write_iomap_ops); > + &xfs_direct_write_iomap_ops); > return iomap_truncate_page(inode, pos, did_zero, > &xfs_buffered_write_iomap_ops); > } > -- > 2.30.2 > -- dm-devel mailing list dm-devel@redhat.com https://listman.redhat.com/mailman/listinfo/dm-devel From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from lists.ozlabs.org (lists.ozlabs.org [112.213.38.117]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 54F2BC433F5 for ; Tue, 23 Nov 2021 23:02:30 +0000 (UTC) Received: from boromir.ozlabs.org (localhost [IPv6:::1]) by lists.ozlabs.org (Postfix) with ESMTP id 4HzKR8390mz2ync for ; Wed, 24 Nov 2021 10:02:28 +1100 (AEDT) Authentication-Results: lists.ozlabs.org; dkim=fail reason="signature verification failed" (2048-bit key; unprotected) header.d=kernel.org header.i=@kernel.org header.a=rsa-sha256 header.s=k20201202 header.b=DGGP2Hw/; dkim-atps=neutral Authentication-Results: lists.ozlabs.org; spf=pass (sender SPF authorized) smtp.mailfrom=kernel.org (client-ip=198.145.29.99; helo=mail.kernel.org; envelope-from=djwong@kernel.org; receiver=) Authentication-Results: lists.ozlabs.org; dkim=pass (2048-bit key; unprotected) header.d=kernel.org header.i=@kernel.org header.a=rsa-sha256 header.s=k20201202 header.b=DGGP2Hw/; dkim-atps=neutral Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by lists.ozlabs.org (Postfix) with ESMTPS id 4HzKR452drz2yLJ for ; Wed, 24 Nov 2021 10:02:24 +1100 (AEDT) Received: by mail.kernel.org (Postfix) with ESMTPSA id 8792A60F9F; Tue, 23 Nov 2021 23:02:22 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1637708542; bh=GS50QTQfJ1+ToyzIbpu55dsHnRqqv0iWy7BBdE0JB2I=; h=Date:From:To:Cc:Subject:References:In-Reply-To:From; b=DGGP2Hw/qt0fg0TjTYCkjZem7cLOTvAV+sYzt/gGFNVpe5YlzxKjG2+IdmBZqgOp0 Tn14P64ZEMV4gebCdVgbL7CaMTp+X8CNJrxr0ZVMCKYY6k5XfA/+4EzCTh12rE7uwK fCo9ojaHmUFP3YFJWseiNw+SOmYbzBfz0SuuRHu/QcvKfxVhoRr5CXwdiB9KihiSTE OKdQ61mK9QOijxi5EjdC2NztG+GMSG+wrxjmHQLzMdOkMzK9cncUXf/Q/FakS6kyUJ su7FZZvTzHx1x8UJK7RJy9zA4zSLjCAN5QyeSRSJcE6pP1ZNqQvF4CqnWs+kY5B/nw RYEu1hk9aGLJQ== Date: Tue, 23 Nov 2021 15:02:22 -0800 From: "Darrick J. Wong" To: Christoph Hellwig Subject: Re: [PATCH 24/29] xfs: use xfs_direct_write_iomap_ops for DAX zeroing Message-ID: <20211123230222.GS266024@magnolia> References: <20211109083309.584081-1-hch@lst.de> <20211109083309.584081-25-hch@lst.de> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20211109083309.584081-25-hch@lst.de> X-BeenThere: linux-erofs@lists.ozlabs.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Development of Linux EROFS file system List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: nvdimm@lists.linux.dev, Mike Snitzer , linux-s390@vger.kernel.org, linux-erofs@lists.ozlabs.org, virtualization@lists.linux-foundation.org, linux-xfs@vger.kernel.org, dm-devel@redhat.com, linux-fsdevel@vger.kernel.org, Dan Williams , linux-ext4@vger.kernel.org, Ira Weiny Errors-To: linux-erofs-bounces+linux-erofs=archiver.kernel.org@lists.ozlabs.org Sender: "Linux-erofs" On Tue, Nov 09, 2021 at 09:33:04AM +0100, Christoph Hellwig wrote: > While the buffered write iomap ops do work due to the fact that zeroing > never allocates blocks, the DAX zeroing should use the direct ops just > like actual DAX I/O. > > Signed-off-by: Christoph Hellwig Heh. I've wanted to fix this for a long time, but I like your surrounding cleanups better than anything I had time to work on. :) Reviewed-by: Darrick J. Wong --D > --- > fs/xfs/xfs_iomap.c | 4 ++-- > 1 file changed, 2 insertions(+), 2 deletions(-) > > diff --git a/fs/xfs/xfs_iomap.c b/fs/xfs/xfs_iomap.c > index 8cef3b68cba78..704292c6ce0c7 100644 > --- a/fs/xfs/xfs_iomap.c > +++ b/fs/xfs/xfs_iomap.c > @@ -1324,7 +1324,7 @@ xfs_zero_range( > > if (IS_DAX(inode)) > return dax_zero_range(inode, pos, len, did_zero, > - &xfs_buffered_write_iomap_ops); > + &xfs_direct_write_iomap_ops); > return iomap_zero_range(inode, pos, len, did_zero, > &xfs_buffered_write_iomap_ops); > } > @@ -1339,7 +1339,7 @@ xfs_truncate_page( > > if (IS_DAX(inode)) > return dax_truncate_page(inode, pos, did_zero, > - &xfs_buffered_write_iomap_ops); > + &xfs_direct_write_iomap_ops); > return iomap_truncate_page(inode, pos, did_zero, > &xfs_buffered_write_iomap_ops); > } > -- > 2.30.2 > From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 83122C433FE for ; Tue, 23 Nov 2021 23:02:24 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S233244AbhKWXFc (ORCPT ); Tue, 23 Nov 2021 18:05:32 -0500 Received: from mail.kernel.org ([198.145.29.99]:58924 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S232959AbhKWXFb (ORCPT ); Tue, 23 Nov 2021 18:05:31 -0500 Received: by mail.kernel.org (Postfix) with ESMTPSA id 8792A60F9F; Tue, 23 Nov 2021 23:02:22 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1637708542; bh=GS50QTQfJ1+ToyzIbpu55dsHnRqqv0iWy7BBdE0JB2I=; h=Date:From:To:Cc:Subject:References:In-Reply-To:From; b=DGGP2Hw/qt0fg0TjTYCkjZem7cLOTvAV+sYzt/gGFNVpe5YlzxKjG2+IdmBZqgOp0 Tn14P64ZEMV4gebCdVgbL7CaMTp+X8CNJrxr0ZVMCKYY6k5XfA/+4EzCTh12rE7uwK fCo9ojaHmUFP3YFJWseiNw+SOmYbzBfz0SuuRHu/QcvKfxVhoRr5CXwdiB9KihiSTE OKdQ61mK9QOijxi5EjdC2NztG+GMSG+wrxjmHQLzMdOkMzK9cncUXf/Q/FakS6kyUJ su7FZZvTzHx1x8UJK7RJy9zA4zSLjCAN5QyeSRSJcE6pP1ZNqQvF4CqnWs+kY5B/nw RYEu1hk9aGLJQ== Date: Tue, 23 Nov 2021 15:02:22 -0800 From: "Darrick J. Wong" To: Christoph Hellwig Cc: Dan Williams , Mike Snitzer , Ira Weiny , dm-devel@redhat.com, linux-xfs@vger.kernel.org, nvdimm@lists.linux.dev, linux-s390@vger.kernel.org, linux-fsdevel@vger.kernel.org, linux-erofs@lists.ozlabs.org, linux-ext4@vger.kernel.org, virtualization@lists.linux-foundation.org Subject: Re: [PATCH 24/29] xfs: use xfs_direct_write_iomap_ops for DAX zeroing Message-ID: <20211123230222.GS266024@magnolia> References: <20211109083309.584081-1-hch@lst.de> <20211109083309.584081-25-hch@lst.de> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20211109083309.584081-25-hch@lst.de> Precedence: bulk List-ID: X-Mailing-List: linux-ext4@vger.kernel.org On Tue, Nov 09, 2021 at 09:33:04AM +0100, Christoph Hellwig wrote: > While the buffered write iomap ops do work due to the fact that zeroing > never allocates blocks, the DAX zeroing should use the direct ops just > like actual DAX I/O. > > Signed-off-by: Christoph Hellwig Heh. I've wanted to fix this for a long time, but I like your surrounding cleanups better than anything I had time to work on. :) Reviewed-by: Darrick J. Wong --D > --- > fs/xfs/xfs_iomap.c | 4 ++-- > 1 file changed, 2 insertions(+), 2 deletions(-) > > diff --git a/fs/xfs/xfs_iomap.c b/fs/xfs/xfs_iomap.c > index 8cef3b68cba78..704292c6ce0c7 100644 > --- a/fs/xfs/xfs_iomap.c > +++ b/fs/xfs/xfs_iomap.c > @@ -1324,7 +1324,7 @@ xfs_zero_range( > > if (IS_DAX(inode)) > return dax_zero_range(inode, pos, len, did_zero, > - &xfs_buffered_write_iomap_ops); > + &xfs_direct_write_iomap_ops); > return iomap_zero_range(inode, pos, len, did_zero, > &xfs_buffered_write_iomap_ops); > } > @@ -1339,7 +1339,7 @@ xfs_truncate_page( > > if (IS_DAX(inode)) > return dax_truncate_page(inode, pos, did_zero, > - &xfs_buffered_write_iomap_ops); > + &xfs_direct_write_iomap_ops); > return iomap_truncate_page(inode, pos, did_zero, > &xfs_buffered_write_iomap_ops); > } > -- > 2.30.2 >