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 8C682EE57DF for ; Mon, 11 Sep 2023 14:33:57 +0000 (UTC) Received: by kanga.kvack.org (Postfix) id 132F66B02A5; Mon, 11 Sep 2023 10:33:57 -0400 (EDT) Received: by kanga.kvack.org (Postfix, from userid 40) id 0E2726B02A6; Mon, 11 Sep 2023 10:33:57 -0400 (EDT) X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id EC4FA6B02A7; Mon, 11 Sep 2023 10:33:56 -0400 (EDT) X-Delivered-To: linux-mm@kvack.org Received: from relay.hostedemail.com (smtprelay0013.hostedemail.com [216.40.44.13]) by kanga.kvack.org (Postfix) with ESMTP id D929B6B02A5 for ; Mon, 11 Sep 2023 10:33:56 -0400 (EDT) Received: from smtpin29.hostedemail.com (a10.router.float.18 [10.200.18.1]) by unirelay02.hostedemail.com (Postfix) with ESMTP id A8A8D120A47 for ; Mon, 11 Sep 2023 14:33:56 +0000 (UTC) X-FDA: 81224560872.29.1B88E2A Received: from us-smtp-delivery-124.mimecast.com (us-smtp-delivery-124.mimecast.com [170.10.129.124]) by imf27.hostedemail.com (Postfix) with ESMTP id 58C9740012 for ; Mon, 11 Sep 2023 14:33:54 +0000 (UTC) Authentication-Results: imf27.hostedemail.com; dkim=pass header.d=redhat.com header.s=mimecast20190719 header.b=XuG8yRgO; dmarc=pass (policy=none) header.from=redhat.com; spf=pass (imf27.hostedemail.com: domain of david@redhat.com designates 170.10.129.124 as permitted sender) smtp.mailfrom=david@redhat.com ARC-Seal: i=1; s=arc-20220608; d=hostedemail.com; t=1694442834; a=rsa-sha256; cv=none; b=blQp3XN8gvoI0RnK4s5I6VPOZ6ZtPA1HA7c6iFtYmSggpRTxI68pH5wkTa50W2sSIJ9rnh g1jmb0hTbt3aEM5YNXkLM5dkP7jpEy6DK11b/hlvFdoFiF9W4Iyntia28HE00LBJfM2M7R D58QrNtMZTTubHV/4lbGDxw56QjJnGg= ARC-Authentication-Results: i=1; imf27.hostedemail.com; dkim=pass header.d=redhat.com header.s=mimecast20190719 header.b=XuG8yRgO; dmarc=pass (policy=none) header.from=redhat.com; spf=pass (imf27.hostedemail.com: domain of david@redhat.com designates 170.10.129.124 as permitted sender) smtp.mailfrom=david@redhat.com ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=hostedemail.com; s=arc-20220608; t=1694442834; h=from:from:sender: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:dkim-signature; bh=R6fgHbS8D+uTD08GSlTthpp2bLqas6LD5jQg3oM+vXs=; b=DcOY9QFcCSjHj4ZyVj7sllAw/MIjsclBErPuV5AAWow2CVdp0Y7htOMDwmxonZrVQ9dnR0 rFRoSfTme1qlx7hCtHOiASpPJeeJUUcQxHWKVdioQ7jb62mmKSrePI1Fq2B+OLEa54kesm xQ+uglnosvCHqEiPzL4JLfuKzsUIuJI= DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1694442833; 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=R6fgHbS8D+uTD08GSlTthpp2bLqas6LD5jQg3oM+vXs=; b=XuG8yRgOLuHKZ7uMVPBxl2NfhEulcpA6jT87jpGC9q8EoqYKf62L86l6S6ClEL88A2mot5 W3rflnSKT2C7E7//Q5dqlz8GM28QuvgfHVizcbJwm1IYejZg0fLIiYEFzy6HmyaNduGBWW 33mJK55g2uLZ9jgRLXS0hIdjyaAwqok= Received: from mail-wm1-f71.google.com (mail-wm1-f71.google.com [209.85.128.71]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.3, cipher=TLS_AES_256_GCM_SHA384) id us-mta-479-1e28aRwDNCyFFQoN-DEaZQ-1; Mon, 11 Sep 2023 10:33:52 -0400 X-MC-Unique: 1e28aRwDNCyFFQoN-DEaZQ-1 Received: by mail-wm1-f71.google.com with SMTP id 5b1f17b1804b1-402cd372b8bso36298095e9.2 for ; Mon, 11 Sep 2023 07:33:52 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1694442831; x=1695047631; h=content-transfer-encoding:in-reply-to:organization:from:references :cc:to:content-language:subject:user-agent:mime-version:date :message-id:x-gm-message-state:from:to:cc:subject:date:message-id :reply-to; bh=R6fgHbS8D+uTD08GSlTthpp2bLqas6LD5jQg3oM+vXs=; b=tVBLYAx66ndTBYd1PgwVue/J7XyaDtAMPHbPrCD3pM+LVqwiixi82ly0HF97jx0vBf woAp9dzuKWYGBY4CWfEwrsJx+OIGHEcDSAym3rqYws3umG5WOxrGFFBwQF1RQUx9LW8B cP/qACCno7RAtSDdALdQ31iIGT8idPQr9V6OM56fN8sY+YuFtuLjZZVkUdACnSWEG0P3 cBN5QBFASYaGP1weKkOBlb6u077e/Vtk45dY5VoZaRfN+rPMPwJ5CI5INE5JZXVPSDwp +ZvM/6nCtGRcJqi4BBVvhkvjlg/oIZJyOj4ux8s9i+6EAj0CpREjZgpoVv2qFspxjP5K TfLA== X-Gm-Message-State: AOJu0Yx/FMBmpxiRjJbgiHXflsWFPEDeVsZzIMXVQrXN74SRImkOjJ+q OY7KnXETwwTBcwM/5JJhCyF3NehE5O65X/XqXdffIe1gwccgGVQHMHFn7FBQ2GY3Bg+lILcclS3 LpzbVQw9pAmA= X-Received: by 2002:a05:600c:5120:b0:402:f517:9c07 with SMTP id o32-20020a05600c512000b00402f5179c07mr7985438wms.0.1694442831140; Mon, 11 Sep 2023 07:33:51 -0700 (PDT) X-Google-Smtp-Source: AGHT+IG5pMvmXX0+VW9KHCfmQiDyHsdxBecmD9teUi0kfSkwDsZ1VNAU+o/EeDi3ry3+F0HnO2KLxQ== X-Received: by 2002:a05:600c:5120:b0:402:f517:9c07 with SMTP id o32-20020a05600c512000b00402f5179c07mr7985407wms.0.1694442830722; Mon, 11 Sep 2023 07:33:50 -0700 (PDT) Received: from ?IPV6:2003:cb:c743:5500:a9bd:94ab:74e9:782f? (p200300cbc7435500a9bd94ab74e9782f.dip0.t-ipconnect.de. [2003:cb:c743:5500:a9bd:94ab:74e9:782f]) by smtp.gmail.com with ESMTPSA id b13-20020a5d634d000000b0031c5e9c2ed7sm10238812wrw.92.2023.09.11.07.33.49 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Mon, 11 Sep 2023 07:33:50 -0700 (PDT) Message-ID: Date: Mon, 11 Sep 2023 16:33:48 +0200 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:102.0) Gecko/20100101 Thunderbird/102.13.0 Subject: Re: [PATCH 1/3] proc/vmcore: Do not map unaccepted memory To: "Kirill A. Shutemov" Cc: Adrian Hunter , Borislav Petkov , Andrew Morton , Dave Hansen , Vlastimil Babka , Mike Rapoport , Lorenzo Stoakes , Tom Lendacky , Baoquan He , Vivek Goyal , Dave Young , linux-kernel@vger.kernel.org, linux-fsdevel@vger.kernel.org, linux-mm@kvack.org, linux-coco@lists.linux.dev, linux-efi@vger.kernel.org, kexec@lists.infradead.org References: <20230906073902.4229-1-adrian.hunter@intel.com> <20230906073902.4229-2-adrian.hunter@intel.com> <20230911084148.l6han7jxob42rdvm@box.shutemov.name> <49ab74c8-553b-b3d0-6a72-2d259a2b5bdf@redhat.com> <20230911092712.2ps55mylf7elfqp6@box.shutemov.name> <476456e1-ac50-8e48-260d-5cbe5e8b085e@redhat.com> <20230911100555.mjjnx3ujnjlaxgsy@box.shutemov.name> From: David Hildenbrand Organization: Red Hat In-Reply-To: <20230911100555.mjjnx3ujnjlaxgsy@box.shutemov.name> X-Mimecast-Spam-Score: 0 X-Mimecast-Originator: redhat.com Content-Language: en-US Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit X-Rspam-User: X-Rspamd-Server: rspam06 X-Rspamd-Queue-Id: 58C9740012 X-Stat-Signature: 6zzoh4bx6rz6ff6drtr81topn8byfwjq X-HE-Tag: 1694442834-147284 X-HE-Meta: U2FsdGVkX18Aj0510WZg/SRTyImRjFGlm8ggUOcXkyuOtn5UZWH8/qHhT6yhO1jUdsX4/Tr2QMPi01h6QIOsx2jcEFaVQCoKmea2FUshNi9jnBYHt34ekz81OVZbkCXDN9xBPACMDBOWqG7wHNPM6noOWVyHy2M9dPf+s5yNVoR2oVooOBFhC1mgB17lMyP1sAGIC+CRboDKLUqGsE0EblwnILZt6BTH62+Fgb1Jz4PFDFNnSIPJ+OGFLRes/XQ7/M+Sxwu5WUP3IJtwMMscUMtx/EddgzHXoLKWQn+BuZFKVnJ3pxQ3Z8rJYRSsoMzPGfjx/fv8i+Qb7T38bnoJ5Cv9gWfK6znFVrxcfLRgajZ7UXPDIrW8KQ1jbGA2dp3kAF849r8S5f82plRX9A4mY0GKks2e9XF2NIfm+M7tF0tocEi1pvoymEVpYdE2Z7Xjbtpn4cP2BnQTUzh4tbHL/aMdK8/YS5SRh6ZTAN/rhMVyGMwAY3dzUJJodv4TDfDxZU6799OkBIUiVHE/zaU0V2r+pC4Jh5jty+BKpWawNHc2mEzRnopNBXzge989nwaBR8uJ9VNoa7mb7DlL73tR8dv952RrQL6zRZWnCF7HkzhnbmzGFh7GZRcLhD5qO9v8akuwEf9BAAqh7tok7n0vAcG0msV9vAtbz3WqTLguFH/z+wpcwYTJEy4+gTlxCO4KRlA09pf1IDCfL7ShHM0RanuJ4bOS6G4GoPMpXQpLuLCY+TJmSg5GY7QOiBbNVFlK51uhCNLILA3gV03lQ6ASpKTfbpT4QCQlyq4y1gqkRmx1OxR42cceC7US5SPPiVd1M1Ow/IwxTeaZyrF+iuZzz7U5c3VNwNBfV9OQZynSUZ9dV39TcTeO1Dgp5csqA/zTI1dOpyaTeWnZS79A63lcvuxlkTCh85eghcY/179LBWxGUK1qjacxdzZDI3vx5j+kW6onW+MnD6xNMLSxaw0 kO2gD6ve McFImU+XU3bfJaHsO83vlsMztPH0wkCksv1bG2HDVvVyTy5JV7tkPU5DKXekk1eyAc/kjvdEtTJKq9ulg279q0IbjRSexBYxZYC3SC+7IPospAsxrB88uMtaF3rQUpI3ZdPYmRYNQtHYwV2PnAYW45SkFjax3CBenS98c4oa6dhnFCw0cvd0oNSmsXYKqmlO4IpxzHwrETHyzCA0ka9mZzfenmxvUUGekg8/q6qqo0Eg9iT5tiU/DuxZ3EWUFwPpAbM7S/yjLDuwKF8PN9zeOgY19FguVM6q/+vTnsHDkVZ2XXpQPPpTURxWJCzS9OobOGqXKMY67cfZyxB+pTR0w+NBkMFMS/4bc1Pc6c7Dr2XsxdycjyvEdHtlixFuw/0YOUCes 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.09.23 12:05, Kirill A. Shutemov wrote: > On Mon, Sep 11, 2023 at 11:50:31AM +0200, David Hildenbrand wrote: >> On 11.09.23 11:27, Kirill A. Shutemov wrote: >>> On Mon, Sep 11, 2023 at 10:42:51AM +0200, David Hildenbrand wrote: >>>> On 11.09.23 10:41, Kirill A. Shutemov wrote: >>>>> On Mon, Sep 11, 2023 at 10:03:36AM +0200, David Hildenbrand wrote: >>>>>> On 06.09.23 09:39, Adrian Hunter wrote: >>>>>>> Support for unaccepted memory was added recently, refer commit >>>>>>> dcdfdd40fa82 ("mm: Add support for unaccepted memory"), whereby >>>>>>> a virtual machine may need to accept memory before it can be used. >>>>>>> >>>>>>> Do not map unaccepted memory because it can cause the guest to fail. >>>>>>> >>>>>>> For /proc/vmcore, which is read-only, this means a read or mmap of >>>>>>> unaccepted memory will return zeros. >>>>>> >>>>>> Does a second (kdump) kernel that exposes /proc/vmcore reliably get access >>>>>> to the information whether memory of the first kernel is unaccepted (IOW, >>>>>> not its memory, but the memory of the first kernel it is supposed to expose >>>>>> via /proc/vmcore)? >>>>> >>>>> There are few patches in my queue to few related issue, but generally, >>>>> yes, the information is available to the target kernel via EFI >>>>> configuration table. >>>> >>>> I assume that table provided by the first kernel, and not read directly from >>>> HW, correct? >>> >>> The table is constructed by the EFI stub in the first kernel based on EFI >>> memory map. >>> >> >> Okay, should work then once that's done by the first kernel. >> >> Maybe include this patch in your series? > > Can do. But the other two patches are not related to kexec. Hm. Yes, the others can go in separately. But this here really needs other kexec/kdump changes. -- Cheers, David / dhildenb