From patchwork Thu Oct 7 00:09:54 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Zev Weiss X-Patchwork-Id: 12540795 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id A7915C433F5 for ; Thu, 7 Oct 2021 00:12:23 +0000 (UTC) Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id 7656A61177 for ; Thu, 7 Oct 2021 00:12:23 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.4.1 mail.kernel.org 7656A61177 Authentication-Results: mail.kernel.org; dmarc=fail (p=none dis=none) header.from=bewilderbeest.net Authentication-Results: mail.kernel.org; spf=none smtp.mailfrom=lists.infradead.org DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender: Content-Transfer-Encoding:Content-Type:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:MIME-Version:References:In-Reply-To: Message-Id:Date:Subject:Cc:To:From:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=Z6tXTKuYUUx9C2dk7IlZdPsj+uTPi4oCgg9LRsMOgPw=; b=EHatX/4QgNvBde eEYuyKBySNAwaJh8BypxjJcdJuU1/heMlFnFycLUKqWUVrAmeXE7zdR16b7GLsrhp+aLDjBwULuWx rid7NSE5fXVjr4XsD5n4VWokKeCAt30peope+OH6/H7rsohyicCQBqteTo17S4Fok52olgYS8fPoe UDl4cM37bMONh3uBu/1BmV7GJvppT5cLK+aHHIhzi0OxHxY134clu6yWbjf67r8j3ZKdP0hAzU6L7 UWX/6macwdxE6Bi0WjfdQH7mQBi/yAoeOqoMdHzB9R5860/rAqTHyXhVv4KnzNzh1vPJhHRhldQyr pkrnfPK3KGtzsN6hIolw==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.94.2 #2 (Red Hat Linux)) id 1mYGzO-00FsPh-MY; Thu, 07 Oct 2021 00:10:22 +0000 Received: from thorn.bewilderbeest.net ([71.19.156.171]) by bombadil.infradead.org with esmtps (Exim 4.94.2 #2 (Red Hat Linux)) id 1mYGzF-00FsNz-VN for linux-arm-kernel@lists.infradead.org; Thu, 07 Oct 2021 00:10:15 +0000 Received: from hatter.bewilderbeest.net (71-212-29-146.tukw.qwest.net [71.212.29.146]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) (Authenticated sender: zev) by thorn.bewilderbeest.net (Postfix) with ESMTPSA id 8A47BC9D; Wed, 6 Oct 2021 17:10:13 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=bewilderbeest.net; s=thorn; t=1633565413; bh=XbnBokbU4ntbWci1KrAbGbAkUYozeIlG0GRIL9z3qXo=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=EitWl8QleIUt2OPZiPMJHveL8FiAN7YvAna53lj/V5pHG85jwRgWKeB0Wul/1oG+R UK2CqTSLh+QHrGhAwU8tWk6lV+2b9ykqCNlrtjz/Q2VlW7CkoV2BXGK1Yns/FebXek MK4ZnWkn9bRJ0AIs3j9nJ8x5SEtyaU6WmkO0dO+U= From: Zev Weiss To: openbmc@lists.ozlabs.org Cc: Greg Kroah-Hartman , Jeremy Kerr , Joel Stanley , Rob Herring , devicetree@vger.kernel.org, Zev Weiss , Andrew Jeffery , linux-arm-kernel@lists.infradead.org, linux-aspeed@lists.ozlabs.org, linux-kernel@vger.kernel.org Subject: [PATCH 9/9] ARM: dts: aspeed: Add e3c246d4i BIOS flash device Date: Wed, 6 Oct 2021 17:09:54 -0700 Message-Id: <20211007000954.30621-10-zev@bewilderbeest.net> X-Mailer: git-send-email 2.33.0 In-Reply-To: <20211007000954.30621-1-zev@bewilderbeest.net> References: <20211007000954.30621-1-zev@bewilderbeest.net> MIME-Version: 1.0 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20211006_171014_035767_36F7C825 X-CRM114-Status: GOOD ( 15.03 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org This uses a dynamic DT node because the BIOS SPI flash requires significant coordination with the host system (power state tracking, GPIOs, IPMI messages) before the BMC can touch it, and needs to be relinquished back to the host when the BMC is done accessing it. Signed-off-by: Zev Weiss --- .../boot/dts/aspeed-bmc-asrock-e3c246d4i.dts | 23 +++++++++++++++++++ 1 file changed, 23 insertions(+) diff --git a/arch/arm/boot/dts/aspeed-bmc-asrock-e3c246d4i.dts b/arch/arm/boot/dts/aspeed-bmc-asrock-e3c246d4i.dts index 9b4cf5ebe6d5..428198703824 100644 --- a/arch/arm/boot/dts/aspeed-bmc-asrock-e3c246d4i.dts +++ b/arch/arm/boot/dts/aspeed-bmc-asrock-e3c246d4i.dts @@ -68,6 +68,29 @@ flash@0 { }; }; +&spi1 { + /* + * The BIOS SPI flash is shared with the host via an external mux, and + * is not accessible by the BMC by default (hence reserved/dynamic + * here rather than okay). This would ideally be done on the flash@0 + * node instead of the spi1 controller, but the driver infrastructure + * to support dynamic devices at that level of the device tree isn't + * currently in place, and it's the only flash chip on this + * controller, so we can get away with the coarser granularity here + * until support for making individual flash chips dynamic is + * available. + */ + status = "reserved"; + dynamic; + pinctrl-names = "default"; + pinctrl-0 = <&pinctrl_spi1_default>; + flash@0 { + status = "okay"; + label = "bios"; + m25p,fast-read; + }; +}; + &uart5 { status = "okay"; };