Received: by 2002:a05:6358:3188:b0:123:57c1:9b43 with SMTP id q8csp10283045rwd; Wed, 21 Jun 2023 20:13:21 -0700 (PDT) X-Google-Smtp-Source: ACHHUZ5qUS6Mz7zBDuPpJJ2HmS9us14xkKBkn9kyG5bHrE02z+txRwcMFQPp7VW8/hB1uqmAUjG9 X-Received: by 2002:a9d:76d4:0:b0:6b1:383f:cb83 with SMTP id p20-20020a9d76d4000000b006b1383fcb83mr7879333otl.18.1687403601690; Wed, 21 Jun 2023 20:13:21 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1687403601; cv=none; d=google.com; s=arc-20160816; b=GD2bsCxiTMCqYusMuElDaoyYW97hilrBGKLPbeL5OkyH52/kj4V/WSpL4z2KG0yYmG brVyPWrclue5hkMvA1bwlXs8YsBmJi6eu4HdiYldFM+/f32tMwHYfT02/piNRZyh0tQR M1Qr0AusLwSrdtd6c3ZC3sSKzGvCemF3QD6AP3UGJBWDW5Xkb0nrkXmRLrhqEZEVvyTG jZ+2VBDxB4cT5eR+jw1Br7UbBLOcO+iFrcbFqRW6DJgzX3iac0yty1CzNL/MfQe9p0d0 dE8NfO7pqy38wh2StkxgbpP3+bTE788mcLKytm+HIdVtSwxGGLmuZsPZjr0m4ZrrPWK+ FcIw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:in-reply-to:content-disposition:mime-version :references:message-id:subject:cc:to:from:date:dkim-signature; bh=AtSJ4+V5YXDJtcUG1UAUgd4mT3PAUroEXWopFI1UU4s=; b=WQXhatgp6uiBnkdRozKesq3NCAnd2bByqjFTmk+U59d/ecRdu1vkIc0EvaUk3jq3zG THQ/DEmVQq9BetK/J1TYw1fff5gR68UiCJ/b7sjz5TlC6UhnV1ZyOWxJ2EGRny20oQv2 ofaoxKqlgf/AfUZXlQuI9qULOYTdNwfaN+d8jPCOuRKvO+FB1CdltYB7s3QY8/Uolcvq cb7zvJDj/ITDXjbP6ytyMnd3xp53TJB4qSzxabYOZOMQ0AJPcrVdPRgiLeFlueZp7zAp BXUyybRXoNm515IOH0YbsCeoX+OEJ7RuUoN3sXA6UbS7HG8mYdpj7grsHjOHwGjcYwhd EISQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@infradead.org header.s=casper.20170209 header.b=S+UdIInq; spf=pass (google.com: domain of linux-ext4-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-ext4-owner@vger.kernel.org Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id x22-20020a656ab6000000b0055217e19aa9si5564859pgu.9.2023.06.21.20.13.05; Wed, 21 Jun 2023 20:13:21 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-ext4-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@infradead.org header.s=casper.20170209 header.b=S+UdIInq; spf=pass (google.com: domain of linux-ext4-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-ext4-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229522AbjFVC4I (ORCPT + 99 others); Wed, 21 Jun 2023 22:56:08 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:45300 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229504AbjFVC4H (ORCPT ); Wed, 21 Jun 2023 22:56:07 -0400 Received: from casper.infradead.org (casper.infradead.org [IPv6:2001:8b0:10b:1236::1]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id E039BC6; Wed, 21 Jun 2023 19:56:02 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=infradead.org; s=casper.20170209; 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=AtSJ4+V5YXDJtcUG1UAUgd4mT3PAUroEXWopFI1UU4s=; b=S+UdIInqoq25X8hzomGmVbw375 h7+H+pLjVqAoHq3VHd3tTCkOXT8h35BOeeAio7Bd4nCKWWuwCBoKXjPSg2IVNZn1mI/lB+M2arwh8 eSHFVvXgrkj6IgsMSzzPMcOdMOb+jl50+mNJVA8MwOkNESteSnlMeipmMlWsCOi1eiVo/Xwe0IkCu qRw+ThrgJI7/YKYdXJYbDuOGl8KOfV8cqKslEkAsbcVgiq/hC0LXeuBgMT9rptQVoD9dQZPynnF9E nf004CvPAIEavw8olFWhHbTzu+6ZTG8CT7dvNkEXQxcstE2aYfbMauVade6OTmMWz+lkZlGA1h+hb De2d47aA==; Received: from willy by casper.infradead.org with local (Exim 4.94.2 #2 (Red Hat Linux)) id 1qCAUC-00FCyw-E3; Thu, 22 Jun 2023 02:55:52 +0000 Date: Thu, 22 Jun 2023 03:55:52 +0100 From: Matthew Wilcox To: Dave Chinner Cc: Jeremy Bongio , Ted Tso , "Darrick J . Wong" , Allison Henderson , linux-ext4@vger.kernel.org, linux-fsdevel@vger.kernel.org, linux-xfs@vger.kernel.org Subject: Re: [PATCH 0/1] iomap regression for aio dio 4k writes Message-ID: References: <20230621174114.1320834-1-bongiojp@gmail.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: X-Spam-Status: No, score=-4.4 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_MED,SPF_HELO_NONE, SPF_NONE,T_SCC_BODY_TEXT_LINE autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-ext4@vger.kernel.org On Thu, Jun 22, 2023 at 11:55:23AM +1000, Dave Chinner wrote: > Ok, so having spent a bit more thought on this away from the office > this morning, I think there is a generic way we can avoid deferring > completions for pure overwrites. OK, this is how we can, but should we? The same amount of work needs to be done, no matter whether we do it in interrupt context or workqueue context. Doing it in interrupt context has lower latency, but maybe allows us to batch up the work and so get better bandwidth. And we can't handle other interrupts while we're handling this one, so from a whole-system perspective, I think we'd rather do the work in the workqueue. Latency is important for reads, but why is it important for writes? There's such a thing as a dependent read, but writes are usually buffered and we can wait as long as we like for a write to complete.