From patchwork Thu Apr 30 12:29:56 2015 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Kevin Hao X-Patchwork-Id: 466503 Return-Path: X-Original-To: patchwork-incoming@ozlabs.org Delivered-To: patchwork-incoming@ozlabs.org Received: from lists.ozlabs.org (lists.ozlabs.org [103.22.144.68]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPS id 365EC140308 for ; Thu, 30 Apr 2015 22:33:16 +1000 (AEST) Authentication-Results: ozlabs.org; dkim=fail reason="verification failed; unprotected key" header.d=gmail.com header.i=@gmail.com header.b=IpYZklKs; dkim-adsp=none (unprotected policy); dkim-atps=neutral Received: from ozlabs.org (lists.ozlabs.org [IPv6:2401:3900:2:1::3]) by lists.ozlabs.org (Postfix) with ESMTP id 10D501A05E6 for ; Thu, 30 Apr 2015 22:33:16 +1000 (AEST) Authentication-Results: lists.ozlabs.org; dkim=fail reason="verification failed; unprotected key" header.d=gmail.com header.i=@gmail.com header.b=IpYZklKs; dkim-adsp=none (unprotected policy); dkim-atps=neutral X-Original-To: linuxppc-dev@lists.ozlabs.org Delivered-To: linuxppc-dev@lists.ozlabs.org Received: from mail-yh0-x230.google.com (mail-yh0-x230.google.com [IPv6:2607:f8b0:4002:c01::230]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by lists.ozlabs.org (Postfix) with ESMTPS id 4C9221A0033 for ; Thu, 30 Apr 2015 22:30:23 +1000 (AEST) Authentication-Results: lists.ozlabs.org; dkim=pass reason="2048-bit key; unprotected key" header.d=gmail.com header.i=@gmail.com header.b=IpYZklKs; dkim-adsp=pass; dkim-atps=neutral Received: by yhcb70 with SMTP id b70so12660310yhc.0 for ; Thu, 30 Apr 2015 05:30:21 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=from:to:cc:subject:date:message-id:in-reply-to:references; bh=pEoRa+7Ig+Mo2qzYVnZwDIZfYDHt8MM4h9ZfKzPC0A0=; b=IpYZklKsS2ClH8e//N9NQ3hY9pFsqta4mlk7No8x5avWlgUVcdoYvRehkIdlWElfA6 h0YvIymu+IJHsLt3pwWYp9+dIGA9iCFSo69b4o5zIlhn738iErSOBrV7+xl/X90I49R9 LhCUd/oFEv6qdcvoGtQeMiTf9Ovk/SnZu7o/UdzaDr97oWbwaXZn/PRYUo+s3y3FslPj f9uA2VeGSjDgs1blaRKdT7EE4O61FfXkghZcc+6vnqT4Wq4BVA3YEoCFV0syZo4vBnsd 5XkUMb3gQX/+SLt2c9aGFp6RsPe3jhp8VC/FZdjB+i1BQFkcE80AFGO/D07fML+ryGtw vjsQ== X-Received: by 10.236.27.66 with SMTP id d42mr3126466yha.156.1430397020963; Thu, 30 Apr 2015 05:30:20 -0700 (PDT) Received: from pek-khao-d1.corp.ad.wrs.com ([106.120.101.38]) by mx.google.com with ESMTPSA id 29sm1954692yhe.50.2015.04.30.05.30.17 (version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Thu, 30 Apr 2015 05:30:19 -0700 (PDT) From: Kevin Hao To: linuxppc-dev@lists.ozlabs.org Subject: [PATCH 1/2] powerpc: fix the dependency issue for CRASH_DUMP Date: Thu, 30 Apr 2015 20:29:56 +0800 Message-Id: <1430396997-14656-2-git-send-email-haokexin@gmail.com> X-Mailer: git-send-email 2.1.0 In-Reply-To: <1430396997-14656-1-git-send-email-haokexin@gmail.com> References: <1430396997-14656-1-git-send-email-haokexin@gmail.com> X-BeenThere: linuxppc-dev@lists.ozlabs.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: Linux on PowerPC Developers Mail List List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Errors-To: linuxppc-dev-bounces+patchwork-incoming=ozlabs.org@lists.ozlabs.org Sender: "Linuxppc-dev" In the current code, the RELOCATABLE will be forcedly enabled when enabling CRASH_DUMP. But for ppc32, the RELOCABLE also depend on ADVANCED_OPTIONS and select NONSTATIC_KERNEL. This will cause build error when CRASH_DUMP=y && ADVANCED_OPTIONS=n. Even there is no such issue for ppc64, but select is only for non-visible symbols and for symbols with no dependencies. As for a symbol like RELOCATABLE, it is definitely not suitable to select it. So choose to depend on it. Also enable the RELOCATABLE explicitly for the defconfigs which has CRASH_DUMP enabled. Signed-off-by: Kevin Hao --- arch/powerpc/Kconfig | 3 +-- arch/powerpc/configs/ppc64_defconfig | 1 + 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/arch/powerpc/Kconfig b/arch/powerpc/Kconfig index 190cc48abc0c..d6bbf4f6f869 100644 --- a/arch/powerpc/Kconfig +++ b/arch/powerpc/Kconfig @@ -429,8 +429,7 @@ config KEXEC config CRASH_DUMP bool "Build a kdump crash kernel" - depends on PPC64 || 6xx || FSL_BOOKE || (44x && !SMP) - select RELOCATABLE if (PPC64 && !COMPILE_TEST) || 44x || FSL_BOOKE + depends on 6xx || ((PPC64 || FSL_BOOKE || (44x && !SMP)) && RELOCATABLE) help Build a kernel suitable for use as a kdump capture kernel. The same kernel binary can be used as production kernel and dump diff --git a/arch/powerpc/configs/ppc64_defconfig b/arch/powerpc/configs/ppc64_defconfig index aad501ae3834..01f7b63f2df0 100644 --- a/arch/powerpc/configs/ppc64_defconfig +++ b/arch/powerpc/configs/ppc64_defconfig @@ -46,6 +46,7 @@ CONFIG_BINFMT_MISC=m CONFIG_PPC_TRANSACTIONAL_MEM=y CONFIG_KEXEC=y CONFIG_CRASH_DUMP=y +CONFIG_RELOCATABLE=y CONFIG_IRQ_ALL_CPUS=y CONFIG_MEMORY_HOTREMOVE=y CONFIG_KSM=y