From patchwork Fri Nov 4 19:36:55 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: "Hawkins, Nick" X-Patchwork-Id: 15757 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:a5d:6687:0:0:0:0:0 with SMTP id l7csp601235wru; Fri, 4 Nov 2022 12:41:01 -0700 (PDT) X-Google-Smtp-Source: AMsMyM7KUgB0AsRhZozLwW/bGAUWEOd0R4ebOwwSRvHhZNKgeR2pBn1U9LQWSoSOlo2tcBlM6a3a X-Received: by 2002:a17:907:608d:b0:7a2:b93e:a765 with SMTP id ht13-20020a170907608d00b007a2b93ea765mr36674718ejc.273.1667590861717; Fri, 04 Nov 2022 12:41:01 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1667590861; cv=none; d=google.com; s=arc-20160816; b=XR+9xHJDbQ4ptgwK7SNX43Akp88qpO8t5d0oxmwRKltWIEBqEpxpfe/hSVVj+NQkfs FmSUGOjiKurFwr4fQKCT9QWceTEkv/mGYcKG13ykfYku8X7NFlY8uZOHdMD4oOtG4Sal DJrFkO770Dc6K02nEtQaUdmscKdQlzLmlRQL7exyCxzupqvQsZ1uz4vdNoaKdFgwFSFe 83mnzix/pV0K8UXElMEzQPLCFpclNnemBuCt0XFUnYukcikI015qn1t0HbohTCoKARgK FpR+tpp9wuqFGfYzTi1YMzZpvq8Vr5aCXmA3SXM9iHBpwxtCz6sWswBwHhiBSRfLA3z6 Br1g== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:references:in-reply-to:message-id:date:subject :to:from:dkim-signature; bh=5bjPs4ztaVaX28LoetRQEyad5DP9Y8AuzRk63Drm/IM=; b=QH0f2ljcsE29UFwB2fzOCSeOmaTxUj/Nxdlbj01Q63Iu8YxU4MrXosi12Unsq0v6kl 0ZmqD+rmk5EUSf8DYCqSfjhwHp0PSZZGFUllmA39JaXXRZAWs6Nk/HeZ9/CAfABUORWH lWzD8zR+ncrLHsYDyqNiCNFp3+SmSgaBv3FZbcZ2GTxG108CBAoMU2wk5l2081dSro+J 9RGQJzWvPibhZiTgRyOyfc7MnZ2t75Y6RLsVG8R7SIxP+xlUgA8KNSqo8ciG7hsYIef2 aYEdCX3xg0G0xFjB0nMtG2JOxE6mVC5FWLjrjcmo59fr2Ecs0mu69GKs9z+MNxSXY9iy hbZA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@hpe.com header.s=pps0720 header.b=FuUgBt5N; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=hpe.com Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id f13-20020a170906084d00b0078168566b26si3337055ejd.356.2022.11.04.12.40.33; Fri, 04 Nov 2022 12:41:01 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@hpe.com header.s=pps0720 header.b=FuUgBt5N; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=hpe.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229863AbiKDTi5 (ORCPT + 99 others); Fri, 4 Nov 2022 15:38:57 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:35364 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229764AbiKDTip (ORCPT ); Fri, 4 Nov 2022 15:38:45 -0400 Received: from mx0a-002e3701.pphosted.com (mx0a-002e3701.pphosted.com [148.163.147.86]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 0B5FC10CF; Fri, 4 Nov 2022 12:38:43 -0700 (PDT) Received: from pps.filterd (m0150241.ppops.net [127.0.0.1]) by mx0a-002e3701.pphosted.com (8.17.1.5/8.17.1.5) with ESMTP id 2A4HGUqj018115; Fri, 4 Nov 2022 19:38:12 GMT DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=hpe.com; h=from : to : subject : date : message-id : in-reply-to : references; s=pps0720; bh=5bjPs4ztaVaX28LoetRQEyad5DP9Y8AuzRk63Drm/IM=; b=FuUgBt5NCg4jb/noEz486oodnocwf4aLfffzwAiYnXyZGQBfr6ILbJ852FJ7b6GYWgNm MSamDOvxm/vMZM5rVzhxOwXO++6gbSS5pJUSbpL2b6iWZTwV9dP4+fmaHSOGBMk1yxID RgGlrs+039pLK5HxVcDEB5ZnRdR4jA3ekIMa0EHArGTkoWU51oBJgcRMhZtsA2IfjTlN TyAu05WM8m3KuC39KCwmwzk7Atuq5zU1K+QhNpzNBiO5fj0i2YNbKzIOa/pzCSeiEYRH LHWg8ben37JtOn8/2NDrvel6dYGHnqdVnWpGVEyCJIdGUod7b8t9QeCixk+fZQCCiZkh zw== Received: from p1lg14878.it.hpe.com (p1lg14878.it.hpe.com [16.230.97.204]) by mx0a-002e3701.pphosted.com (PPS) with ESMTPS id 3kn6xh0xgw-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT); Fri, 04 Nov 2022 19:38:12 +0000 Received: from p1lg14885.dc01.its.hpecorp.net (unknown [10.119.18.236]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) by p1lg14878.it.hpe.com (Postfix) with ESMTPS id 82D18D2AE; Fri, 4 Nov 2022 19:38:11 +0000 (UTC) Received: from hpe.com (unknown [16.231.227.36]) by p1lg14885.dc01.its.hpecorp.net (Postfix) with ESMTP id E8DC680353C; Fri, 4 Nov 2022 19:38:10 +0000 (UTC) From: nick.hawkins@hpe.com To: jdelvare@suse.com, linux@roeck-us.net, robh+dt@kernel.org, krzysztof.kozlowski+dt@linaro.org, verdun@hpe.com, nick.hawkins@hpe.com, corbet@lwn.net, linux@armlinux.org.uk, linux-hwmon@vger.kernel.org, linux-kernel@vger.kernel.org, devicetree@vger.kernel.org, linux-doc@vger.kernel.org, linux-arm-kernel@lists.infradead.org Subject: [PATCH v1 4/6] ARM: dts: add GXP Support for fans and SPI Date: Fri, 4 Nov 2022 14:36:55 -0500 Message-Id: <20221104193657.105130-5-nick.hawkins@hpe.com> X-Mailer: git-send-email 2.17.1 In-Reply-To: <20221104193657.105130-1-nick.hawkins@hpe.com> References: <20221104193657.105130-1-nick.hawkins@hpe.com> X-Proofpoint-GUID: egV9SKPfbHnJJhY2p3KYJID9KdCjRZ2s X-Proofpoint-ORIG-GUID: egV9SKPfbHnJJhY2p3KYJID9KdCjRZ2s X-HPE-SCL: -1 X-Proofpoint-Virus-Version: vendor=baseguard engine=ICAP:2.0.219,Aquarius:18.0.895,Hydra:6.0.545,FMLib:17.11.122.1 definitions=2022-11-04_11,2022-11-03_01,2022-06-22_01 X-Proofpoint-Spam-Details: rule=outbound_notspam policy=outbound score=0 suspectscore=0 mlxlogscore=885 lowpriorityscore=0 priorityscore=1501 bulkscore=0 adultscore=0 spamscore=0 clxscore=1015 phishscore=0 malwarescore=0 impostorscore=0 mlxscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.12.0-2210170000 definitions=main-2211040122 X-Spam-Status: No, score=-3.8 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_LOW, SPF_HELO_NONE,SPF_NONE autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org X-getmail-retrieved-from-mailbox: =?utf-8?q?INBOX?= X-GMAIL-THRID: =?utf-8?q?1748595755454542382?= X-GMAIL-MSGID: =?utf-8?q?1748595755454542382?= From: Nick Hawkins Reorganize the base address of AHB to accommodate the SPI and fan driver register requirements. Add the hpe,gxp-spifi and hpe,gxp-fan-ctrl compatibles. Add comments to make the register range more clear. Signed-off-by: Nick Hawkins --- arch/arm/boot/dts/hpe-bmc-dl360gen10.dts | 58 +++++++++++++++++++++ arch/arm/boot/dts/hpe-gxp.dtsi | 64 +++++++++++++++++------- 2 files changed, 103 insertions(+), 19 deletions(-) diff --git a/arch/arm/boot/dts/hpe-bmc-dl360gen10.dts b/arch/arm/boot/dts/hpe-bmc-dl360gen10.dts index 3a7382ce40ef..d49dcef95c5c 100644 --- a/arch/arm/boot/dts/hpe-bmc-dl360gen10.dts +++ b/arch/arm/boot/dts/hpe-bmc-dl360gen10.dts @@ -24,3 +24,61 @@ reg = <0x40000000 0x20000000>; }; }; + +&spifi { + status = "okay"; + flash@0 { + partitions { + compatible = "fixed-partitions"; + #address-cells = <1>; + #size-cells = <1>; + + u-boot@0 { + label = "u-boot"; + reg = <0x0 0x60000>; + }; + + u-boot-env@60000 { + label = "u-boot-env"; + reg = <0x60000 0x20000>; + }; + + kernel@80000 { + label = "kernel"; + reg = <0x80000 0x4c0000>; + }; + + rofs@540000 { + label = "rofs"; + reg = <0x540000 0x1740000>; + }; + + rwfs@1c80000 { + label = "rwfs"; + reg = <0x1c80000 0x250000>; + }; + + section@1ed0000{ + label = "section"; + reg = <0x1ed0000 0x130000>; + }; + }; + }; + flash@1 { + partitions { + compatible = "fixed-partitions"; + #address-cells = <1>; + #size-cells = <1>; + + host-prime@0 { + label = "host-prime"; + reg = <0x0 0x02000000>; + }; + + host-second@2000000 { + label = "host-second"; + reg = <0x02000000 0x02000000>; + }; + }; + }; +}; diff --git a/arch/arm/boot/dts/hpe-gxp.dtsi b/arch/arm/boot/dts/hpe-gxp.dtsi index cf735b3c4f35..27486dd4d99a 100644 --- a/arch/arm/boot/dts/hpe-gxp.dtsi +++ b/arch/arm/boot/dts/hpe-gxp.dtsi @@ -1,6 +1,6 @@ // SPDX-License-Identifier: GPL-2.0 /* - * Device Tree file for HPE GXP + * Device Tree for HPE */ /dts-v1/; @@ -52,76 +52,102 @@ cache-level = <2>; }; - ahb@c0000000 { + ahb@80000000 { compatible = "simple-bus"; #address-cells = <1>; #size-cells = <1>; - ranges = <0x0 0xc0000000 0x30000000>; + ranges = <0x0 0x80000000 0xf000000>, /* 0x80000000 - 0x8f000000 */ + <0x40000000 0xc0000000 0x7fffffff>; /* 0xc0000000 - 0xffffffff */ dma-ranges; - vic0: interrupt-controller@eff0000 { + spifi: spi@40000200 { /* 0xc0000200 */ + compatible = "hpe,gxp-spifi"; + reg = <0x40000200 0x80>, <0x4000c000 0x100>, <0x78000000 0x7ff0000>; + interrupts = <20>; + interrupt-parent = <&vic0>; + #address-cells = <1>; + #size-cells = <0>; + status = "disabled"; + flash@0 { + reg = <0>; + compatible = "jedec,spi-nor"; + }; + + flash@1 { + reg = <1>; + compatible = "jedec,spi-nor"; + }; + }; + + vic0: interrupt-controller@4eff0000 { /* 0xceff0000 */ compatible = "arm,pl192-vic"; - reg = <0xeff0000 0x1000>; + reg = <0x4eff0000 0x1000>; interrupt-controller; #interrupt-cells = <1>; }; - vic1: interrupt-controller@80f00000 { + vic1: interrupt-controller@f00000 { /* 0x80f00000 */ compatible = "arm,pl192-vic"; - reg = <0x80f00000 0x1000>; + reg = <0xf00000 0x1000>; interrupt-controller; #interrupt-cells = <1>; }; - uarta: serial@e0 { + uarta: serial@400000e0 { /* 0xc00000e0 */ compatible = "ns16550a"; - reg = <0xe0 0x8>; + reg = <0x400000e0 0x8>; interrupts = <17>; interrupt-parent = <&vic0>; clock-frequency = <1846153>; reg-shift = <0>; }; - uartb: serial@e8 { + uartb: serial@400000e8 { /* 0xc00000e8 */ compatible = "ns16550a"; - reg = <0xe8 0x8>; + reg = <0x400000e8 0x8>; interrupts = <18>; interrupt-parent = <&vic0>; clock-frequency = <1846153>; reg-shift = <0>; }; - uartc: serial@f0 { + uartc: serial@400000f0 { /* 0xc00000f0 */ compatible = "ns16550a"; - reg = <0xf0 0x8>; + reg = <0x400000f0 0x8>; interrupts = <19>; interrupt-parent = <&vic0>; clock-frequency = <1846153>; reg-shift = <0>; }; - usb0: usb@efe0000 { + usb0: usb@4efe0000 { /* 0xcefe0000 */ compatible = "hpe,gxp-ehci", "generic-ehci"; - reg = <0xefe0000 0x100>; + reg = <0x4efe0000 0x100>; interrupts = <7>; interrupt-parent = <&vic0>; }; - st: timer@80 { + st: timer@40000080 { /* 0xc0000080 */ compatible = "hpe,gxp-timer"; - reg = <0x80 0x16>; + reg = <0x40000080 0x16>; interrupts = <0>; interrupt-parent = <&vic0>; clocks = <&iopclk>; clock-names = "iop"; }; - usb1: usb@efe0100 { + usb1: usb@4efe0100 { /* 0xcefe0100 */ compatible = "hpe,gxp-ohci", "generic-ohci"; - reg = <0xefe0100 0x110>; + reg = <0x4efe0100 0x110>; interrupts = <6>; interrupt-parent = <&vic0>; }; + + fanctrl: fanctrl@40000c00 { /* 0xc0000c00 */ + compatible = "hpe,gxp-fan-ctrl"; + reg = <0x40000c00 0x200>, <0x51000027 0x06>, <0x200070 0x01>; + reg-names = "base", "plreg", "fn2reg"; + }; }; }; };