From patchwork Mon Oct 19 23:38:54 2015 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Geoff Levand X-Patchwork-Id: 55265 Return-Path: X-Original-To: linaro@patches.linaro.org Delivered-To: linaro@patches.linaro.org Received: from mail-lb0-f198.google.com (mail-lb0-f198.google.com [209.85.217.198]) by patches.linaro.org (Postfix) with ESMTPS id EA15622EA2 for ; Mon, 19 Oct 2015 23:40:31 +0000 (UTC) Received: by lbcao8 with SMTP id ao8sf539120lbc.1 for ; Mon, 19 Oct 2015 16:40:30 -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:message-id:in-reply-to:references :from:patch-date:subject:to:date:precedence:list-id:list-unsubscribe :list-archive:list-post:list-help:list-subscribe:cc:mime-version :content-type:content-transfer-encoding:sender:errors-to :x-original-sender:x-original-authentication-results:mailing-list; bh=ukkaki1yadFyY0RSSmimEkvl7EzRBDlIcc1zeyZgwC4=; b=OO5Cz6+Mj99TupdrllbbO/AztB60t1PBjNkYdVhT8ZWB27+SKFr+SbkAxbwUo+E107 1WpMdMdPQ7GAKd8lR8ELD+nTPdsOD/zNpEefU9rY0gqL+KdRMfsEEKKB5sPfa13aqou2 7qqfCqCbyBQIV0Bz2Djmb/yD2/nsdx4rUgUP7yrgInFTdkDjhXuzioAmxnPRonSnRVj5 WuxmkgUKzM0RdHclnuQhWOESSKP3Kd0M2jZL1f+cSFPVyK+fZ4j8xHpspJA4NVfwB4Uj dbyNpx6V++eoZx0dZ1JUZGdelFGBl472hPJzHmPIDSrhVQwGAHE+HCSVlQBZezLDV3iK BvSQ== X-Gm-Message-State: ALoCoQnOPA3A8CQCODkGlO+TleeTknVVhW89PBFnhspkWiFUod1RrSR7y850eaKZOXiyh9cuSuJe X-Received: by 10.112.147.7 with SMTP id tg7mr20952lbb.16.1445298030531; Mon, 19 Oct 2015 16:40:30 -0700 (PDT) X-BeenThere: patchwork-forward@linaro.org Received: by 10.25.15.106 with SMTP id e103ls3093lfi.14.gmail; Mon, 19 Oct 2015 16:40:30 -0700 (PDT) X-Received: by 10.112.63.135 with SMTP id g7mr60552lbs.16.1445298030264; Mon, 19 Oct 2015 16:40:30 -0700 (PDT) Received: from mail-lb0-f171.google.com (mail-lb0-f171.google.com. [209.85.217.171]) by mx.google.com with ESMTPS id j68si148632lfi.25.2015.10.19.16.40.30 for (version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Mon, 19 Oct 2015 16:40:30 -0700 (PDT) Received-SPF: pass (google.com: domain of patch+caf_=patchwork-forward=linaro.org@linaro.org designates 209.85.217.171 as permitted sender) client-ip=209.85.217.171; Received: by lbcao8 with SMTP id ao8so831731lbc.3 for ; Mon, 19 Oct 2015 16:40:30 -0700 (PDT) X-Received: by 10.112.161.168 with SMTP id xt8mr48961lbb.88.1445298030040; Mon, 19 Oct 2015 16:40:30 -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.112.59.35 with SMTP id w3csp1756350lbq; Mon, 19 Oct 2015 16:40:29 -0700 (PDT) X-Received: by 10.68.161.162 with SMTP id xt2mr115401pbb.89.1445298028927; Mon, 19 Oct 2015 16:40:28 -0700 (PDT) Received: from bombadil.infradead.org (bombadil.infradead.org. [2001:1868:205::9]) by mx.google.com with ESMTPS id yi1si252531pbb.246.2015.10.19.16.40.28 for (version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Mon, 19 Oct 2015 16:40:28 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-arm-kernel-bounces+patch=linaro.org@lists.infradead.org designates 2001:1868:205::9 as permitted sender) client-ip=2001:1868:205::9; Received: from localhost ([127.0.0.1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.80.1 #2 (Red Hat Linux)) id 1ZoK1P-0003EY-2x; Mon, 19 Oct 2015 23:39:19 +0000 Received: from merlin.infradead.org ([2001:4978:20e::2]) by bombadil.infradead.org with esmtps (Exim 4.80.1 #2 (Red Hat Linux)) id 1ZoK12-0002eL-7p; Mon, 19 Oct 2015 23:38:56 +0000 Received: from geoff by merlin.infradead.org with local (Exim 4.85 #2 (Red Hat Linux)) id 1ZoK10-0000x6-JM; Mon, 19 Oct 2015 23:38:54 +0000 Message-Id: <4cf0c03d6cd1cb4826bb5df679fbcdaf80be0b1c.1445297709.git.geoff@infradead.org> In-Reply-To: References: From: Geoff Levand Patch-Date: Tue, 6 Oct 2015 14:54:40 +0900 Subject: [PATCH 16/16] arm64: kdump: relax BUG_ON() if more than one cpus are still active To: Catalin Marinas , Will Deacon Date: Mon, 19 Oct 2015 23:38:54 +0000 X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.20 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: , List-Help: , List-Subscribe: , Cc: Mark Rutland , AKASHI@infradead.org, marc.zyngier@arm.com, kexec@lists.infradead.org, Takahiro , linux-arm-kernel@lists.infradead.org, christoffer.dall@linaro.org MIME-Version: 1.0 Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+patch=linaro.org@lists.infradead.org X-Removed-Original-Auth: Dkim didn't pass. X-Original-Sender: geoff@infradead.org X-Original-Authentication-Results: mx.google.com; spf=pass (google.com: domain of patch+caf_=patchwork-forward=linaro.org@linaro.org designates 209.85.217.171 as permitted sender) smtp.mailfrom=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 From: AKASHI Takahiro We should try best in case of kdump. So even if not all secondary cpus have shut down, we do kdump anyway. --- arch/arm64/kernel/machine_kexec.c | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/arch/arm64/kernel/machine_kexec.c b/arch/arm64/kernel/machine_kexec.c index f315ee4..157c29b 100644 --- a/arch/arm64/kernel/machine_kexec.c +++ b/arch/arm64/kernel/machine_kexec.c @@ -139,7 +139,12 @@ void machine_kexec(struct kimage *image) phys_addr_t reboot_code_buffer_phys; void *reboot_code_buffer; - BUG_ON(num_online_cpus() > 1); + if (num_online_cpus() > 1) { + if (in_crash_kexec) + pr_warn("*\n* kdump might fail because %d cpus are still online\n*\n", num_online_cpus()); + else + BUG(); + } kimage_head = image->head;