Received: by 2002:a05:7412:8d10:b0:f3:1519:9f41 with SMTP id bj16csp2442199rdb; Fri, 8 Dec 2023 08:13:37 -0800 (PST) X-Google-Smtp-Source: AGHT+IHLL9NHQZ3EfagTKm38cLBy+fwldFUSERxeHSbvcHwDSWowR3kH76B90l540mHxI8mH9z+N X-Received: by 2002:a17:902:d4c5:b0:1d0:4cde:6e2f with SMTP id o5-20020a170902d4c500b001d04cde6e2fmr239259plg.37.1702052016961; Fri, 08 Dec 2023 08:13:36 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1702052016; cv=none; d=google.com; s=arc-20160816; b=ks/Y6B3vWATZ9DW2L24B0HCJkP0D1aiY2kP4JnVqSiosaAKp36JI9W5l7pBHqn/xG/ ruupP2HgQDBUZGUHpCu7mDDHGtV9RFpiTetngzxMH5I0AETQ0JjI4Q86w/IOqQIzDNZA 2jjf5m0G+aiidBUuBMsvdc+GDAGGdY4sR3TqXELyMCBpGDpvTT0UZOnq4uDlvSmvt0D7 H2t2gvpms/RcKPEJFQFxMlOZBWNwUDD68/85VIPbUrmsM3y3jw2yKy34m/IwWt8asR3e vvL9zS1FHVRQk892viWcSe07umfXJGO/mKNjBBFf81Ag5IQe5gi1FcV1FpGkQ7obJymK S78Q== 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 :dkim-signature; bh=dTU5KtilBzqMs1820zYNtcs9nCUHlD6780U14+z9iDM=; fh=t1bsw/gEI8w3DN7ouBpAewoQyybWh2yxEgAHixB9Iis=; b=BFY/ALpc7fyhjSltVcBhnlXrAe8S9xF26ep4HpzpSVOwRwhtO6M0NUuu4AiXiMzAzq kFKDRTLEqdCWr4FE+0QIT7IudCFJ0E+G33FRP69A46bwt83gGLUnGLjOtOR6xFXKm9wS j+j2FFHLmfAmFaKSmboggzfo+nGEBPLFlVP0uqokWs0xdnBD3LkzWGfgYmC2DXW43hIs WWqqH4Aft7M2XiaWMbrSqCcBoVvHvmdqgE9jAxNqScgdUFNPJxorHkzcBmYc9ysyeV50 p4b3cbPz0a0it8GWEckmRyuOk6XHvY4sHLYEcaB5nwJEAsmSnzeucgwjIpqlTr+sgU4r Qp1g== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@bootlin.com header.s=gm1 header.b=ZMGj9JSs; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.36 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=REJECT sp=REJECT dis=NONE) header.from=bootlin.com Return-Path: Received: from pete.vger.email (pete.vger.email. [23.128.96.36]) by mx.google.com with ESMTPS id h2-20020a170902f54200b001d08ac11b93si1882131plf.374.2023.12.08.08.13.35 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 08 Dec 2023 08:13:36 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.36 as permitted sender) client-ip=23.128.96.36; Authentication-Results: mx.google.com; dkim=pass header.i=@bootlin.com header.s=gm1 header.b=ZMGj9JSs; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.36 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=REJECT sp=REJECT dis=NONE) header.from=bootlin.com Received: from out1.vger.email (depot.vger.email [IPv6:2620:137:e000::3:0]) by pete.vger.email (Postfix) with ESMTP id DBF6782E1092; Fri, 8 Dec 2023 08:13:32 -0800 (PST) X-Virus-Status: Clean X-Virus-Scanned: clamav-milter 0.103.11 at pete.vger.email Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1574213AbjLHQNQ (ORCPT + 99 others); Fri, 8 Dec 2023 11:13:16 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:51486 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1574044AbjLHQNA (ORCPT ); Fri, 8 Dec 2023 11:13:00 -0500 Received: from relay1-d.mail.gandi.net (relay1-d.mail.gandi.net [217.70.183.193]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id CD1FC1995; Fri, 8 Dec 2023 08:13:02 -0800 (PST) Received: by mail.gandi.net (Postfix) with ESMTPSA id DFE65240007; Fri, 8 Dec 2023 16:13:00 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=bootlin.com; s=gm1; t=1702051981; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=dTU5KtilBzqMs1820zYNtcs9nCUHlD6780U14+z9iDM=; b=ZMGj9JSs16wC1UqvmZPxrLZuhd6D9s9/2hZvlDZQTaHZimfVIGLShWLVVSGpy40FyvrIkp JaYXI8Z9RMdyRk2BXXR5RHfCkMuL/yNmT/+Zxa5MDgKsDuoxlCJu+ibU3++PPmwvgl3Jgj e+6CCk9uH0BXn3FfAZp1QxyzFBoh/CJV2zrTm9TrX5LKl80iDtITM7z71p56u4X1Mqzqqi zxCOiW4jdamVH1pVYo1XqpTWRPiJqwK4Gl2VqKtREt+lriK5RpcFG9E575MTqzumbe/Dsh l3DeLMbIta13ikZMCvmfjYn0JdqX3Vy+1+P9D7Tmp1KZQvCdBICjhRLa3nwA3w== From: Gregory CLEMENT To: Paul Burton , Thomas Bogendoerfer , linux-mips@vger.kernel.org, Jiaxun Yang , Rob Herring , Krzysztof Kozlowski , devicetree@vger.kernel.org, linux-kernel@vger.kernel.org Cc: Vladimir Kondratiev , Tawfik Bayouk , Alexandre Belloni , =?UTF-8?q?Th=C3=A9o=20Lebrun?= , Thomas Petazzoni Subject: [PATCH v4 08/22] MIPS: Allow kernel base to be set from Kconfig for all platforms Date: Fri, 8 Dec 2023 17:12:24 +0100 Message-ID: <20231208161249.1827174-9-gregory.clement@bootlin.com> X-Mailer: git-send-email 2.42.0 In-Reply-To: <20231208161249.1827174-1-gregory.clement@bootlin.com> References: <20231208161249.1827174-1-gregory.clement@bootlin.com> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-GND-Sasl: gregory.clement@bootlin.com X-Spam-Status: No, score=-0.9 required=5.0 tests=DKIM_SIGNED,DKIM_VALID, DKIM_VALID_AU,HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI, SPF_HELO_NONE,SPF_PASS,T_SCC_BODY_TEXT_LINE autolearn=unavailable autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on pete.vger.email Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org X-Greylist: Sender passed SPF test, not delayed by milter-greylist-4.6.4 (pete.vger.email [0.0.0.0]); Fri, 08 Dec 2023 08:13:33 -0800 (PST) From: Jiaxun Yang There are some platforms in wild that generic loading address won't work with them due to memory layout. Allow PHYSICAL_START to be override from Kconfig, introduce PHYSICAL_START_BOOL symbol as powerpc did. Signed-off-by: Jiaxun Yang --- arch/mips/Kconfig | 18 ++++++++++++++---- 1 file changed, 14 insertions(+), 4 deletions(-) diff --git a/arch/mips/Kconfig b/arch/mips/Kconfig index fad05f699efdf..11bacbd3971f6 100644 --- a/arch/mips/Kconfig +++ b/arch/mips/Kconfig @@ -2866,12 +2866,22 @@ config ARCH_SUPPORTS_KEXEC config ARCH_SUPPORTS_CRASH_DUMP def_bool y +config PHYSICAL_START_BOOL + bool "Set physical address where the kernel is loaded" + default y if CRASH_DUMP + help + This gives the CKSEG0, KSEG0 or XKPHYS address where the kernel + is loaded. + + Say N here unless you know what you are doing. + config PHYSICAL_START - hex "Physical address where the kernel is loaded" - default "0xffffffff84000000" - depends on CRASH_DUMP + hex "Physical address where the kernel is loaded" if PHYSICAL_START_BOOL + default "0xffffffff84000000" if CRASH_DUMP + default "0xffffffff80100000" help - This gives the CKSEG0 or KSEG0 address where the kernel is loaded. + This gives the CKSEG0, KSEG0 or XKPHYS address where the kernel + is loaded. If you plan to use kernel for capturing the crash dump change this value to start of the reserved region (the "X" value as specified in the "crashkernel=YM@XM" command line boot parameter -- 2.42.0