Received: by 2002:a25:1985:0:0:0:0:0 with SMTP id 127csp104192ybz; Tue, 21 Apr 2020 16:16:37 -0700 (PDT) X-Google-Smtp-Source: APiQypJrHmJQvCUZc2R4/TTMlTYkWR6P7+8pCXxYSIN+NELobMwSz+oQsUQ+LMYQZIuj/jtP4Qxb X-Received: by 2002:a17:906:cd1:: with SMTP id l17mr22688422ejh.319.1587510997711; Tue, 21 Apr 2020 16:16:37 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1587510997; cv=none; d=google.com; s=arc-20160816; b=TRrHDoXdZQ0snH7nExRv47CnWEpWxHf63DX/OIRf7e3cro6XAbn8Ani5cptR+O48dQ 5asAKj6zNih4z+GnKO58Z/JQlzQtmShJu5jRh/donzxcoqktPDVpIYip06RdlB0xqbmT 5WKzLOi+yu7f6Y50xEjBN4/NpZdojNTrnSPApMnVItMSBi3d0SBXywxdSXmcfMMSRd7n ri6q5ULgpkfoZbjMdYv2oCFhxgPtP9mofup4AKBd6lVDd6XVOlJXh+iOSqqE5aXitrh4 y2ytkhqXr/Fp8kioEHdyBe3W1EN84aewDDada/1XBqzHUoh7nTDF3dB8BdD1feWhTztF AKaw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:in-reply-to:content-disposition :mime-version:references:message-id:subject:cc:to:from:date; bh=rGVAvb4/DqYIxG8iCt3hHe7amse8sHu6S9Kxg5zMRo8=; b=hDwESHT6UGG6WLLK7LwlUGkec/zcPE+fckgr860Mco0gpKi8NOro3R0b+pBE+FPOye m0lWEjKGBZRBAxlmgtEdgbhcrSHGWNccsbutIDL03BIQANuEyxbhPPvtDx30cQjAgPE2 YjFcHpiyfEZoK806n+Ze4KmIFkxfVvSnEXjovurKuSDmy3YyMnTxcnUayqIvEUGcF/GH seXIX5ElkRjOk3yQLrhdIE53zZ3Qc1o309lbzZ9KmGSOIy9uFBNdD3JrDOGYF/jsCui/ xjsvcvRbmYzBlLaqw4etPKvyNz/zNl5DwVfHTxJCWWgF23HfBMeKOTRkskEyk8PXPUcG /VIQ== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-ext4-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-ext4-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id g5si2482262edu.188.2020.04.21.16.16.13; Tue, 21 Apr 2020 16:16:37 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-ext4-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-ext4-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-ext4-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726173AbgDUXQM (ORCPT + 99 others); Tue, 21 Apr 2020 19:16:12 -0400 Received: from outgoing-auth-1.mit.edu ([18.9.28.11]:57798 "EHLO outgoing.mit.edu" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1726039AbgDUXQL (ORCPT ); Tue, 21 Apr 2020 19:16:11 -0400 Received: from callcc.thunk.org (pool-100-0-195-244.bstnma.fios.verizon.net [100.0.195.244]) (authenticated bits=0) (User authenticated as tytso@ATHENA.MIT.EDU) by outgoing.mit.edu (8.14.7/8.12.4) with ESMTP id 03LNFr6S004708 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT); Tue, 21 Apr 2020 19:15:54 -0400 Received: by callcc.thunk.org (Postfix, from userid 15806) id 78DCE42030C; Tue, 21 Apr 2020 19:15:53 -0400 (EDT) Date: Tue, 21 Apr 2020 19:15:53 -0400 From: "Theodore Y. Ts'o" To: Christoph Hellwig Cc: Jan Kara , Dave Chinner , Ritesh Harjani , bugzilla-daemon@bugzilla.kernel.org, linux-ext4@vger.kernel.org, "Darrick J. Wong" , linux-fsdevel@vger.kernel.org Subject: Re: [Bug 207367] Accraid / aptec / Microsemi / ext4 / larger then 16TB Message-ID: <20200421231553.GB4278@mit.edu> References: <20200421042039.BF8074C046@d06av22.portsmouth.uk.ibm.com> <20200421050850.GB27860@dread.disaster.area> <20200421080405.GA4149@infradead.org> <20200421162910.GB5118@quack2.suse.cz> <20200421164554.GA3271@infradead.org> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20200421164554.GA3271@infradead.org> Sender: linux-ext4-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-ext4@vger.kernel.org On Tue, Apr 21, 2020 at 09:45:54AM -0700, Christoph Hellwig wrote: > On Tue, Apr 21, 2020 at 06:29:10PM +0200, Jan Kara wrote: > > Well, there are two problems with this - firstly, ocfs2 is also using jbd2 > > and it knows nothing about iomap. So that would have to be implemented. > > Secondly, you have to somehow pass iomap ops to jbd2 so it all boils down > > to passing some callback to jbd2 during journal init to map blocks anyway > > as Dave said. And then it is upto filesystem to do the mapping - usually > > directly using its internal block mapping function - so no need for iomap > > AFAICT. > > You'll need to describe the mapping some how. So why not reuse an > existing mechanism instead of creating a new ad-hoc one? Well, we could argue that bmap() is an "existing mechanism" --- again, bmap() returns a u64, so it's perfectly fine. It's FIBMAP which is "fundamentally broken", not bmap(). If the goal is to eventually eliminate bmap() and aops->bmap(), sure, then we should force march all file systems to use iomap_bmap(), including ocfs2. Otherwise, if the goal alert users of FIBMAP when it's returning an corrutped block number, why not move the check if the block is larger than INT_MAX to ioctl_fibmap() in fs/ioctl.c, instead of in iomap_bmap()? If we can't fix this, I'm beginning to think that switching to iomap for fiemap and bmap is actually a lose for ext4. It's causing performance regressions, and now we see it's causing functionality regressions. Sure, it's saving a bit of code size, but is it really worth it to use iomap for fiemap/bmap? - Ted