Received: by 2002:a05:6a10:c604:0:0:0:0 with SMTP id y4csp4270162pxt; Wed, 11 Aug 2021 01:53:47 -0700 (PDT) X-Google-Smtp-Source: ABdhPJytZ1OIXALeJHQuMV4ykvQhqmUUHrT+cSvDzJ9upGdFx5TP7ytc+eWJR5zeppSFqZqEggVF X-Received: by 2002:a05:6402:3128:: with SMTP id dd8mr10324114edb.40.1628672027493; Wed, 11 Aug 2021 01:53:47 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1628672027; cv=none; d=google.com; s=arc-20160816; b=zdXKKHDDPm9OJbBHTC2kN+EAfv+rkOrJjmYS4ZFPRbw7fkGkuOOsF9YgTxgYuTQ0pu wjl1UYIWgus0XyRlPO1V06o0A5pgaHMFyXVnDCI2X5P0GxrfBmgWzkeFuXzycBlN1ecf t7Lt6zVI92I7Zz8OR+hJj9j8PIsZ4y6cizVTJCuFp0cb3jy6HYKxKfcmNGVUVRTxcNvF VoqNmqI++Ix8bf2tCcIOPIi1rC/f688sbQ1gDBO4iOfjvuy98QDMfLoYhZCVLF/H1V+D ykH9h8OgyIFRZQ4zJOfRpTitGmi/LNCDD/8tHlD6+pRlmLC6lbSvOHm2yga8OBNDOTXZ Auuw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :references:in-reply-to:message-id:date:subject:cc:to:from; bh=fqhzjMvxPIst+mTyNo4H0hcJin4PUbGKvFz6LrUHe18=; b=z/VxGrTZqKbWAtdfkoVr1+H3AHdYZENXQ0hUAxPMpd8+zLY/WmKLtnR63ftzJqWkc/ E6H9UzCnlvlbrGMOPKnFKjaPG10SwisilQVEOrXtxxcJSQU4fSRWNU3MIFhKIw5pnKiK 504UBkPWr+BsPXIF3Jbv3dMCdRAOQA1hSK2dz8avFhvYqiG8ltpt8do+EpCY92Y/K+pU ZbZdaRk1K9LqdRUaYceP/6FiP+SKfTnrrEHzVeDLi7Qj8H4xxdWMVVvmuI29vqizqqyf c/EB+TCpgBWhe63D/A6NDV5B+77IgFMD0zpUdS7hqh8yVxgjFkVceW8yZExy1FvB9OGs /pRA== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id p17si4009803edq.486.2021.08.11.01.53.24; Wed, 11 Aug 2021 01:53:47 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S236595AbhHKIwE (ORCPT + 99 others); Wed, 11 Aug 2021 04:52:04 -0400 Received: from newton.telenet-ops.be ([195.130.132.45]:53388 "EHLO newton.telenet-ops.be" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S236290AbhHKIv7 (ORCPT ); Wed, 11 Aug 2021 04:51:59 -0400 Received: from baptiste.telenet-ops.be (baptiste.telenet-ops.be [IPv6:2a02:1800:120:4::f00:13]) by newton.telenet-ops.be (Postfix) with ESMTPS id 4Gl3TL6s1BzMqlKv for ; Wed, 11 Aug 2021 10:51:34 +0200 (CEST) Received: from ramsan.of.borg ([IPv6:2a02:1810:ac12:ed20:438:1ff1:1071:f524]) by baptiste.telenet-ops.be with bizsmtp id g8rG250091gJxCh018rG46; Wed, 11 Aug 2021 10:51:34 +0200 Received: from rox.of.borg ([192.168.97.57]) by ramsan.of.borg with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.93) (envelope-from ) id 1mDjxE-001yaE-4C; Wed, 11 Aug 2021 10:51:16 +0200 Received: from geert by rox.of.borg with local (Exim 4.93) (envelope-from ) id 1mDjxD-0058xK-E7; Wed, 11 Aug 2021 10:51:15 +0200 From: Geert Uytterhoeven To: Rob Herring , Russell King , Nicolas Pitre , Ard Biesheuvel , Linus Walleij , Catalin Marinas , Will Deacon , Thomas Bogendoerfer , Nick Kossifidis , Paul Walmsley , Palmer Dabbelt , Albert Ou , Frank Rowand , Dave Young Cc: Baoquan He , Vivek Goyal , Mike Rapoport , devicetree@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-mips@vger.kernel.org, linux-riscv@lists.infradead.org, kexec@lists.infradead.org, linux-renesas-soc@vger.kernel.org, linux-kernel@vger.kernel.org, Geert Uytterhoeven , Palmer Dabbelt Subject: [PATCH v5 6/9] riscv: Remove non-standard linux,elfcorehdr handling Date: Wed, 11 Aug 2021 10:51:04 +0200 Message-Id: <41c75d6ee3114ae6304f8afe0051895af91200ee.1628670468.git.geert+renesas@glider.be> X-Mailer: git-send-email 2.25.1 In-Reply-To: References: MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org RISC-V uses platform-specific code to locate the elf core header in memory. However, this does not conform to the standard "linux,elfcorehdr" DT bindings, as it relies on a reserved memory node with the "linux,elfcorehdr" compatible value, instead of on a "linux,elfcorehdr" property under the "/chosen" node. The non-compliant code can just be removed, as the standard behavior is already implemented by platform-agnostic handling in the FDT core code. Fixes: 5640975003d0234d ("RISC-V: Add crash kernel support") Signed-off-by: Geert Uytterhoeven Reviewed-by: Palmer Dabbelt Acked-by: Palmer Dabbelt --- v5: - Add Reviewed-by, Acked-by, v4: - No changes. --- arch/riscv/mm/init.c | 20 -------------------- 1 file changed, 20 deletions(-) diff --git a/arch/riscv/mm/init.c b/arch/riscv/mm/init.c index 88134cc288d9a60b..3f284b2d327166af 100644 --- a/arch/riscv/mm/init.c +++ b/arch/riscv/mm/init.c @@ -860,26 +860,6 @@ static void __init reserve_crashkernel(void) } #endif /* CONFIG_KEXEC_CORE */ -#ifdef CONFIG_CRASH_DUMP -/* - * We keep track of the ELF core header of the crashed - * kernel with a reserved-memory region with compatible - * string "linux,elfcorehdr". Here we register a callback - * to populate elfcorehdr_addr/size when this region is - * present. Note that this region will be marked as - * reserved once we call early_init_fdt_scan_reserved_mem() - * later on. - */ -static int __init elfcore_hdr_setup(struct reserved_mem *rmem) -{ - elfcorehdr_addr = rmem->base; - elfcorehdr_size = rmem->size; - return 0; -} - -RESERVEDMEM_OF_DECLARE(elfcorehdr, "linux,elfcorehdr", elfcore_hdr_setup); -#endif - void __init paging_init(void) { setup_bootmem(); -- 2.25.1