Received: by 2002:ad5:474a:0:0:0:0:0 with SMTP id i10csp1615046imu; Tue, 20 Nov 2018 22:21:52 -0800 (PST) X-Google-Smtp-Source: AFSGD/XBrDMzyj4pu38ZrWBzWUAKhZdlTRtiBMVl7YruOM2BzfKA/wuDDx1EHRWzpkHZ/1iXwaTU X-Received: by 2002:a63:e101:: with SMTP id z1mr4805188pgh.310.1542781312058; Tue, 20 Nov 2018 22:21:52 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1542781312; cv=none; d=google.com; s=arc-20160816; b=K6MuHZf33rs1sHL6P2mbmg9tDADIHyVPAIhkY+Uli4j/N5gQwc+9TXQbQPAl5Z/5Cp YEgIMlJWrEaEvokD6rJJCfQNPyD/wm+vdqSIgq2Us2g+XVdaCmaZwYPeMmG1yqwJKtTy m579paF9up/vtn338+xIwtxuBPLmfJ99wfBu8fp963FXOl6V4/u2stbgSocGxUGZxrFq lmcy+hNQkcn4hmQejAwD4sphk+8An5H991p/LU7EpJ2/gV2V1Mv2WTdE8oU7OzkGDE7Q IFWwdkMPEaUU8s1laVBHGbkVkH//04YTim5wzn8XDw4oPVqI69aWMonousH9sAHualjL uEuw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:user-agent:in-reply-to :content-disposition:mime-version:references:message-id:subject:cc :to:from:date; bh=KupD56t9eGsO/04RXyWsDIXjxd/pFPFsFd1c7vr39JI=; b=sQzCl+vEcj3Cwg+gv1QURtmqv+Mbi35UC4wLcaKnzbJspthZepGNerVga1bIzOzI6t E70ozFoXVKyeq8Jak7zKIBw3Kp5boxiHPAh5xLUBWDVFq711qxWxTymML4P61yOxfjSv qlap59osS+SMAFNBTz6s9bo1jGbGEwoJJX6IV2J01/dNguHEGQ8zBv9doP/hmEB95xAO TSEXVxribAmV+4Jj98+8F8y55Tlyi1Kb0K/qbWrmXdfSDVnwtRjlueu7/I7TDWM35gqj +KCRNutuOr+/W5yxN53HVQuHN8/JDloWU1IsUN+y4j705A2fH4FW+aZTkQ8V5P/zCeJ2 4JGg== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=redhat.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id h10si27815459pgd.285.2018.11.20.22.21.36; Tue, 20 Nov 2018 22:21:52 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=redhat.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727992AbeKUQiS (ORCPT + 99 others); Wed, 21 Nov 2018 11:38:18 -0500 Received: from mx1.redhat.com ([209.132.183.28]:52882 "EHLO mx1.redhat.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1725995AbeKUQiR (ORCPT ); Wed, 21 Nov 2018 11:38:17 -0500 Received: from smtp.corp.redhat.com (int-mx07.intmail.prod.int.phx2.redhat.com [10.5.11.22]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mx1.redhat.com (Postfix) with ESMTPS id 6D1BBC049592; Wed, 21 Nov 2018 06:05:13 +0000 (UTC) Received: from localhost (ovpn-8-29.pek2.redhat.com [10.72.8.29]) by smtp.corp.redhat.com (Postfix) with ESMTPS id 3F1DC103BAB7; Wed, 21 Nov 2018 06:05:01 +0000 (UTC) Date: Wed, 21 Nov 2018 14:04:58 +0800 From: Baoquan He To: David Hildenbrand Cc: linux-mm@kvack.org, Michal Hocko , Arnd Bergmann , linux-pm@vger.kernel.org, pv-drivers@vmware.com, Borislav Petkov , linux-doc@vger.kernel.org, kexec-ml , linux-kernel@vger.kernel.org, Matthew Wilcox , Omar Sandoval , Kazuhito Hagio , "Michael S. Tsirkin" , xen-devel@lists.xenproject.org, linux-fsdevel@vger.kernel.org, devel@linuxdriverproject.org, Dave Young , Andrew Morton , "Kirill A. Shutemov" , Lianbo Jiang 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-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20181119101616.8901-4-david@redhat.com> User-Agent: Mutt/1.9.1 (2017-09-22) X-Scanned-By: MIMEDefang 2.84 on 10.5.11.22 X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-4.5.16 (mx1.redhat.com [10.5.110.31]); Wed, 21 Nov 2018 06:05:14 +0000 (UTC) Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org 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