Received: by 2002:a05:6a10:a841:0:0:0:0 with SMTP id d1csp1203328pxy; Thu, 29 Apr 2021 01:47:42 -0700 (PDT) X-Google-Smtp-Source: ABdhPJzFXc/NBDRRGrzJNWLgUh/T9+XnFIpzyBWJ76fUelYdAd421KFmuEf5dcfppjfVFVMe2RlB X-Received: by 2002:a17:907:1629:: with SMTP id hb41mr774723ejc.316.1619686061877; Thu, 29 Apr 2021 01:47:41 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1619686061; cv=none; d=google.com; s=arc-20160816; b=r5sMh0bwHTWTNwrUM3CX5X5IVfLD1C4DPPtO6aQv+6LOCws+z+EtFLS3KJ1k3oB7Og wfcOB+TPy1W73RTKb2spEP26Z2y8aq6l7o0niMM19JHfme/kGfSriySVwqYHx6aIFn9x YQJwDPVMOn8/Mp2zVo4YkL3bZ+OOBEIXm0KxDozCwtxldCBX1N5+Mrg00JnfwpDCajpp bSWhqoaA46jPAhlVD9dPXH//889t7QbEHGo8eNjJChmQe7ox/gFogSJ251oEGSR44F73 COXFaTdXrzskKr7GHn60FY2hTDjlcyekjfAHt6a69rQhBehs4R7hbIjOdRufJ8JsWqb7 tsuA== 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 :message-id:date:subject:to:from; bh=OgSjdYNodjoFoLNBIeXmlGucKytvN/1G2+FQvPAeLLU=; b=K+A5nli7splVCtBncg6GcOyk+NjDdSBUr1R58VIBrUtIMGNKtN95S2efqZVsTdiWLs /Uq568mJJvtI1QOJWRpm69BNlSYaqByGF8bFHECOCsWafsGvNY+LbFGfA8vzxTPzXase 18N/zFcVs9dZOkzp7nVON/FkQ5zeibi+p5GVSJN0osmlI8nV67bC0MiUAtn8A2ERAVBD /iCQhw2jPglGD4F9D614AVP6yghLea8Prdx1mcYeLr1WztWzDkkb89U02nHvAMEYmK2X SOJXBDnKNgX5b3l/FjQjoVdHrxw9O5Jy0YsgFqbaRGSKX0YhDFqcohdDF15IjbUemTyX g0Cg== 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 q18si2651940ejy.55.2021.04.29.01.47.18; Thu, 29 Apr 2021 01:47:41 -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 S240008AbhD2Iqc (ORCPT + 99 others); Thu, 29 Apr 2021 04:46:32 -0400 Received: from relay1-d.mail.gandi.net ([217.70.183.193]:25811 "EHLO relay1-d.mail.gandi.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S233714AbhD2Iqb (ORCPT ); Thu, 29 Apr 2021 04:46:31 -0400 X-Originating-IP: 2.7.49.219 Received: from debian.home (lfbn-lyo-1-457-219.w2-7.abo.wanadoo.fr [2.7.49.219]) (Authenticated sender: alex@ghiti.fr) by relay1-d.mail.gandi.net (Postfix) with ESMTPSA id C4ECF240006; Thu, 29 Apr 2021 08:45:42 +0000 (UTC) From: Alexandre Ghiti To: Paul Walmsley , Palmer Dabbelt , Albert Ou , Alexandre Ghiti , linux-riscv@lists.infradead.org, linux-kernel@vger.kernel.org Subject: [PATCH] riscv: Disallow to build XIP_KERNEL with SOC_SIFIVE Date: Thu, 29 Apr 2021 04:45:41 -0400 Message-Id: <20210429084541.28083-1-alex@ghiti.fr> X-Mailer: git-send-email 2.20.1 MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org RISCV_ERRATA_ALTERNATIVE patches text at runtime which is not possible when the kernel is executed from the flash in XIP mode, and as the SIFIVE errata must be fixed somehow, disallow to build a XIP kernel that supports SIFIVE socs. Signed-off-by: Alexandre Ghiti --- arch/riscv/Kconfig.erratas | 2 +- arch/riscv/Kconfig.socs | 1 + 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/arch/riscv/Kconfig.erratas b/arch/riscv/Kconfig.erratas index d5d03ae8d685..9537dbd67357 100644 --- a/arch/riscv/Kconfig.erratas +++ b/arch/riscv/Kconfig.erratas @@ -2,7 +2,7 @@ menu "CPU errata selection" config RISCV_ERRATA_ALTERNATIVE bool "RISC-V alternative scheme" - default y + default y if !XIP_KERNEL help This Kconfig allows the kernel to automatically patch the errata required by the execution platform at run time. The diff --git a/arch/riscv/Kconfig.socs b/arch/riscv/Kconfig.socs index 00c2b205654c..9cb38bc9d7cd 100644 --- a/arch/riscv/Kconfig.socs +++ b/arch/riscv/Kconfig.socs @@ -9,6 +9,7 @@ config SOC_MICROCHIP_POLARFIRE config SOC_SIFIVE bool "SiFive SoCs" + depends on !XIP_KERNEL select SERIAL_SIFIVE if TTY select SERIAL_SIFIVE_CONSOLE if TTY select CLK_SIFIVE -- 2.20.1