Received: by 2002:a05:6358:3188:b0:123:57c1:9b43 with SMTP id q8csp2118144rwd; Fri, 26 May 2023 01:51:33 -0700 (PDT) X-Google-Smtp-Source: ACHHUZ4aGYJVbsCJ0GYbeYnX2qfaP5c2BpHpX4YCXyLn7q2I6xx2bP3EazAqrObnRcnHDDD0HkBv X-Received: by 2002:a05:6a21:328d:b0:10b:8221:3348 with SMTP id yt13-20020a056a21328d00b0010b82213348mr1442101pzb.50.1685091092820; Fri, 26 May 2023 01:51:32 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1685091092; cv=none; d=google.com; s=arc-20160816; b=zXMzodp+3q9AE53LbXcOeOJ1CG0rsn/UnpAEsY00VLMmZ2btSbqYkF8HaWGoYzpVv5 M7D8E1JTCSM6oujZMkjEareKH3abIo8eDxtRo0kJ6F4Au+WjKtPZ8RqOMdA40Ypkz72Q 6BBVP104ENcUjDqSz9xs8xEATZjHZuUv/xxiryJrkk6/IXJnYLvpaSeCuLVL1GtRcXu9 dS4MimW/UigBDXmHZMoQdBdGHtD3tfvWk2CkFSvprcovF+6ESLHzbnohnVvWx7bIfAo6 YXFaNFgLWmTamth9v6Vt8yHHlnIrklAjsUg7Bmh8laoeb52Vv85OhWgaiGsuVn+V88nw fDhQ== 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:dkim-signature:date; bh=yHu4Pz64nDZSjcqDec3QpKXS1/Ocd0ra+J22ys59U50=; b=QvMKf9/vdAirsWkuJ2sC4zpeXPutoXk5ojbwzDFSpYxt73/pvVI66y5Xd33yksJCml fwVCrwmigYupgpyrFXZ7bXvAciUE0v1Oj3yc9bq4yi5+gK6FzAZsSWIHvt/gyiCsRYRi f4Qi+lYi8Gn4tpep63+DbjQey4Pf7tDI9jq3LMM72tcetLjVqfXt5G4i03irO5d9nq2M 9hS/hn7K+r06PpN6zc9kRLEQghBOhU5lf1JaF0Ba7CGVSwLsb/HzkV7lTvg2b5Guy9Py Pq5yezCzLHec2Ma/62yTZ+OlGZ//SomzP+c8Va83IGaaVu4mqywOIs2whUF4ymz2tuYq Xrnw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linux.dev header.s=key1 header.b=Dt1IiiWg; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linux.dev Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id f6-20020a637546000000b0053427b6841dsi1950564pgn.337.2023.05.26.01.51.12; Fri, 26 May 2023 01:51:32 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-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=@linux.dev header.s=key1 header.b=Dt1IiiWg; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linux.dev Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S242702AbjEZIi6 (ORCPT + 99 others); Fri, 26 May 2023 04:38:58 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:40532 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S242506AbjEZIi4 (ORCPT ); Fri, 26 May 2023 04:38:56 -0400 Received: from out-26.mta1.migadu.com (out-26.mta1.migadu.com [95.215.58.26]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 157C5135 for ; Fri, 26 May 2023 01:38:50 -0700 (PDT) Date: Fri, 26 May 2023 04:38:41 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linux.dev; s=key1; t=1685090329; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: in-reply-to:in-reply-to:references:references; bh=yHu4Pz64nDZSjcqDec3QpKXS1/Ocd0ra+J22ys59U50=; b=Dt1IiiWg0fUjae2EuGVoz9gw9KLrFZ4KGWIBr2jlc7uTvzwpUT6ITWY2wRLaXZrGAQJKZZ BFBJqnkSYYmR83YZhe9VpxaGZImQK8VN/Q3ryMG8CqcsZmkq+Kp8Eq6xCl1n+f5+48lgXH D+SnRTiyC5GWq+bYGDli1ocUPAm32Dw= X-Report-Abuse: Please report any abuse attempt to abuse@migadu.com and include these headers. From: Kent Overstreet To: Christoph Hellwig Cc: Andreas =?utf-8?Q?Gr=C3=BCnbacher?= , Jan Kara , cluster-devel@redhat.com, "Darrick J . Wong" , linux-kernel@vger.kernel.org, dhowells@redhat.com, linux-bcachefs@vger.kernel.org, linux-fsdevel@vger.kernel.org, Kent Overstreet Subject: Re: [Cluster-devel] [PATCH 06/32] sched: Add task_struct->faults_disabled_mapping Message-ID: References: <20230509165657.1735798-1-kent.overstreet@linux.dev> <20230509165657.1735798-7-kent.overstreet@linux.dev> <20230510010737.heniyuxazlprrbd6@quack3> <20230523133431.wwrkjtptu6vqqh5e@quack3> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: X-Migadu-Flow: FLOW_OUT X-Spam-Status: No, score=-2.1 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,SPF_HELO_NONE,SPF_PASS, T_SCC_BODY_TEXT_LINE,URIBL_BLOCKED autolearn=unavailable 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-kernel@vger.kernel.org On Fri, May 26, 2023 at 01:10:43AM -0700, Christoph Hellwig wrote: > On Thu, May 25, 2023 at 07:20:46PM -0400, Kent Overstreet wrote: > > > > I'm absolutely not in favour to add workarounds for thes kind of locking > > > > problems to the core kernel. I already feel bad for allowing the > > > > small workaround in iomap for btrfs, as just fixing the locking back > > > > then would have avoid massive ratholing. > > > > > > Please let me know when those btrfs changes are in a presentable shape ... > > > > I would also be curious to know what btrfs needs and what the approach > > is there. > > btrfs has the extent locked, where "extent locked" is a somewhat magic > range lock that actually includes different lock bits. It does so > because it clears the page writeback bit when the data made it to the > media, but before the metadata required to find it is commited, and > the extent lock prevents it from trying to do a readpage on something > that has actually very recently been written back but not fully > commited. Once btrfs is changed to only clear the page writeback bit > once the write is fully commited like in other file systems this extra > level of locking can go away, and there are no more locks in the > readpage path that are also taken by the direct I/O code. With that > a lot of code in btrfs working around this can go away, including the > no fault direct I/O code. wow, yeah, that is not how that is supposed to work...