Received: by 2002:a05:6358:3188:b0:123:57c1:9b43 with SMTP id q8csp487138rwd; Wed, 31 May 2023 00:51:28 -0700 (PDT) X-Google-Smtp-Source: ACHHUZ6FNayQLd2oMI+eVoWwvSPOl+4n8Kasy9kHABsfF9T0nE+kS7UKZoDRniMHwzhU92qVcxMs X-Received: by 2002:aca:a953:0:b0:396:42c7:3c5 with SMTP id s80-20020acaa953000000b0039642c703c5mr2442204oie.57.1685519488480; Wed, 31 May 2023 00:51:28 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1685519488; cv=none; d=google.com; s=arc-20160816; b=CRhuacB1cILtmj1odTFYRKSrUESQczexsCeu+oOWKdcrcZ5DvRpsMSCWUUVnR6Llzl KY1IjNvZpcN7GT9JfpYL8kjnA7rgttkhWrjWNqjfTFzIkEpRfw7iX5+bw/p9kHAhFBvk HTFfAK4jQY9ztHCA3behXkFGZnhph1996EJw0TmBBBlvsYoi5vYWV6YgFX36DBo6xTYQ BL0GnuAi3EorrpBKAuPaZAvdjsCj283j0pWZhrv8HG/M4IsUZDuvSC7maNax3hTcPSNR o37V3svhwOC8fb8CKiVNTwiR8nnvlsKGmZgVY0ZP/f3j2BCrGezZbi4MeoW/c8AjCNZW tP7A== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:in-reply-to:subject :organization:from:references:cc:to:content-language:user-agent :mime-version:date:message-id:dkim-signature; bh=pu0dxF+jwnL1jQ+DhiyLdliDD3ireyhq8OENBi+96kc=; b=LAdFZ3y59yMFCe57mTBa7jhrZ4RSfHR01tkh65Tm82dZz5AMDYa7qMETVFoE/O6NGT pXH5FsA4wnxCs/TqsY/vE6G5sqF6r8J0xXee8fhxgKYPrPnmPJ/mcYoUc0LLl6gZc0Wm +mW67sYjvDUWw+1dh6zW6hgDUM86O5Z1lQG6Ojwn/JGHLMhj2FEj3MqaF+9DJVsodbzd Kyy9ByvvBImE7i2Ag3kKBN5kT0OEFdKhrLOlCBeas0fqKe/ECpw7DF3yypKHrEHAjGAk hHd5D1xSTRZYmJsWgOPvSfiCV26Q2GQauj5LNyZj0Zy6nyUz0/jRlYMXcjZrq1xySBna 34rw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@redhat.com header.s=mimecast20190719 header.b=fMh4OHxZ; 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=redhat.com Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id v23-20020a63b957000000b0053fbb2ddb4csi579163pgo.36.2023.05.31.00.51.10; Wed, 31 May 2023 00:51:28 -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=@redhat.com header.s=mimecast20190719 header.b=fMh4OHxZ; 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=redhat.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S233509AbjEaHn0 (ORCPT + 99 others); Wed, 31 May 2023 03:43:26 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:48666 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S232077AbjEaHnY (ORCPT ); Wed, 31 May 2023 03:43:24 -0400 Received: from us-smtp-delivery-124.mimecast.com (us-smtp-delivery-124.mimecast.com [170.10.133.124]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 735B3E47 for ; Wed, 31 May 2023 00:42:32 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1685518951; 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: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=pu0dxF+jwnL1jQ+DhiyLdliDD3ireyhq8OENBi+96kc=; b=fMh4OHxZJYZqhnDXp8oFtK50LNOUn3ha91Ubf2LNc9uvhGO9TSxkUQedkcbZHaJ575o+RZ POZ0P4W1FswIAixnBoBWa3PtvOoAgwxZAiMY8lciJ7vclC+teC3SdN/6SpG/HdAbcXPnwy 7meGrC3hoKbH4QzRBHvraftUFYO9f/0= Received: from mail-wr1-f70.google.com (mail-wr1-f70.google.com [209.85.221.70]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.3, cipher=TLS_AES_256_GCM_SHA384) id us-mta-618-nLx13OLMPKmAOINEbppf8g-1; Wed, 31 May 2023 03:42:30 -0400 X-MC-Unique: nLx13OLMPKmAOINEbppf8g-1 Received: by mail-wr1-f70.google.com with SMTP id ffacd0b85a97d-30af3835de5so920604f8f.0 for ; Wed, 31 May 2023 00:42:30 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1685518949; x=1688110949; h=content-transfer-encoding:in-reply-to:subject:organization:from :references:cc:to:content-language:user-agent:mime-version:date :message-id:x-gm-message-state:from:to:cc:subject:date:message-id :reply-to; bh=pu0dxF+jwnL1jQ+DhiyLdliDD3ireyhq8OENBi+96kc=; b=PZ8CeiLf/xeiikF3xEq01C9iqdhcD+WwHMm5LBGUoUwWFjXJMI6cJqMPmaViL35qPL 0ZVvYRSyLkbI5b0SJGmN6CjSrS3cb4C0gwv/5OuR1AUnW64naC1B/UaG2j5DLeyRZViu cmBWTsWFP4qp/9Uc/BAu+3HBOUu4R9YErP6v7WwAvxTSGDnYnDlbWFymuVhdXLOiV0Gr iaocPp5uhjCh73vRTiHNI0647l3XX9Sc7A/royUAeB1iaK2jJDxCCN1TjPy+swfhjflT C6w9Q5Kr2meZvMlZEz1HC4FN0cAa/fvKG2L3KJfO78NgPBr/ucEIplZuN+mYT4HjDBE7 idzQ== X-Gm-Message-State: AC+VfDzV5ykAfB9gBkaw8pw7ffU2lJyHhrHwGaVRRjpHjToqLZoKQCYX 20Zju8oYMtoODfcAXcgaxjHMm+qjI5SMwxEC7FhrNk8YS0YSR0EJ0nPc5TiyQHNnW8+5pSGtVs3 C2uKZGqfLMJaIlof9MM8hCbSZ X-Received: by 2002:adf:fac6:0:b0:30a:ea8b:4488 with SMTP id a6-20020adffac6000000b0030aea8b4488mr3243062wrs.16.1685518949147; Wed, 31 May 2023 00:42:29 -0700 (PDT) X-Received: by 2002:adf:fac6:0:b0:30a:ea8b:4488 with SMTP id a6-20020adffac6000000b0030aea8b4488mr3243049wrs.16.1685518948739; Wed, 31 May 2023 00:42:28 -0700 (PDT) Received: from ?IPV6:2003:cb:c749:cb00:fc9f:d303:d4cc:9f26? (p200300cbc749cb00fc9fd303d4cc9f26.dip0.t-ipconnect.de. [2003:cb:c749:cb00:fc9f:d303:d4cc:9f26]) by smtp.gmail.com with ESMTPSA id p12-20020adfcc8c000000b0030adfa48e1esm5812964wrj.29.2023.05.31.00.42.27 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Wed, 31 May 2023 00:42:28 -0700 (PDT) Message-ID: Date: Wed, 31 May 2023 09:42:26 +0200 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:102.0) Gecko/20100101 Thunderbird/102.10.0 Content-Language: en-US To: David Howells , Christoph Hellwig , Lorenzo Stoakes Cc: Jens Axboe , Al Viro , Matthew Wilcox , Jan Kara , Jeff Layton , Jason Gunthorpe , Logan Gunthorpe , Hillf Danton , Christian Brauner , Linus Torvalds , linux-fsdevel@vger.kernel.org, linux-block@vger.kernel.org, linux-kernel@vger.kernel.org, linux-mm@kvack.org, Andrew Morton , John Hubbard References: <20230526214142.958751-1-dhowells@redhat.com> <20230526214142.958751-3-dhowells@redhat.com> From: David Hildenbrand Organization: Red Hat Subject: Re: [PATCH v4 2/3] mm: Provide a function to get an additional pin on a page In-Reply-To: <20230526214142.958751-3-dhowells@redhat.com> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit X-Spam-Status: No, score=-2.4 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,NICE_REPLY_A, RCVD_IN_DNSWL_NONE,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-kernel@vger.kernel.org On 26.05.23 23:41, David Howells wrote: > Provide a function to get an additional pin on a page that we already have > a pin on. This will be used in fs/direct-io.c when dispatching multiple > bios to a page we've extracted from a user-backed iter rather than redoing > the extraction. > I guess this function is only used for "replicating" an existing pin, and not changing the semantics of an existing pin: something that was pinned !FOLL_LONGTERM cannot suddenly become effectively pinned FOLL_LONGTERM. Out of curiosity, could we end up passing in an anonymous page, or is this almost exclusively for pagecache+zero pages? (I rememebr John H. had a similar patch where he said it would not apply to anon pages) > Signed-off-by: David Howells > cc: Christoph Hellwig > cc: David Hildenbrand > cc: Lorenzo Stoakes > cc: Andrew Morton > cc: Jens Axboe > cc: Al Viro > cc: Matthew Wilcox > cc: Jan Kara > cc: Jeff Layton > cc: Jason Gunthorpe > cc: Logan Gunthorpe > cc: Hillf Danton > cc: Christian Brauner > cc: Linus Torvalds > cc: linux-fsdevel@vger.kernel.org > cc: linux-block@vger.kernel.org > cc: linux-kernel@vger.kernel.org > cc: linux-mm@kvack.org > --- Acked-by: David Hildenbrand -- Thanks, David / dhildenb