From mboxrd@z Thu Jan 1 00:00:00 1970 Return-path: Received: from mx1.redhat.com ([209.132.183.28]) by bombadil.infradead.org with esmtps (Exim 4.90_1 #2 (Red Hat Linux)) id 1gPLdd-0007bG-6n for kexec@lists.infradead.org; Wed, 21 Nov 2018 06:05:26 +0000 Date: Wed, 21 Nov 2018 14:04:58 +0800 From: Baoquan He Subject: Re: [PATCH v1 3/8] kexec: export PG_offline to VMCOREINFO Message-ID: <20181121060458.GC7386@MiWiFi-R3L-srv> References: <20181119101616.8901-1-david@redhat.com> <20181119101616.8901-4-david@redhat.com> MIME-Version: 1.0 Content-Disposition: inline In-Reply-To: <20181119101616.8901-4-david@redhat.com> List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Sender: "kexec" Errors-To: kexec-bounces+dwmw2=infradead.org@lists.infradead.org To: David Hildenbrand Cc: Michal Hocko , "Michael S. Tsirkin" , Arnd Bergmann , linux-pm@vger.kernel.org, pv-drivers@vmware.com, linux-doc@vger.kernel.org, kexec-ml , linux-kernel@vger.kernel.org, Matthew Wilcox , linux-mm@kvack.org, Kazuhito Hagio , Borislav Petkov , devel@linuxdriverproject.org, linux-fsdevel@vger.kernel.org, xen-devel@lists.xenproject.org, Andrew Morton , Dave Young , Omar Sandoval , "Kirill A. Shutemov" , Lianbo Jiang On 11/19/18 at 11:16am, David Hildenbrand wrote: > diff --git a/kernel/crash_core.c b/kernel/crash_core.c > index 933cb3e45b98..093c9f917ed0 100644 > --- a/kernel/crash_core.c > +++ b/kernel/crash_core.c > @@ -464,6 +464,8 @@ static int __init crash_save_vmcoreinfo_init(void) > VMCOREINFO_NUMBER(PAGE_BUDDY_MAPCOUNT_VALUE); > #ifdef CONFIG_HUGETLB_PAGE > VMCOREINFO_NUMBER(HUGETLB_PAGE_DTOR); > +#define PAGE_OFFLINE_MAPCOUNT_VALUE (~PG_offline) > + VMCOREINFO_NUMBER(PAGE_OFFLINE_MAPCOUNT_VALUE); > #endif This solution looks good to me. One small concern is why we don't export PG_offline to vmcoreinfo directly, then define PAGE_OFFLINE_MAPCOUNT_VALUE in makedumpfile. We have been exporting kernel data/MACRO directly, why this one is exceptional. Thanks Baoquan _______________________________________________ kexec mailing list kexec@lists.infradead.org http://lists.infradead.org/mailman/listinfo/kexec