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=-2.4 required=3.0 tests=DKIM_SIGNED,DKIM_VALID, DKIM_VALID_AU,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 1B12ACA9EA0 for ; Tue, 22 Oct 2019 09:17:37 +0000 (UTC) Received: from kanga.kvack.org (kanga.kvack.org [205.233.56.17]) by mail.kernel.org (Postfix) with ESMTP id CDBDF2064B for ; Tue, 22 Oct 2019 09:17:36 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (1024-bit key) header.d=redhat.com header.i=@redhat.com header.b="V4Rhzasf" DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org CDBDF2064B Authentication-Results: mail.kernel.org; dmarc=fail (p=none dis=none) header.from=redhat.com Authentication-Results: mail.kernel.org; spf=pass smtp.mailfrom=owner-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix) id 6CC416B0003; Tue, 22 Oct 2019 05:17:36 -0400 (EDT) Received: by kanga.kvack.org (Postfix, from userid 40) id 67C8B6B0006; Tue, 22 Oct 2019 05:17:36 -0400 (EDT) X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id 591D56B0007; Tue, 22 Oct 2019 05:17:36 -0400 (EDT) X-Delivered-To: linux-mm@kvack.org Received: from forelay.hostedemail.com (smtprelay0071.hostedemail.com [216.40.44.71]) by kanga.kvack.org (Postfix) with ESMTP id 3909C6B0003 for ; Tue, 22 Oct 2019 05:17:36 -0400 (EDT) Received: from smtpin14.hostedemail.com (10.5.19.251.rfc1918.com [10.5.19.251]) by forelay03.hostedemail.com (Postfix) with SMTP id AF0668249980 for ; Tue, 22 Oct 2019 09:17:34 +0000 (UTC) X-FDA: 76070867628.14.knot20_7c44d431ec201 X-HE-Tag: knot20_7c44d431ec201 X-Filterd-Recvd-Size: 4140 Received: from us-smtp-delivery-1.mimecast.com (us-smtp-1.mimecast.com [207.211.31.81]) by imf33.hostedemail.com (Postfix) with ESMTP for ; Tue, 22 Oct 2019 09:17:33 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1571735853; 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=O5z9CMG3C81sifoUf2QQwhHlJPM7DMSGubNkuyFNjik=; b=V4Rhzasf2nZuUISvPDqcTOgG9ZNA/3qj8kM2s2MwmnVED9kZ5bgYC8UrK2PlI10lDW6EFk oZ5yGukSXpHO/9XLTh1iDoQdVwk6Vafo2fkQmmDdQqr3iGhigopsfXTxNHO6YugWlqiAoY u1snKIPGbBj5lwq6MgcNDvEzVw0W0nk= Received: from mimecast-mx01.redhat.com (mimecast-mx01.redhat.com [209.132.183.4]) (Using TLS) by relay.mimecast.com with ESMTP id us-mta-357-sm3pJgPVP2O00wTgL4khMA-1; Tue, 22 Oct 2019 05:17:31 -0400 Received: from smtp.corp.redhat.com (int-mx05.intmail.prod.int.phx2.redhat.com [10.5.11.15]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mimecast-mx01.redhat.com (Postfix) with ESMTPS id BEABD107AD31; Tue, 22 Oct 2019 09:17:28 +0000 (UTC) Received: from [10.36.117.11] (ovpn-117-11.ams2.redhat.com [10.36.117.11]) by smtp.corp.redhat.com (Postfix) with ESMTP id E60465D6A5; Tue, 22 Oct 2019 09:17:24 +0000 (UTC) Subject: Re: [PATCH v2 0/2] mm: Memory offlining + page isolation cleanups To: Michal Hocko Cc: linux-kernel@vger.kernel.org, linux-mm@kvack.org, Alexander Duyck , Andrew Morton , Anshuman Khandual , Dan Williams , Mel Gorman , Mike Rapoport , Mike Rapoport , Oscar Salvador , Pavel Tatashin , Pavel Tatashin , Pingfan Liu , Qian Cai , Vlastimil Babka , Wei Yang References: <20191021172353.3056-1-david@redhat.com> <25d3f071-3268-298b-e0c8-9c307d1015fe@redhat.com> <20191022080835.GZ9379@dhcp22.suse.cz> <1f56744d-2c22-6c12-8fe8-4a71e791c467@redhat.com> <20191022082131.GC9379@dhcp22.suse.cz> <20191022091431.GG9379@dhcp22.suse.cz> From: David Hildenbrand Organization: Red Hat GmbH Message-ID: <68d6da35-276c-0491-99ea-8249dee8fd1d@redhat.com> Date: Tue, 22 Oct 2019 11:17:24 +0200 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:68.0) Gecko/20100101 Thunderbird/68.1.1 MIME-Version: 1.0 In-Reply-To: <20191022091431.GG9379@dhcp22.suse.cz> Content-Language: en-US X-Scanned-By: MIMEDefang 2.79 on 10.5.11.15 X-MC-Unique: sm3pJgPVP2O00wTgL4khMA-1 X-Mimecast-Spam-Score: 0 Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: quoted-printable 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 22.10.19 11:14, Michal Hocko wrote: > On Tue 22-10-19 10:32:11, David Hildenbrand wrote: > [...] >> E.g., arch/x86/kvm/mmu.c:kvm_is_mmio_pfn() >=20 > Thanks for these references. I am not really familiar with kvm so I > cannot really comment on the specific code but I am wondering why > it simply doesn't check for ZONE_DEVICE explicitly? Also we do care > about holes in RAM (from the early boot), those should be reserved > already AFAIR. So we are left with hotplugged memory with holes and > I am not really sure we should bother with this until there is a clear > usecase in sight. Well, checking for ZONE_DEVICE is only possible if you have an=20 initialized memmap. And that is not guaranteed when you start mapping=20 random stuff into your guest via /dev/mem. I am reworking these patches right now and audit the whole kernel for=20 PageReserved() checks that might affect ZONE_DEVICE. I'll send the=20 collection of patches as RFC. --=20 Thanks, David / dhildenb