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 BB1D5C433EF for ; Mon, 25 Apr 2022 09:19:47 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S234738AbiDYJWc (ORCPT ); Mon, 25 Apr 2022 05:22:32 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:54666 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S234278AbiDYJW0 (ORCPT ); Mon, 25 Apr 2022 05:22:26 -0400 Received: from verein.lst.de (verein.lst.de [213.95.11.211]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id A97F51FA66 for ; Mon, 25 Apr 2022 02:19:23 -0700 (PDT) Received: by verein.lst.de (Postfix, from userid 2407) id 13F2368AA6; Mon, 25 Apr 2022 11:19:21 +0200 (CEST) Date: Mon, 25 Apr 2022 11:19:20 +0200 From: Christoph Hellwig To: Qu Wenruo Cc: Christoph Hellwig , Josef Bacik , David Sterba , Qu Wenruo , Naohiro Aota , linux-btrfs@vger.kernel.org Subject: Re: [PATCH 03/10] btrfs: split btrfs_submit_data_bio Message-ID: <20220425091920.GC16446@lst.de> References: <20220425075418.2192130-1-hch@lst.de> <20220425075418.2192130-4-hch@lst.de> <62f71a43-8167-f29f-8e9f-d95bc6667e0e@gmx.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <62f71a43-8167-f29f-8e9f-d95bc6667e0e@gmx.com> User-Agent: Mutt/1.5.17 (2007-11-01) Precedence: bulk List-ID: X-Mailing-List: linux-btrfs@vger.kernel.org On Mon, Apr 25, 2022 at 05:11:15PM +0800, Qu Wenruo wrote: > > > On 2022/4/25 15:54, Christoph Hellwig wrote: >> Split btrfs_submit_data_bio into one helper for reads and one for writes. > > If we're splitting the bio mapping, wouldn't it be better to split by > read/write first, then by data/meta? > > Especially for all read bios, we use workqueue to defer to a less strict > context, which is unrelated to data/metadata. Splitting the read vs write handling entirely and not allocating a btrfs_bio for writes will be the next series after this one. You're getting ahead of me :)