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 Received: from kanga.kvack.org (kanga.kvack.org [205.233.56.17]) by smtp.lore.kernel.org (Postfix) with ESMTP id 5BD21C433EF for ; Fri, 11 Feb 2022 16:49:14 +0000 (UTC) Received: by kanga.kvack.org (Postfix) id DEEC76B0078; Fri, 11 Feb 2022 11:49:13 -0500 (EST) Received: by kanga.kvack.org (Postfix, from userid 40) id D9D0D6B007B; Fri, 11 Feb 2022 11:49:13 -0500 (EST) X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id C8C8B6B007D; Fri, 11 Feb 2022 11:49:13 -0500 (EST) X-Delivered-To: linux-mm@kvack.org Received: from forelay.hostedemail.com (smtprelay0055.hostedemail.com [216.40.44.55]) by kanga.kvack.org (Postfix) with ESMTP id BAADE6B0078 for ; Fri, 11 Feb 2022 11:49:13 -0500 (EST) Received: from smtpin09.hostedemail.com (10.5.19.251.rfc1918.com [10.5.19.251]) by forelay02.hostedemail.com (Postfix) with ESMTP id 7564A98C3E for ; Fri, 11 Feb 2022 16:49:13 +0000 (UTC) X-FDA: 79131084186.09.562785A Received: from us-smtp-delivery-124.mimecast.com (us-smtp-delivery-124.mimecast.com [170.10.129.124]) by imf07.hostedemail.com (Postfix) with ESMTP id E131540006 for ; Fri, 11 Feb 2022 16:49:12 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1644598152; 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=PP4TELWylzhqvbTRyqntJ6du2uBGE5WicD7gyfPqb1s=; b=L8wv4zWoXhN3DvGFAwArd9nmJRWpbc43cPEXwm/TbPogN7hCEsEltiqRtDhD2OaxX/2PJh DOQMtZnU6pA+Yx7h49VEMVlnuBkgLZSpVGIWMBPBLkrmqEn9IoqLgb/VQq8m9SaE9FAfBv BkAZ5VUoVyjyTM2K7fIuaLdM7km+3tU= Received: from mail-wr1-f69.google.com (mail-wr1-f69.google.com [209.85.221.69]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id us-mta-65-k8Bj41RAN2SpRURQap0eQA-1; Fri, 11 Feb 2022 11:49:11 -0500 X-MC-Unique: k8Bj41RAN2SpRURQap0eQA-1 Received: by mail-wr1-f69.google.com with SMTP id i10-20020adfaaca000000b001e4b2db0303so2105123wrc.23 for ; Fri, 11 Feb 2022 08:49:11 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:message-id:date:mime-version:user-agent:subject :content-language:to:cc:references:from:organization:in-reply-to :content-transfer-encoding; bh=PP4TELWylzhqvbTRyqntJ6du2uBGE5WicD7gyfPqb1s=; b=ogTksa1S6y+7y7SyZnucn3F2u/KwaLc321BYkMOWa9SotwGOA8UfgjkaiaSehrD1XB GUOcVyPbIGyec5tuefqaGR/OmR/gykOr6AmWAeI33lTIiDeC1rRrvz7z8d4oVqBVm/Xw ro0S95U0QNFsy2BtvYSe41k/TzXHEcnhBFo4rGyEXLA/ml/YZW/i2nmmOouWZiLedShg ZMXNAftTD+rLAgirXlP08rJVS1vvwAOdMn1jL8qnQAlhEQ8sO52dNYCxYMI6NMq0rqki PnVZcQezwRMy9N/CvP4ud+C4/KxYYGNJOYX6g/06nT0Ot2doFcKpjj4ZxJVki2K+ddr3 Y92g== X-Gm-Message-State: AOAM530YgBYsoknSRwJI4szU6KdNYOKlMii1Ar5AMUfu255VDEUY0mOI 7hNv6K5yER9BqNjrXMtNFyns679hqM1vqfmiqny+7WyLBRRlXi+EgM8bQxrgt0V7++4KQQbYcgF Hv6R1K7fZ7qw= X-Received: by 2002:adf:e94c:: with SMTP id m12mr1981419wrn.383.1644598150266; Fri, 11 Feb 2022 08:49:10 -0800 (PST) X-Google-Smtp-Source: ABdhPJy7WIrAF58deu+37aUiWlRp/W5UJhe80Crx1E3d+PpeeyE61InCn2g0DPuWCXNpzEMPcQYA7w== X-Received: by 2002:adf:e94c:: with SMTP id m12mr1981411wrn.383.1644598150072; Fri, 11 Feb 2022 08:49:10 -0800 (PST) Received: from ?IPV6:2003:cb:c70c:aa00:4cc6:d24a:90ae:8c1f? (p200300cbc70caa004cc6d24a90ae8c1f.dip0.t-ipconnect.de. [2003:cb:c70c:aa00:4cc6:d24a:90ae:8c1f]) by smtp.gmail.com with ESMTPSA id f1sm3214049wmb.20.2022.02.11.08.49.08 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Fri, 11 Feb 2022 08:49:09 -0800 (PST) Message-ID: <6a8df47e-96d0-ffaf-247a-acc504e2532b@redhat.com> Date: Fri, 11 Feb 2022 17:49:08 +0100 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:91.0) Gecko/20100101 Thunderbird/91.4.0 Subject: Re: [PATCH v6 01/10] mm: add zone device coherent type memory support To: Jason Gunthorpe Cc: Alex Sierra , 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, jglisse@redhat.com, apopple@nvidia.com, willy@infradead.org References: <20220201154901.7921-1-alex.sierra@amd.com> <20220201154901.7921-2-alex.sierra@amd.com> <20220211164537.GO4160@nvidia.com> From: David Hildenbrand Organization: Red Hat In-Reply-To: <20220211164537.GO4160@nvidia.com> X-Mimecast-Spam-Score: 0 X-Mimecast-Originator: redhat.com Content-Language: en-US Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit X-Stat-Signature: gmfd1tephfz1iz5zjozqs7i5bm5ono5m X-Rspamd-Server: rspam02 X-Rspamd-Queue-Id: E131540006 Authentication-Results: imf07.hostedemail.com; dkim=pass header.d=redhat.com header.s=mimecast20190719 header.b=L8wv4zWo; dmarc=pass (policy=none) header.from=redhat.com; spf=none (imf07.hostedemail.com: domain of david@redhat.com has no SPF policy when checking 170.10.129.124) smtp.mailfrom=david@redhat.com X-Rspam-User: X-HE-Tag: 1644598152-86371 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 11.02.22 17:45, Jason Gunthorpe wrote: > On Fri, Feb 11, 2022 at 05:15:25PM +0100, David Hildenbrand wrote: > >> ... I'm pretty sure we cannot FOLL_PIN DEVICE_PRIVATE pages > > Currently the only way to get a DEVICE_PRIVATE page out of the page > tables is via hmm_range_fault() and that doesn't manipulate any ref > counts. Thanks for clarifying Jason! ... and AFAIU, device exclusive entries are essentially just pointers at ordinary PageAnon() pages. So with DEVICE COHERENT we'll have the first PageAnon() ZONE_DEVICE pages mapped as present in the page tables where GUP could FOLL_PIN them. -- Thanks, David / dhildenb