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 C330AC7EE2E for ; Tue, 13 Jun 2023 05:17:36 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S239079AbjFMFRf (ORCPT ); Tue, 13 Jun 2023 01:17:35 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:36776 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S232951AbjFMFRe (ORCPT ); Tue, 13 Jun 2023 01:17:34 -0400 Received: from bombadil.infradead.org (bombadil.infradead.org [IPv6:2607:7c80:54:3::133]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id BFBA8E78 for ; Mon, 12 Jun 2023 22:17:33 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=infradead.org; s=bombadil.20210309; h=In-Reply-To:Content-Type:MIME-Version :References:Message-ID:Subject:Cc:To:From:Date:Sender:Reply-To: Content-Transfer-Encoding:Content-ID:Content-Description; bh=IrkyZ2l6feA14TmqW8ByGm4qQKANmdP+xQdjTwmwPQw=; b=w2jfBplYVi5M8yvnBZDy7NN+2i jegxZlppuHP2p7ZtfT5L+Fb37ysBj+0uv7JIhz4va5EAP38T4EcrRFn3+L/BHrB8tgg7Mf3vs8gr1 05AC5h1mZ8FFDxS5qAe4sVMIlrm+wnLcny9TGV9KGEoHxiPxl4B4GZ0vuT9wR8hlhZGErFlV+MznF i5lxz4+sm4mJCAHzKq6dRCxq1uJmVZOS0wcUw7Q+hFbj93YXRsCft0Satt/clVW2vGjsuOfDyZTp5 Wm8/O2s6y9XhyewYNeAS7NmKd6I/so7u0N+hGjHFwVNqlGxswsa+d0WuMLLl1kgccZtN7/tdqWOdW sMsag28Q==; Received: from hch by bombadil.infradead.org with local (Exim 4.96 #2 (Red Hat Linux)) id 1q8wPD-006x5H-1J; Tue, 13 Jun 2023 05:17:23 +0000 Date: Mon, 12 Jun 2023 22:17:23 -0700 From: Christoph Hellwig To: Naohiro Aota Cc: linux-btrfs@vger.kernel.org, Naohiro Aota Subject: Re: [PATCH] btrfs: zoned: do not limit delalloc size to fs_info->max_extent_size Message-ID: References: MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: X-SRS-Rewrite: SMTP reverse-path rewritten from by bombadil.infradead.org. See http://www.infradead.org/rpr.html Precedence: bulk List-ID: X-Mailing-List: linux-btrfs@vger.kernel.org On Tue, Jun 13, 2023 at 12:10:29AM +0900, Naohiro Aota wrote: > This patch reverts the delalloc size to BTRFS_MAX_EXTENT_SIZE, as it does > not directly corresponds to the size of one extent. Instead, this patch > will limit the allocation size at cow_file_range() for the zoned mode. Maybe I'm missing something, but that limitation also seems wrong or at least suboptimal. There is absolutely no problem in creating a large allocation in cow_file_range. btrfs_submit_bio will split it into max appens size chunks for I/O, and depending on if they got reordered or not we might even be able to record the entire big allocation as a single extent on disk.