From patchwork Thu Jun 26 10:07:39 2014 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Wang Nan X-Patchwork-Id: 32543 Return-Path: X-Original-To: linaro@patches.linaro.org Delivered-To: linaro@patches.linaro.org Received: from mail-qc0-f198.google.com (mail-qc0-f198.google.com [209.85.216.198]) by ip-10-151-82-157.ec2.internal (Postfix) with ESMTPS id 60DC82066E for ; Thu, 26 Jun 2014 10:17:49 +0000 (UTC) Received: by mail-qc0-f198.google.com with SMTP id m20sf5994181qcx.9 for ; Thu, 26 Jun 2014 03:17:49 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:delivered-to:from:to:cc:subject:date:message-id :mime-version:sender:precedence:list-id:x-original-sender :x-original-authentication-results:mailing-list:list-post:list-help :list-archive:list-unsubscribe:content-type; bh=86WFOCMk+oyBKLHnZsERQjB5O9DGRVeCJDBH9+Dpn+U=; b=hN2RIpZ6D4zNJ/5p5S+Y5do25b1oLo3/V3px6ql55WhgB1W1anx9JGWu2ODKgRZ4cQ H+h9JmLN5q1Io5Pg3rao4W1OxTMYSCtCqDhLp5VDGf0xQ7eBJQLYBWx8P09/UoHNT19E MP/NuSAAI4yfAOhZmSWLbTOFj8m3YwCUOv5r2kaqwzmZiTff5RIkCYEcuRlQEyGZ6sGf gFxO0oM0Z2GyIwzre0GCnpatF4eSWcZDeVXGiDyKG0G5lyTu2/moghYFCYxlnoyIDrq9 RmpSj4WXy9cCtaywcNhbkIb2KACtZ9cgTEIoDiwVxlLr7g9f5PtjFNi8tA8otps9atWb zI8A== X-Gm-Message-State: ALoCoQn6BA3be6s1xASgS7awjo5pIpFuxj8dafbpw33GT/5nv/1jvkKkrGRiocATGDeN6VL/IskR X-Received: by 10.58.146.227 with SMTP id tf3mr7430955veb.14.1403777869173; Thu, 26 Jun 2014 03:17:49 -0700 (PDT) X-BeenThere: patchwork-forward@linaro.org Received: by 10.140.109.33 with SMTP id k30ls154067qgf.15.gmail; Thu, 26 Jun 2014 03:17:49 -0700 (PDT) X-Received: by 10.53.7.204 with SMTP id de12mr8174427vdd.41.1403777869060; Thu, 26 Jun 2014 03:17:49 -0700 (PDT) Received: from mail-vc0-f172.google.com (mail-vc0-f172.google.com [209.85.220.172]) by mx.google.com with ESMTPS id jv10si4071516veb.29.2014.06.26.03.17.49 for (version=TLSv1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Thu, 26 Jun 2014 03:17:49 -0700 (PDT) Received-SPF: pass (google.com: domain of patch+caf_=patchwork-forward=linaro.org@linaro.org designates 209.85.220.172 as permitted sender) client-ip=209.85.220.172; Received: by mail-vc0-f172.google.com with SMTP id hy10so3257931vcb.31 for ; Thu, 26 Jun 2014 03:17:49 -0700 (PDT) X-Received: by 10.58.112.65 with SMTP id io1mr45183veb.61.1403777868958; Thu, 26 Jun 2014 03:17:48 -0700 (PDT) X-Forwarded-To: patchwork-forward@linaro.org X-Forwarded-For: patch@linaro.org patchwork-forward@linaro.org Delivered-To: patch@linaro.org Received: by 10.221.37.5 with SMTP id tc5csp19398vcb; Thu, 26 Jun 2014 03:17:48 -0700 (PDT) X-Received: by 10.67.11.14 with SMTP id ee14mr19889170pad.107.1403777868086; Thu, 26 Jun 2014 03:17:48 -0700 (PDT) Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id st6si9203196pab.46.2014.06.26.03.17.47; Thu, 26 Jun 2014 03:17:47 -0700 (PDT) Received-SPF: none (google.com: linux-kernel-owner@vger.kernel.org does not designate permitted sender hosts) client-ip=209.132.180.67; Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1756580AbaFZKRh (ORCPT + 27 others); Thu, 26 Jun 2014 06:17:37 -0400 Received: from szxga03-in.huawei.com ([119.145.14.66]:12999 "EHLO szxga03-in.huawei.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751425AbaFZKRe (ORCPT ); Thu, 26 Jun 2014 06:17:34 -0400 Received: from 172.24.2.119 (EHLO lggeml409-hub.china.huawei.com) ([172.24.2.119]) by szxrg03-dlp.huawei.com (MOS 4.4.3-GA FastPath queued) with ESMTP id AQV38806; Thu, 26 Jun 2014 18:16:37 +0800 (CST) Received: from kernel-host.huawei (10.107.197.247) by lggeml409-hub.china.huawei.com (10.72.61.105) with Microsoft SMTP Server id 14.3.158.1; Thu, 26 Jun 2014 18:16:28 +0800 From: Wang Nan To: , , CC: , , , , Wang Nan , Li Zefan Subject: [PATCH] ARM: kdump: 2nd kernel should use strict pfn_valid in SPARSEMEM platform Date: Thu, 26 Jun 2014 18:07:39 +0800 Message-ID: <1403777259-28949-1-git-send-email-wangnan0@huawei.com> X-Mailer: git-send-email 1.8.4 MIME-Version: 1.0 X-Originating-IP: [10.107.197.247] X-CFilter-Loop: Reflected X-Mirapoint-Virus-RAPID-Raw: score=unknown(0), refid=str=0001.0A020204.53ABF306.0067,ss=1,re=0.000,fgs=0, ip=0.0.0.0, so=2013-05-26 15:14:31, dmn=2011-05-27 18:58:46 X-Mirapoint-Loop-Id: b818d9592ef59c9a283abdf44283f6fa Sender: linux-kernel-owner@vger.kernel.org Precedence: list List-ID: X-Mailing-List: linux-kernel@vger.kernel.org X-Removed-Original-Auth: Dkim didn't pass. X-Original-Sender: wangnan0@huawei.com X-Original-Authentication-Results: mx.google.com; spf=pass (google.com: domain of patch+caf_=patchwork-forward=linaro.org@linaro.org designates 209.85.220.172 as permitted sender) smtp.mail=patch+caf_=patchwork-forward=linaro.org@linaro.org Mailing-list: list patchwork-forward@linaro.org; contact patchwork-forward+owners@linaro.org X-Google-Group-Id: 836684582541 List-Post: , List-Help: , List-Archive: List-Unsubscribe: , This patch removes an irrational limitation for crash dump kernel on ARM platform when SPARSEMEM enabled. Without this patch, crash reservation area for a crash dump kernel with SPARSEMEM selected must occupy a full section plus 1MiB. If not, elfcorehdr and some memory space used by the first kernel will unable to get accessed. This is caused by pfn_valid: fast pfn_valid ragards any pfn in a valid section as valid and prevents it to be ioremapped. This limitation wastes memory, because sections are always large and crash dump kernel should be as small as possible. This patch selects HAVE_ARCH_PFN_VALID for CRASH_DUMP, makes crash dump kernel to use strict version of pfn_valid(). Signed-off-by: Wang Nan Cc: Li Zefan --- This is the forth time I post this patch. The previous discussions can be retrived from: http://lists.infradead.org/pipermail/linux-arm-kernel/2014-May/256498.html http://lists.infradead.org/pipermail/linux-arm-kernel/2014-May/257472.html http://lists.infradead.org/pipermail/linux-arm-kernel/2014-May/260322.html The second thread discusses the limitation in detail, but non of previous discussion reaches a conclusion. --- arch/arm/Kconfig | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/arch/arm/Kconfig b/arch/arm/Kconfig index 87b63fd..aca8ee0 100644 --- a/arch/arm/Kconfig +++ b/arch/arm/Kconfig @@ -1725,7 +1725,7 @@ config ARCH_SELECT_MEMORY_MODEL def_bool ARCH_SPARSEMEM_ENABLE config HAVE_ARCH_PFN_VALID - def_bool ARCH_HAS_HOLES_MEMORYMODEL || !SPARSEMEM + def_bool ARCH_HAS_HOLES_MEMORYMODEL || !SPARSEMEM || CRASH_DUMP config HIGHMEM bool "High Memory Support"