Received: by 2002:a05:6358:9144:b0:117:f937:c515 with SMTP id r4csp6886897rwr; Tue, 2 May 2023 06:55:33 -0700 (PDT) X-Google-Smtp-Source: ACHHUZ4gDzCamZWGooOGJXffubjL0qwDH6Im7D87lAf+7Y8W1AdsC2MsH3djyVfAY+fS6x4aOSHq X-Received: by 2002:a17:903:1382:b0:1aa:fd48:f5e2 with SMTP id jx2-20020a170903138200b001aafd48f5e2mr4798224plb.32.1683035732908; Tue, 02 May 2023 06:55:32 -0700 (PDT) ARC-Seal: i=2; a=rsa-sha256; t=1683035732; cv=pass; d=google.com; s=arc-20160816; b=Pj58AVcg5j+B73+BIQBztcPVVyWdBhsERuqvviZi7GSvCtm0LBP7J88L/1CzeLg8pL bL/CweE3TwLrzYLY0hAF6QWM1r4zvsEAzNcb8ViUWt5OwXDIvJeUdY5LfWiDgvPPI/ux tKEv8UWzXcXitdoLeF9nnzd1bpNCTRWRvSNE7AHBqjNnccpPiknORLNSgfi7xxCjCaPl RTq7j+j81zovq8Xkalqp3FGcwafuLeArNADu7/PnF45CHIZs5KBaqFRiiZdC+ALgcIOt A88fKzO9vctvvT7oYEC2u7V6ltvzqZMxx3kAf6mMDCtKOOEz+QwLUgIcgS21R8BHQl9g Bpww== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:mime-version:in-reply-to:content-disposition :references:message-id:subject:cc:to:from:date:dkim-signature; bh=lDTBnVrE1AVnGhJc0W5eeVhuAe7pnI+KUoY3IACpHM4=; b=CWEYFl8RMKNMr26JYDMH5TzML/OacLH+rOYbA/SN/0yKR39OsWElHzOIPTiP16X95b XzRgM8yEB+bvqV5M8RC4sokGQ5IJX4/AHUrVEdYgOF2XXJ8VW2YVQOj0cCAoo51h7g/1 1UpauVxZ3VjfeQczSFwYTlaLJjfuTk65ffeJ8s9DOAHnYG+Hzo9pPD9sf1ph1tYvWrjN tta0yAI9SXyyVcvLZwsBElOLy+t5+jPFijeKTRJPOuXUAm0R1M0spXuUz3AB/dwqRxya AwKcqXz75K4UJtR7bNZktGVonkZF2Fe24tEkoWjMUhHY3CGSCN3PjP9/9UaDz7iZqvFn bSgw== ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@Nvidia.com header.s=selector2 header.b=UABZPazu; arc=pass (i=1 spf=pass spfdomain=nvidia.com dkim=pass dkdomain=nvidia.com dmarc=pass fromdomain=nvidia.com); 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=REJECT sp=REJECT dis=NONE) header.from=nvidia.com Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id i7-20020a17090a974700b0024ba8621f82si23730664pjw.172.2023.05.02.06.55.18; Tue, 02 May 2023 06:55: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=@Nvidia.com header.s=selector2 header.b=UABZPazu; arc=pass (i=1 spf=pass spfdomain=nvidia.com dkim=pass dkdomain=nvidia.com dmarc=pass fromdomain=nvidia.com); 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=REJECT sp=REJECT dis=NONE) header.from=nvidia.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S234406AbjEBNvH (ORCPT + 99 others); Tue, 2 May 2023 09:51:07 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:49490 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S234196AbjEBNvF (ORCPT ); Tue, 2 May 2023 09:51:05 -0400 Received: from NAM10-DM6-obe.outbound.protection.outlook.com (mail-dm6nam10on2084.outbound.protection.outlook.com [40.107.93.84]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 0E007ED; Tue, 2 May 2023 06:51:02 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=PCh1srkLKlLKofa84a28whfTxtC2m9GwDqUriAwAHfkxrdVtCEJmfDHoGFYU34rXcStJclwhcMovS/DMTBZZckIh7I4zE3ml10U4q+rY0kbR6Mkl12uOramTcpJtC7gUkMkB17/sE4GFFyVKIHvmzvhJzgpDh+PFsHvsQ1BFUUhIkevgzl3u8JNuTE28sfMbcBFkcG/1YDYabXAMmAudDs5UUWbDz301eoUh3ClEUwh81FRjwbHSj9bxn/slVEO1qcwB+Y+7i6kKiWfMoDYHwxoXEaaSA9TWv6w6L2Yj+1N6tXdGO297GXQb6EJhB8HN9PPd6XUZju/uNFLdOhFFEw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=lDTBnVrE1AVnGhJc0W5eeVhuAe7pnI+KUoY3IACpHM4=; b=GeWThYnrV2N+pMmjUmio2xbe8c9Q5Ij9VCklcLIRQv7hrGIO/Fyf4G+9YRYXWgpi79DiqMNCiVoGARDaM6dy+Y78+bownia1t1UUR8bKQ7jcJQyW+14oZ9Urz73Ul9zKBTQLLlDBos0XYYnF9dUtlIjuOU7Zd2wTK9GXdQuU8VoEBGXNX+WrwIs2PRtyGvQhNORsice0pT14fPYspZACdIBT218tKDTxEhPHNCDHhKpWJALI7rBSJOyMJzox8kzRaBDBVAXKTO8ENEn54isfe3feKk0i4VfH5lh4ksitEDvU05DCgASuKsBbSaCpOca4lkPDoWRN+38zcOdTVVJLRA== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=nvidia.com; dmarc=pass action=none header.from=nvidia.com; dkim=pass header.d=nvidia.com; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=Nvidia.com; s=selector2; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=lDTBnVrE1AVnGhJc0W5eeVhuAe7pnI+KUoY3IACpHM4=; b=UABZPazuOn3gEjNzYeS7DmbyY4/ZIKVeI3TlliuTKxYYzPNPMPkeWmLsvHn85p8KqzUuRns07bEHQ5UO/Bfdlq/01+EkZmgLd1J7DOlNgnWUccyHmstXqH9Dr06ztD07UJZdmO/209+MTBrBW3X8LseC8K33zQ6aHi2z1dSiQ77dDZvsgfSQhcJssK7EnVuay6hBb6bswu2b/F2aD1bFPa1bFyZm/RgI0wVUTWdMEEPN7kEK2crupCYUx8AbJglu+iBNeXTCRQVdD5TgOMBbiChYuJHiJY5MjymEgYdavVXa6vuCJp41MpTEu+fsFbPZHsAnhg/mnyt1R1NGPrR5/g== Authentication-Results: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=nvidia.com; Received: from LV2PR12MB5869.namprd12.prod.outlook.com (2603:10b6:408:176::16) by PH0PR12MB7012.namprd12.prod.outlook.com (2603:10b6:510:21c::20) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.6340.31; Tue, 2 May 2023 13:50:59 +0000 Received: from LV2PR12MB5869.namprd12.prod.outlook.com ([fe80::f7a7:a561:87e9:5fab]) by LV2PR12MB5869.namprd12.prod.outlook.com ([fe80::f7a7:a561:87e9:5fab%6]) with mapi id 15.20.6340.030; Tue, 2 May 2023 13:50:59 +0000 Date: Tue, 2 May 2023 10:50:58 -0300 From: Jason Gunthorpe To: David Hildenbrand Cc: Matthew Rosato , Christian Borntraeger , Lorenzo Stoakes , linux-mm@kvack.org, linux-kernel@vger.kernel.org, Andrew Morton , Jens Axboe , Matthew Wilcox , Dennis Dalessandro , Leon Romanovsky , Christian Benvenuti , Nelson Escobar , Bernard Metzler , Peter Zijlstra , Ingo Molnar , Arnaldo Carvalho de Melo , Mark Rutland , Alexander Shishkin , Jiri Olsa , Namhyung Kim , Ian Rogers , Adrian Hunter , Bjorn Topel , Magnus Karlsson , Maciej Fijalkowski , Jonathan Lemon , "David S . Miller" , Eric Dumazet , Jakub Kicinski , Paolo Abeni , Christian Brauner , Richard Cochran , Alexei Starovoitov , Daniel Borkmann , Jesper Dangaard Brouer , John Fastabend , linux-fsdevel@vger.kernel.org, linux-perf-users@vger.kernel.org, netdev@vger.kernel.org, bpf@vger.kernel.org, Oleg Nesterov , John Hubbard , Jan Kara , "Kirill A . Shutemov" , Pavel Begunkov , Mika Penttila , Dave Chinner , Theodore Ts'o , Peter Xu Subject: Re: [PATCH v6 3/3] mm/gup: disallow FOLL_LONGTERM GUP-fast writing to file-backed mappings Message-ID: References: <7d56b424-ba79-4b21-b02c-c89705533852@lucifer.local> Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: X-ClientProxiedBy: BLAPR03CA0110.namprd03.prod.outlook.com (2603:10b6:208:32a::25) To LV2PR12MB5869.namprd12.prod.outlook.com (2603:10b6:408:176::16) MIME-Version: 1.0 X-MS-PublicTrafficType: Email X-MS-TrafficTypeDiagnostic: LV2PR12MB5869:EE_|PH0PR12MB7012:EE_ X-MS-Office365-Filtering-Correlation-Id: c1dccf04-bcc1-40b0-1f24-08db4b144266 X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: HEIgO10zT/RXASXzrLZFMzaiKU4Mq1aHXtPh+7K9zIF3nECChMSKxRWoCPpJk1bXLTt8HLfJbnRJYZbTbIX1Su0Z3i5+xWZfEWmkou99HrVr5SODlDtBh7wX0NRVam6I/2sdfIsCycig4d8vtfgHRrMfKQUA/0vWUaDmS0vHUNbHep7jcrQldYqJchTZBYfekePAnNj3P5+L5/NtK9MPmM3F7497kwJC/bb9qh8LqqWY2SaXwcwS1m1N1EybkScYqGLDm07YFbg9aKrQf/XqddSrFxiuul+lwgTCvv/qIrOgfdjTVw2C16EzM8s5E8hjH4YeQFFok9ShZFcUOctTgbZcrefJCZKsXQRBHPZg8aEC/6va7V35HD8y81peYaXdj6Ne7/kAU1vBIhPwHB+yYIthclPjBye4qkgN6nbX7252E9w5LyD7h7nlYw3NlOf9Em18HL9tnUbP1sqt+ypXVfEgsDwprxDFgSW5VAr9ZI0GZDeTwYA3/Tlmj0GX8hpj6P+muLyEXqABiA6IoCzBv0q+xdYwNh5Oz75vDLDgnhiatDttuYcr1FLYS6cscNx2 X-Forefront-Antispam-Report: CIP:255.255.255.255;CTRY:;LANG:en;SCL:1;SRV:;IPV:NLI;SFV:NSPM;H:LV2PR12MB5869.namprd12.prod.outlook.com;PTR:;CAT:NONE;SFS:(13230028)(4636009)(396003)(39860400002)(366004)(136003)(346002)(376002)(451199021)(5660300002)(2906002)(186003)(54906003)(7416002)(7406005)(8676002)(8936002)(66476007)(26005)(6512007)(6506007)(4744005)(478600001)(86362001)(6486002)(2616005)(38100700002)(36756003)(66556008)(6916009)(66946007)(316002)(41300700001)(4326008);DIR:OUT;SFP:1101; X-MS-Exchange-AntiSpam-MessageData-ChunkCount: 1 X-MS-Exchange-AntiSpam-MessageData-0: =?us-ascii?Q?mrj5DnBw1hwoUFfjXdvV/oeVoUY44Q8dLwJls//LAu+puWagrJj7mxRipwbn?= =?us-ascii?Q?nogXX2xVIoHmADPl7QnHMjXwtzHfx7FU2oFeWMGrZ5ZVwSdiDQQ5A9zFNdPC?= =?us-ascii?Q?jp0iq0aFK4eHEe6+vTUhN3bN4ktygw5/gaZGkkBsuu6WIemZs8GjSz6w8Q5i?= =?us-ascii?Q?tn7YAqGCWLSvtFYWI/qA4hoqlPeL4lWduPwQAWaVqfrFif0/UNrKLzNevm1Y?= =?us-ascii?Q?lH346iu+uRsRAhhByyNb3bTSRaxbyY0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V+dgSHjpN/mrDbYtNVHjKmBdg7ie7l9eMC0xQd6htCn6bdIPgys3CmhlTP?= =?us-ascii?Q?mRs77N+oy+kgbeMooS5G6VTJv5atBM5QnQRNKoa30+3hkUMuMf84Y0xRcY1a?= =?us-ascii?Q?bWbY/UDqvtTDLjxhMPhNGa7fl8A1GSWrngx21w5Bk2/ZA5U4rC0xknVDcGrN?= =?us-ascii?Q?hea4AMazfzxWKmMMpKVkl0aEXBIoEXK1Z5cdvOmQXhhPZ7NRpxxSajPvaCCm?= =?us-ascii?Q?xAJziv4lCV1A49krBMbzvbf+h9G/Il5RT3T/QPY5XLBd5bmm2b1qCfgsgUgm?= =?us-ascii?Q?PUL/7Es+o3+LSjZYylOAO/LenLhoZRCS45YVrhiL+b5nA1s7NA45mqMgBlrk?= =?us-ascii?Q?kLUF1s3+imF4XuSyhmKSeXEVXNd1v70zk95y1hwUGVCFgAMk5z8EfhErrPZm?= =?us-ascii?Q?YA2KTzbafV9bgAAHe1eDv7YONBtI4nlUQ0cUMSzM?= X-OriginatorOrg: Nvidia.com X-MS-Exchange-CrossTenant-Network-Message-Id: c1dccf04-bcc1-40b0-1f24-08db4b144266 X-MS-Exchange-CrossTenant-AuthSource: LV2PR12MB5869.namprd12.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 02 May 2023 13:50:59.0557 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 43083d15-7273-40c1-b7db-39efd9ccc17a X-MS-Exchange-CrossTenant-MailboxType: HOSTED X-MS-Exchange-CrossTenant-UserPrincipalName: ueCrK4TS9J1krYwHAd++AdGaeE0+lgdNsuKSqeP7B2xHrt2Cfex2pM339KHYujmO X-MS-Exchange-Transport-CrossTenantHeadersStamped: PH0PR12MB7012 X-Spam-Status: No, score=-1.3 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,FORGED_SPF_HELO, RCVD_IN_DNSWL_NONE,RCVD_IN_MSPIKE_H2,SPF_HELO_PASS,SPF_NONE, T_SCC_BODY_TEXT_LINE autolearn=no 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 Tue, May 02, 2023 at 03:47:43PM +0200, David Hildenbrand wrote: > > Eventually we want to implement a mechanism where we can dynamically pin in response to RPCIT. > > Okay, so IIRC we'll fail starting the domain early, that's good. And if we > pin all guest memory (instead of small pieces dynamically), there is little > existing use for file-backed RAM in such zPCI configurations (because memory > cannot be reclaimed either way if it's all pinned), so likely there are no > real existing users. Right, this is VFIO, the physical HW can't tolerate not having pinned memory, so something somewhere is always pinning it. Which, again, makes it weird/wrong that this KVM code is pinning it again :\ Jason