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.3 required=3.0 tests=BAYES_00, HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS, USER_AGENT_SANE_1 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 C0D28C4338F for ; Wed, 25 Aug 2021 12:34:34 +0000 (UTC) Received: from gabe.freedesktop.org (gabe.freedesktop.org [131.252.210.177]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id 4AEB261139 for ; Wed, 25 Aug 2021 12:34:34 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.4.1 mail.kernel.org 4AEB261139 Authentication-Results: mail.kernel.org; dmarc=none (p=none dis=none) header.from=lst.de Authentication-Results: mail.kernel.org; spf=none smtp.mailfrom=lists.freedesktop.org Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id 865966E20B; Wed, 25 Aug 2021 12:34:32 +0000 (UTC) Received: from verein.lst.de (verein.lst.de [213.95.11.211]) by gabe.freedesktop.org (Postfix) with ESMTPS id 810636E161; Wed, 25 Aug 2021 07:46:05 +0000 (UTC) Received: by verein.lst.de (Postfix, from userid 2407) id C709967357; Wed, 25 Aug 2021 09:46:02 +0200 (CEST) Date: Wed, 25 Aug 2021 09:46:02 +0200 From: Christoph Hellwig To: Alex Sierra Cc: akpm@linux-foundation.org, Felix.Kuehling@amd.com, linux-mm@kvack.org, rcampbell@nvidia.com, linux-ext4@vger.kernel.org, linux-xfs@vger.kernel.org, amd-gfx@lists.freedesktop.org, dri-devel@lists.freedesktop.org, hch@lst.de, jgg@nvidia.com, jglisse@redhat.com Subject: Re: [PATCH v1 03/14] mm: add iomem vma selection for memory migration Message-ID: <20210825074602.GA29620@lst.de> References: <20210825034828.12927-1-alex.sierra@amd.com> <20210825034828.12927-4-alex.sierra@amd.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20210825034828.12927-4-alex.sierra@amd.com> User-Agent: Mutt/1.5.17 (2007-11-01) X-Mailman-Approved-At: Wed, 25 Aug 2021 12:34:20 +0000 X-BeenThere: amd-gfx@lists.freedesktop.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Discussion list for AMD gfx List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: amd-gfx-bounces@lists.freedesktop.org Sender: "amd-gfx" On Tue, Aug 24, 2021 at 10:48:17PM -0500, Alex Sierra wrote: > } else { > - if (!(migrate->flags & MIGRATE_VMA_SELECT_SYSTEM)) > + if (!(migrate->flags & MIGRATE_VMA_SELECT_SYSTEM) && > + !(migrate->flags & MIGRATE_VMA_SELECT_IOMEM)) > goto next; > pfn = pte_pfn(pte); > if (is_zero_pfn(pfn)) { .. also how is this going to work for the device public memory? That should be pte_special() an thus fail vm_normal_page.