Received: by 2002:a05:6902:102b:0:0:0:0 with SMTP id x11csp655259ybt; Fri, 10 Jul 2020 09:04:44 -0700 (PDT) X-Google-Smtp-Source: ABdhPJwUEERERc4p33ecDWyoHWKbwaQSYT6G1i7zD2ryB4vzar1u3vmgCr5+TH4V4H/wzbu0+aHr X-Received: by 2002:a17:906:3a0d:: with SMTP id z13mr53518535eje.109.1594397084664; Fri, 10 Jul 2020 09:04:44 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1594397084; cv=none; d=google.com; s=arc-20160816; b=KvhJ2AnCupyTxxuq4jmBk+kn1nsgwePCwB5hHoh0pQvJvzNHhzXg1y7ZplII6Nq92+ qz0blTHw5xe3tk+Q4eD/bY0atFlHn96r3wqcIxqcFIfu+jStlUZtm7sg49m0wVkL/t5T M/MWrauIST/XklU55bW1JUd7NpEc2BxpQl59ZpQxmd9zzh6UdyO7vqrfLc5nykgqA7d1 v50umtm6Uzn0Gm6AMtrA7NgzQGCv7EW4t3bmSD29exU9VEB9qKdznPv/KvgbxtxSbgwD wK3r9F7nyHIfAMCU5oO/2kX36eV2J4JaKDhnVFR8VVySz5Fiel5zUN8jzgNcF7u6QmFm 2EoA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:user-agent:in-reply-to :content-disposition:mime-version:references:message-id:subject:cc :to:from:date; bh=BEq/zzgYH5tpOJltam29+Qz7jVw4mDcljurvoTHvd84=; b=G9dWbKBPXFkYGBRgjUT5vjZ9YUmKdlP7MIRfWLN6uX2lAgyZUMeqjqTmSehv7HneaS Du6mXfKS96rybhpB/SXMrhR21vvah2xUfZ6e9EJNQ4nLPsWleMHApLXemXHUhrZOCvlH Bb2TqRqxVcMm6SqcHCypkMEQRZCsRnXY+JSEKjHBuPrCbIc7XH0AccIwTGK2S4wjkrdX TvCRHJeSVyJQ01MlFdXK2hi1vD0jNAqD/J/VfPx8e3f+bpyZonCdeZjJF96X6I7iHgGk pHLAo+PsD4USqwOgpdBpZC4uRLI36VBXgNXBngQwDuHNzdkSJ0J13ZuHk/0aQQC10Xzf t4sQ== 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 bd15si4041586edb.45.2020.07.10.09.04.13; Fri, 10 Jul 2020 09:04:44 -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 S1727999AbgGJQDm (ORCPT + 99 others); Fri, 10 Jul 2020 12:03:42 -0400 Received: from verein.lst.de ([213.95.11.211]:43859 "EHLO verein.lst.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727074AbgGJQDl (ORCPT ); Fri, 10 Jul 2020 12:03:41 -0400 Received: by verein.lst.de (Postfix, from userid 2407) id 0D7A368AEF; Fri, 10 Jul 2020 18:03:37 +0200 (CEST) Date: Fri, 10 Jul 2020 18:03:37 +0200 From: Christoph Hellwig To: Dave Chinner Cc: "Darrick J. Wong" , Matthew Wilcox , Christoph Hellwig , Goldwyn Rodrigues , linux-fsdevel@vger.kernel.org, linux-btrfs@vger.kernel.org, fdmanana@gmail.com, dsterba@suse.cz, cluster-devel@redhat.com, linux-ext4@vger.kernel.org, linux-xfs@vger.kernel.org Subject: Re: always fall back to buffered I/O after invalidation failures, was: Re: [PATCH 2/6] iomap: IOMAP_DIO_RWF_NO_STALE_PAGECACHE return if page invalidation fails Message-ID: <20200710160337.GA21808@lst.de> References: <20200707124346.xnr5gtcysuzehejq@fiona> <20200707125705.GK25523@casper.infradead.org> <20200707130030.GA13870@lst.de> <20200708065127.GM2005@dread.disaster.area> <20200708135437.GP25523@casper.infradead.org> <20200709022527.GQ2005@dread.disaster.area> <20200709160926.GO7606@magnolia> <20200709170519.GH12769@casper.infradead.org> <20200709171038.GE7625@magnolia> <20200709225936.GZ2005@dread.disaster.area> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20200709225936.GZ2005@dread.disaster.area> User-Agent: Mutt/1.5.17 (2007-11-01) Sender: linux-ext4-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-ext4@vger.kernel.org This looks sane - slightly updated version below to not bother with the ret and a few tidyups. That being said and to get back to the discussion in this thread: I think it would be saner to give up on direct I/O in case of the invalidation failure. I've cooked up a patch on top of this one (for which I had a few trivial cleanups). It is still under testing, but I'll send the two out in a new thread.