Received: by 2002:a05:6358:3188:b0:123:57c1:9b43 with SMTP id q8csp2544549rwd; Fri, 9 Jun 2023 12:56:53 -0700 (PDT) X-Google-Smtp-Source: ACHHUZ5J5inwErMX21uNyj0DD2kUDy1Ryzphs/rCFZDFklCH9X4wZCidLwmHbT9qtdh0uFl59/qQ X-Received: by 2002:a17:90a:190d:b0:259:43e1:c81e with SMTP id 13-20020a17090a190d00b0025943e1c81emr3157562pjg.12.1686340612718; Fri, 09 Jun 2023 12:56:52 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1686340612; cv=none; d=google.com; s=arc-20160816; b=sKGMvbVoncWkPBqJr2kMiFlfcFut/aDD8lXZ/R0W0K1fL0J0mazNf4OykD3Vkv/e1j Ljl/O1q1Ug2SvDrrAj1i2FP8cKlx0jg4hX3dLGktvQ83LEXupeYu9kODI0BL/eU/K0vD a+L873Rhjfu3gcl+NPppZc8VbVufYDWnGyDfRxTsAMGXA7QnAsFcxn/CTFw1DpNa6Yi4 f4ynrhuVSV1EDfS+ZOk4Er0wM60vz0S4WaRDLmE1CJwHraAXQ0Ew9p6SwTm108E/W5IP AM40DZstUYuWJQ1WUy+LyDGLFP3ZI+Xvn3IqIFpfZ+8cqWiK96d2LHQmUvGzlSYFg0pM mOdQ== 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=lusZ+n63tKGbL0NLAwyLdzJ9q5GPTx8lfmxKN/LB0PY=; b=vueTmCCB5vzdIaQ+JXRGVhLWKjIrnE1PkG329EnR7tePhLHJfDvcJVcT+uf2X1tv7r LuNd15VeUcqQkSrfUZtXlmHmCZW2tT0dfq/bLW+Lp8p3NCl6p40G8K1GFyANB3uFt05k 8dlSII4uKP//xYNP2buK3LxFVs7WLKDBK0UAj6PSgvlHQijk2/BvFs0bhyw+GdGCO5We TWF+Oza3LpkCwErH3U74Seu9V0aLYzXjvDSG+adgieV5VOR/x9/TEuTiFfDtkOQ+Aswm LpmFkerjlZVRDnXp5GRfZdyJ+Q7VKbAhRiDPWaJ50u2MYGACGB9mYqUgYQ4c4MtF7gFx i1Ug== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@infradead.org header.s=casper.20170209 header.b=CNfhC6+W; 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 Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id k137-20020a636f8f000000b00543a6b76431si517620pgc.326.2023.06.09.12.56.39; Fri, 09 Jun 2023 12:56:52 -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=@infradead.org header.s=casper.20170209 header.b=CNfhC6+W; 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 Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S231789AbjFIThx (ORCPT + 99 others); Fri, 9 Jun 2023 15:37:53 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:44468 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229517AbjFIThw (ORCPT ); Fri, 9 Jun 2023 15:37:52 -0400 Received: from casper.infradead.org (casper.infradead.org [IPv6:2001:8b0:10b:1236::1]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 27386E0; Fri, 9 Jun 2023 12:37:51 -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=lusZ+n63tKGbL0NLAwyLdzJ9q5GPTx8lfmxKN/LB0PY=; b=CNfhC6+WyPlV8tbFcjbN0TEnbz dLYLnJhghcLMBiB+AgpZ+6tvYAU+jvfv/ohGWsHslgWuDKY0TQHqBY76FBp+4BukmWSGPC3pmxIsG m7XyIZHxWmmF4+rQdH0MclhhopxKtiWggD5WFChzDKTULUh35ze6FQKnWjYPAEeJLNNjXZ8sdErHA 8MIVtuOjD2fnDUYqjiiWnaLLJcpa4G4rgV8ajNQVt/y/JiYjoMrslA4llfYW00daPRVQaU8FMh4zK GD3x+k4C3yQdikVVx2Z0k3ylJa1Eh0PBj+FZTTfqbE/sZoIR/a2XcysQ32fJkX5x2MY9E5+4KehvZ x4pWS85Q==; Received: from willy by casper.infradead.org with local (Exim 4.94.2 #2 (Red Hat Linux)) id 1q7hun-00GxfZ-V3; Fri, 09 Jun 2023 19:36:53 +0000 Date: Fri, 9 Jun 2023 20:36:53 +0100 From: Matthew Wilcox To: Suren Baghdasaryan Cc: akpm@linux-foundation.org, hannes@cmpxchg.org, mhocko@suse.com, josef@toxicpanda.com, jack@suse.cz, ldufour@linux.ibm.com, laurent.dufour@fr.ibm.com, michel@lespinasse.org, liam.howlett@oracle.com, jglisse@google.com, vbabka@suse.cz, minchan@google.com, dave@stgolabs.net, punit.agrawal@bytedance.com, lstoakes@gmail.com, hdanton@sina.com, apopple@nvidia.com, peterx@redhat.com, ying.huang@intel.com, david@redhat.com, yuzhao@google.com, dhowells@redhat.com, hughd@google.com, viro@zeniv.linux.org.uk, brauner@kernel.org, pasha.tatashin@soleen.com, linux-mm@kvack.org, linux-fsdevel@vger.kernel.org, linux-kernel@vger.kernel.org, kernel-team@android.com Subject: Re: [PATCH v2 5/6] mm: implement folio wait under VMA lock Message-ID: References: <20230609005158.2421285-1-surenb@google.com> <20230609005158.2421285-6-surenb@google.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,URIBL_BLOCKED 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-kernel@vger.kernel.org On Fri, Jun 09, 2023 at 11:55:29AM -0700, Suren Baghdasaryan wrote: > Oh, after rereading I think you are suggesting to replace > folio_lock_or_retry()/__folio_lock_or_retry() with > folio_lock_fault()/__folio_lock_fault(), not to add them. Is that > right? Right. It only has two callers. And I'd do that before adding the FAULT_VMA_LOCK handling to it.