From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-0.8 required=3.0 tests=DKIM_SIGNED,DKIM_VALID, HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS autolearn=no autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 0E213C2BA19 for ; Mon, 13 Apr 2020 09:42:07 +0000 (UTC) Received: from kanga.kvack.org (kanga.kvack.org [205.233.56.17]) by mail.kernel.org (Postfix) with ESMTP id BC72420575 for ; Mon, 13 Apr 2020 09:42:06 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (2048-bit key) header.d=shutemov-name.20150623.gappssmtp.com header.i=@shutemov-name.20150623.gappssmtp.com header.b="SuIpP+w+" DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org BC72420575 Authentication-Results: mail.kernel.org; dmarc=none (p=none dis=none) header.from=shutemov.name Authentication-Results: mail.kernel.org; spf=pass smtp.mailfrom=owner-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix) id 3B5D28E00F6; Mon, 13 Apr 2020 05:42:06 -0400 (EDT) Received: by kanga.kvack.org (Postfix, from userid 40) id 3663A8E0001; Mon, 13 Apr 2020 05:42:06 -0400 (EDT) X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id 27C128E00F6; Mon, 13 Apr 2020 05:42:06 -0400 (EDT) X-Delivered-To: linux-mm@kvack.org Received: from forelay.hostedemail.com (smtprelay0080.hostedemail.com [216.40.44.80]) by kanga.kvack.org (Postfix) with ESMTP id 0DBA08E0001 for ; Mon, 13 Apr 2020 05:42:06 -0400 (EDT) Received: from smtpin04.hostedemail.com (10.5.19.251.rfc1918.com [10.5.19.251]) by forelay03.hostedemail.com (Postfix) with ESMTP id C6185824556B for ; Mon, 13 Apr 2020 09:42:05 +0000 (UTC) X-FDA: 76702340610.04.robin23_86adb421f5837 X-HE-Tag: robin23_86adb421f5837 X-Filterd-Recvd-Size: 4382 Received: from mail-lj1-f178.google.com (mail-lj1-f178.google.com [209.85.208.178]) by imf06.hostedemail.com (Postfix) with ESMTP for ; Mon, 13 Apr 2020 09:42:05 +0000 (UTC) Received: by mail-lj1-f178.google.com with SMTP id k21so8144195ljh.2 for ; Mon, 13 Apr 2020 02:42:05 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=shutemov-name.20150623.gappssmtp.com; s=20150623; h=date:from:to:cc:subject:message-id:references:mime-version :content-disposition:in-reply-to; bh=5EVtSWTpW2gBZAVG9ya8rnghhWuRsTFGgq4qSDI6w6g=; b=SuIpP+w+r+qMR9OHa1Bp4wwQC6uIAMRhhzW1Rxk6cHq3gO6nqkA/hulf5DEzztSqHj wJGe77kLD8NMfLQM2zJFSUm87BD9GW75pydTfyd8u5BIoeV6jtQXVV2/pHN2Ht9uU023 y/i/hZ7v/Hf4OlnIWGwLF9DBtOGONHZQ/Cg6tUC0fKaFhcdewe1idzlJfSm6ZGvqXG0Z W2ZjDUDM39RS8HYJty0vc8/pmg/NR79rTnfgHGb1Eb2QCUFdazEtbTlht6CzuAdoHpyo XRgBuPYVHrBfi/+Yira39hWBe8qpUKC3Vx2kOh3x+YSo0wLceegv8XcUif+My7kdIy5e gWuw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:date:from:to:cc:subject:message-id:references :mime-version:content-disposition:in-reply-to; bh=5EVtSWTpW2gBZAVG9ya8rnghhWuRsTFGgq4qSDI6w6g=; b=Xh49JfQSAl3FlUbiofBGoDZeCcOdcPS/OfkP02QRnY0G6NrRxjew4Yqk0gDdGN3s95 DLbv3Ylf25zCoFLo7i1lljC8Lngkoxn4/nyBG+PmVfKWvF+4yUEpnWDoLeRQbmqpOjTZ X5wX5aQwYvW9efIdDVAg9w10luUjnYbBPph0/7FpIuTG5N1Cd5FH9mh7OyoI8plsiM6s GoocMHxEXotmJMClxyRHpKlDv7y2JBVvX8fQA4GruHZgSL/jijJdAYyiRrKg8CeASBmg Yv6/BS9+i30XlLQLE0XzJIdZmF1Q6wQD/VGhVfBIr6w0uLH5bpYOf3xwBRKpn77KzVXO zjQQ== X-Gm-Message-State: AGi0PuaSNxgogdMKO/ZMu9W/PBmxr7WePMjntr9KJoygjcoXY3rZwVvj bn34if/cBG3ou55ldzHYbe1i5BMxNcU= X-Google-Smtp-Source: APiQypIyIFcgHREegUey45rm8BQoRKlq4QMlIcs+yf0PgL2iZ92N/aJM6blxjp3mghWys2omt9d82w== X-Received: by 2002:a2e:140d:: with SMTP id u13mr1384446ljd.152.1586770923586; Mon, 13 Apr 2020 02:42:03 -0700 (PDT) Received: from box.localdomain ([86.57.175.117]) by smtp.gmail.com with ESMTPSA id a15sm6720609ljp.44.2020.04.13.02.42.02 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 13 Apr 2020 02:42:02 -0700 (PDT) Received: by box.localdomain (Postfix, from userid 1000) id 7840210230F; Mon, 13 Apr 2020 12:42:04 +0300 (+03) Date: Mon, 13 Apr 2020 12:42:04 +0300 From: "Kirill A. Shutemov" To: John Hubbard Cc: akpm@linux-foundation.org, Andrea Arcangeli , Zi Yan , Yang Shi , linux-mm@kvack.org, linux-kernel@vger.kernel.org, "Kirill A. Shutemov" Subject: Re: [PATCHv2 5/8] khugepaged: Allow to callapse a page shared across fork Message-ID: <20200413094204.a2gpsjhugy5dznjy@box> References: <20200403112928.19742-1-kirill.shutemov@linux.intel.com> <20200403112928.19742-6-kirill.shutemov@linux.intel.com> <5a57635b-ed75-8f09-6f0c-5623f557fc55@nvidia.com> <20200410155543.i66uz6pbynfvkhak@box> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: X-Bogosity: Ham, tests=bogofilter, spamicity=0.000167, version=1.2.4 Sender: owner-linux-mm@kvack.org Precedence: bulk X-Loop: owner-majordomo@kvack.org List-ID: On Fri, Apr 10, 2020 at 01:59:22PM -0700, John Hubbard wrote: > I think I understood what you were saying. The problem is that was ignoring > a couple of points, especially in an RDMA situation: 1) the page can be > pinned by various drivers, on behalf of other processes, even if the original > process is being torn down, and 2) it doesn't really matter which process pins > a page--the end result is that it's pinned. Well, no. It is critical that nobody gets new pins after this point on behalf of *this* process as we about change what is mapped on this virtual address range. We must avoid the situation that khugepaged screws legitimate GUP users and make what process see differs from what GUP see. Pins on behalf of other processes after the point are not relevant to us. I will keep the comment as is for now. As you can see I'm struggling communicating my point. Any better wording is welcome. -- Kirill A. Shutemov