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=-5.8 required=3.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,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 918DCC433E0 for ; Wed, 10 Feb 2021 17:56:31 +0000 (UTC) Received: from kanga.kvack.org (kanga.kvack.org [205.233.56.17]) by mail.kernel.org (Postfix) with ESMTP id 054C064D9E for ; Wed, 10 Feb 2021 17:56:30 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org 054C064D9E Authentication-Results: mail.kernel.org; dmarc=none (p=none dis=none) header.from=ziepe.ca Authentication-Results: mail.kernel.org; spf=pass smtp.mailfrom=owner-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix) id 600946B0006; Wed, 10 Feb 2021 12:56:30 -0500 (EST) Received: by kanga.kvack.org (Postfix, from userid 40) id 5B12B6B006C; Wed, 10 Feb 2021 12:56:30 -0500 (EST) X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id 4A1356B006E; Wed, 10 Feb 2021 12:56:30 -0500 (EST) X-Delivered-To: linux-mm@kvack.org Received: from forelay.hostedemail.com (smtprelay0074.hostedemail.com [216.40.44.74]) by kanga.kvack.org (Postfix) with ESMTP id 34FF76B0006 for ; Wed, 10 Feb 2021 12:56:30 -0500 (EST) Received: from smtpin20.hostedemail.com (10.5.19.251.rfc1918.com [10.5.19.251]) by forelay03.hostedemail.com (Postfix) with ESMTP id E9FEC8245571 for ; Wed, 10 Feb 2021 17:56:29 +0000 (UTC) X-FDA: 77803112898.20.D2D6AA8 Received: from mail-qt1-f177.google.com (mail-qt1-f177.google.com [209.85.160.177]) by imf11.hostedemail.com (Postfix) with ESMTP id E32572000D81 for ; Wed, 10 Feb 2021 17:56:27 +0000 (UTC) Received: by mail-qt1-f177.google.com with SMTP id z32so2154294qtd.8 for ; Wed, 10 Feb 2021 09:56:29 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=ziepe.ca; s=google; h=date:from:to:cc:subject:message-id:references:mime-version :content-disposition:in-reply-to; bh=RUQ3IiEy3EeRQSWZTl5rkIVfBMl0Yr+7rUwczbTqPUI=; b=a+PshXZQLSQ7/K/9jegFaNYC0vZtmSYFRP1bDA8dbf8/musoPpHsw5fl3p1ROGJKfd BIwN8dEMPEjoYVb1yDkSYhphTXpCL9gSnrGEzHWvQCXWv29Ejjq92mz5G3Dg0KmE0XCX FeeRFLPtrUqSk8F0amJkbyHTGLQm8PvYyk+6v0OxaHba2MdI5fI0N/d0XsEh6GVU5emG /0vg6Fo5+WSy7jh21z0QKnlqdDB/yryAPmpCWW8UUSaCKsVbVpQw7LWKFor1C0y7OngB hQc5Rc67W3FeJVpxVwzluKmOqtnpGTOUR0RUS2WW2uLURW1Ug+7jhSO51GMEDjEjkQEH Fj+Q== 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=RUQ3IiEy3EeRQSWZTl5rkIVfBMl0Yr+7rUwczbTqPUI=; b=lhN5uR2kosfuk4C+EFkZUsCO8EVtdS7urBCD1PErIpa3O8EpoHwYa/iPpqpKab98u5 OCuSESgnwsdkD3ITgx7kHsetZHo0b2Q/I6jtMwn+cljBghMcmU1OSoPzNIyA2cWEOcrk 6M9BZMmZ8gC3rayVgx4udVkhjhuNvRHGGTNWnV926g3GAml6zuerIBZQtyFt7drO2/Qj QIGfaVpqHmskNMZ/F1ei9SsAoS52p2Cev9Mb81Za6auxnbQn7OLPb+fq8qht6mSphI4J 8R3740oOdEurnCsywspNzITUdowB0BT2jAiFXOfd+7sWc4kH4ia9NSrILXq3nowxsHJ5 coCw== X-Gm-Message-State: AOAM531bCBWZH6qXCYJzuq57GaAa7EwOW/pFXrd0mQWeLuixDCnxnPBF oVIbQFl9MzwfuVSfVHwTLV5EfA== X-Google-Smtp-Source: ABdhPJwWEC9HwbcTz58sdbmUTleaPOjsDExx3u3MJe7UYTKAqinGSmHRrRGSIqyVmc4V1t6YgU/4OQ== X-Received: by 2002:ac8:d03:: with SMTP id q3mr3814296qti.19.1612979788592; Wed, 10 Feb 2021 09:56:28 -0800 (PST) Received: from ziepe.ca (hlfxns017vw-142-162-115-133.dhcp-dynamic.fibreop.ns.bellaliant.net. [142.162.115.133]) by smtp.gmail.com with ESMTPSA id a25sm1697115qtw.87.2021.02.10.09.56.27 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 10 Feb 2021 09:56:27 -0800 (PST) Received: from jgg by mlx with local (Exim 4.94) (envelope-from ) id 1l9tj0-00686U-SC; Wed, 10 Feb 2021 13:56:26 -0400 Date: Wed, 10 Feb 2021 13:56:26 -0400 From: Jason Gunthorpe To: Jerome Glisse Cc: Alistair Popple , Daniel Vetter , Linux MM , Nouveau Dev , Ben Skeggs , Andrew Morton , Linux Doc Mailing List , Linux Kernel Mailing List , kvm-ppc@vger.kernel.org, dri-devel , John Hubbard , Ralph Campbell Subject: Re: [PATCH 0/9] Add support for SVM atomics in Nouveau Message-ID: <20210210175626.GN4718@ziepe.ca> References: <20210209010722.13839-1-apopple@nvidia.com> <3426910.QXTomnrpqD@nvdebian> <20210209133520.GB4718@ziepe.ca> <20210209211738.GA834106@redhat.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20210209211738.GA834106@redhat.com> X-Stat-Signature: wxdznxwgqu3bk4ho6aq9bbh5zta9nkiu X-Rspamd-Server: rspam05 X-Rspamd-Queue-Id: E32572000D81 Received-SPF: none (ziepe.ca>: No applicable sender policy available) receiver=imf11; identity=mailfrom; envelope-from=""; helo=mail-qt1-f177.google.com; client-ip=209.85.160.177 X-HE-DKIM-Result: pass/pass X-HE-Tag: 1612979787-549919 X-Bogosity: Ham, tests=bogofilter, spamicity=0.000000, version=1.2.4 Sender: owner-linux-mm@kvack.org Precedence: bulk X-Loop: owner-majordomo@kvack.org List-ID: On Tue, Feb 09, 2021 at 04:17:38PM -0500, Jerome Glisse wrote: > > > Yes, I would like to avoid the long term pin constraints as well if possible I > > > just haven't found a solution yet. Are you suggesting it might be possible to > > > add a callback in the page migration logic to specially deal with moving these > > > pages? > > > > How would migration even find the page? > > Migration can scan memory from physical address (isolate_migratepages_range()) > So the CPU mapping is not the only path to get to a page. I mean find out that the page is now owned by the GPU driver to tell it that it needs to migrate that reference. Normally that would go through the VMA to the mmu notifier, but with the page removed from the normal VMA it can't get to a mmu notifier or the GPU driver. Jason