From nobody Tue Apr 7 06:33:39 2026 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 vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id A3D74C433FE for ; Tue, 11 Oct 2022 18:56:49 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S230035AbiJKS4r (ORCPT ); Tue, 11 Oct 2022 14:56:47 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:45004 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229965AbiJKS43 (ORCPT ); Tue, 11 Oct 2022 14:56:29 -0400 Received: from mx0b-002e3701.pphosted.com (mx0b-002e3701.pphosted.com [148.163.143.35]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id B9B9382870; Tue, 11 Oct 2022 11:56:27 -0700 (PDT) Received: from pps.filterd (m0134423.ppops.net [127.0.0.1]) by mx0b-002e3701.pphosted.com (8.17.1.5/8.17.1.5) with ESMTP id 29BGs34F018400; Tue, 11 Oct 2022 18:56:02 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=7M5weptjsCIYnz77TwPaKOTuYrir2azWofVKGceRMkQ=; b=bld7rqEBYTSPeyP1iHM9UR6GrMDKKU6eR7aUwmlf/eGPXkZcQTUNlXvlA49xE0Dk6Fwr qKDliSJbaysWLfWOP1CPEP1ilwt2Y2wUb9bi5nTCNU1R++TmlcSk4WBBSzVsGb7tVOJz +A6AmwsxJFWWnyXzAnHDdbYSYI25HdeX4TAsHc6sBZGUNeKKDuON/OD4tW50B/WGCRZq unpoPDRsJPABGEwLZOSf5GRg/zWWizye/wK8l5VFmYp0+qb6Am5ZRwQXjhBdjHEebSSx 3ToVxAwfZmVKXv57CMEFPkOaSiemQVw0Kcxekun/Wj+v+1NO3OMTVQGCBzQ+4HSrCh7a YQ== Received: from p1lg14878.it.hpe.com (p1lg14878.it.hpe.com [16.230.97.204]) by mx0b-002e3701.pphosted.com (PPS) with ESMTPS id 3k5cdgh07d-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT); Tue, 11 Oct 2022 18:56:02 +0000 Received: from p1lg14886.dc01.its.hpecorp.net (unknown [10.119.18.237]) (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 CEF8D13943; Tue, 11 Oct 2022 18:56:01 +0000 (UTC) Received: from hpe.com (unknown [16.231.227.36]) by p1lg14886.dc01.its.hpecorp.net (Postfix) with ESMTP id 7071A8032BC; Tue, 11 Oct 2022 18:56:01 +0000 (UTC) From: nick.hawkins@hpe.com To: verdun@hpe.com, nick.hawkins@hpe.com, robh+dt@kernel.org, krzysztof.kozlowski+dt@linaro.org, linux@armlinux.org.uk, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, linux-arm-kernel@lists.infradead.org Subject: [PATCH v1 3/5] ARM: dts: hpe: Add PLREG/SPI Support Date: Tue, 11 Oct 2022 13:55:23 -0500 Message-Id: <20221011185525.94210-4-nick.hawkins@hpe.com> X-Mailer: git-send-email 2.17.1 In-Reply-To: <20221011185525.94210-1-nick.hawkins@hpe.com> References: <20221011185525.94210-1-nick.hawkins@hpe.com> X-Proofpoint-GUID: xb0o_b1zfXxOFEh7ivBWi31-iRLmWGq_ X-Proofpoint-ORIG-GUID: xb0o_b1zfXxOFEh7ivBWi31-iRLmWGq_ X-HPE-SCL: -1 X-Proofpoint-Virus-Version: vendor=baseguard engine=ICAP:2.0.205,Aquarius:18.0.895,Hydra:6.0.545,FMLib:17.11.122.1 definitions=2022-10-11_08,2022-10-11_02,2022-06-22_01 X-Proofpoint-Spam-Details: rule=outbound_notspam policy=outbound score=0 bulkscore=0 phishscore=0 mlxlogscore=939 lowpriorityscore=0 malwarescore=0 mlxscore=0 suspectscore=0 adultscore=0 priorityscore=1501 spamscore=0 impostorscore=0 clxscore=1015 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.12.0-2209130000 definitions=main-2210110110 Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" From: Nick Hawkins Adding support for the Programmable Logic Register driver in the HPE GXP SoC. Additionally adding support for the SPI driver that has already been committed to linux (See: drivers/spi/spi-gxp.c). Signed-off-by: Nick Hawkins --- arch/arm/boot/dts/hpe-bmc-dl360gen10.dts | 275 +++++++++++++++++++++++ arch/arm/boot/dts/hpe-gxp.dtsi | 28 ++- 2 files changed, 302 insertions(+), 1 deletion(-) diff --git a/arch/arm/boot/dts/hpe-bmc-dl360gen10.dts b/arch/arm/boot/dts/h= pe-bmc-dl360gen10.dts index 3a7382ce40ef..c97b052c4868 100644 --- a/arch/arm/boot/dts/hpe-bmc-dl360gen10.dts +++ b/arch/arm/boot/dts/hpe-bmc-dl360gen10.dts @@ -23,4 +23,279 @@ device_type =3D "memory"; reg =3D <0x40000000 0x20000000>; }; + + leds { + compatible =3D "gpio-leds"; + + led-power { + gpios =3D <&plreg 6 0>; + default_state =3D "off"; + }; + + led-heartbeat { + gpios =3D <&plreg 7 0>; + default_state =3D "off"; + }; + + led-identify { + gpios =3D <&plreg 56 0>; + default-state =3D "off"; + }; + + led-health_red { + gpios =3D <&plreg 57 0>; + default_state =3D "off"; + }; + + led-health_amber { + gpios =3D <&plreg 58 0>; + default-state =3D "off"; + }; + }; +}; + +&spifi { + status =3D "okay"; + flash@0 { + partitions { + compatible =3D "fixed-partitions"; + #address-cells =3D <1>; + #size-cells =3D <1>; + + u-boot@0 { + label =3D "u-boot"; + reg =3D <0x0 0x60000>; + }; + + u-boot-env@60000 { + label =3D "u-boot-env"; + reg =3D <0x60000 0x20000>; + }; + + kernel@80000 { + label =3D "kernel"; + reg =3D <0x80000 0x4c0000>; + }; + + rofs@540000 { + label =3D "rofs"; + reg =3D <0x540000 0x1740000>; + }; + + rwfs@1c80000 { + label =3D "rwfs"; + reg =3D <0x1c80000 0x250000>; + }; + + section@1ed0000{ + label =3D "section"; + reg =3D <0x1ed0000 0x130000>; + }; + }; + }; + flash@1 { + partitions { + compatible =3D "fixed-partitions"; + #address-cells =3D <1>; + #size-cells =3D <1>; + + host-prime@0 { + label =3D "host-prime"; + reg =3D <0x0 0x02000000>; + }; + + host-second@2000000 { + label =3D "host-second"; + reg =3D <0x02000000 0x02000000>; + }; + }; + }; +}; + +&plreg { + gpio-controller; + #gpio-cells =3D <2>; + gpio-line-names =3D + "", "", "", "", "", + "", "POWER", "HEARTBEAT", "FAN1_INST", "FAN2_INST", + "FAN3_INST", "FAN4_INST", "FAN5_INST", "FAN6_INST", "FAN7_INST", + "FAN8_INST", "FAN9_INST", "FAN10_INST", "FAN11_INST", "FAN12_INST", + "FAN13_INST", "FAN14_INST", "FAN15_INST", "FAN16_INST", "FAN1_FAIL", + "FAN2_FAIL", "FAN3_FAIL", "FAN4_FAIL", "FAN5_FAIL", "FAN6_FAIL", + "FAN7_FAIL", "FAN8_FAIL", "FAN9_FAIL", "FAN10_FAIL", "FAN11_FAIL", + "FAN12_FAIL", "FAN13_FAIL", "FAN14_FAIL", "FAN15_FAIL", "FAN16_FAIL", + "", "", "", "", "", + "", "", "", "", "", + "", "", "", "", "", + "", "IDENTIFY", "HEALTH_RED", "HEALTH_AMBER", "POWER_BUTTON", + "", "SIO_POWER_GOOD", "NMI_BUTTON", "RESET_BUTTON", "SIO_S5", + "SIO_ONCONTROL", "", "", "", "", + "", "", "", "", "", + "", "", "", "", "", + "", "", "", "", "", + "", "", "", "", "", + "", "", "", "", "", + "", "", "", "", ""; + fan1 { + inst =3D <0x27>; + fail =3D <0x29>; + id =3D <0x2B>; + bit =3D <0x01>; + }; + fan2 { + inst =3D <0x27>; + fail =3D <0x29>; + id =3D <0x2B>; + bit =3D <0x02>; + }; + fan3 { + inst =3D <0x27>; + fail =3D <0x29>; + id =3D <0x2B>; + bit =3D <0x04>; + }; + fan4 { + inst =3D <0x27>; + fail =3D <0x29>; + id =3D <0x2B>; + bit =3D <0x08>; + }; + fan5 { + inst =3D <0x27>; + fail =3D <0x29>; + id =3D <0x2B>; + bit =3D <0x10>; + }; + fan6 { + inst =3D <0x27>; + fail =3D <0x29>; + id =3D <0x2B>; + bit =3D <0x40>; + }; + fan7 { + inst =3D <0x27>; + fail =3D <0x29>; + id =3D <0x2B>; + bit =3D <0x40>; + }; + fan8 { + inst =3D <0x27>; + fail =3D <0x29>; + id =3D <0x2B>; + bit =3D <0x80>; + }; + fan9 { + inst =3D <0x28>; + fail =3D <0x2A>; + id =3D <0x2C>; + bit =3D <0x01>; + }; + fan10 { + inst =3D <0x28>; + fail =3D <0x2A>; + id =3D <0x2C>; + bit =3D <0x02>; + }; + fan11 { + inst =3D <0x28>; + fail =3D <0x2A>; + id =3D <0x2C>; + bit =3D <0x04>; + }; + fan12 { + inst =3D <0x28>; + fail =3D <0x2A>; + id =3D <0x2C>; + bit =3D <0x08>; + }; + fan13 { + inst =3D <0x28>; + fail =3D <0x2A>; + id =3D <0x2C>; + bit =3D <0x10>; + }; + fan14 { + inst =3D <0x28>; + fail =3D <0x2A>; + id =3D <0x2C>; + bit =3D <0x20>; + }; + fan15 { + inst =3D <0x28>; + fail =3D <0x2A>; + id =3D <0x2C>; + bit =3D <0x40>; + }; + fan16 { + inst =3D <0x28>; + fail =3D <0x2A>; + id =3D <0x2C>; + bit =3D <0x80>; + }; + healthled { + red =3D <0x0D 0x20>; + amber =3D <0x0D 0x30>; + green =3D <0x0D 0x10>; + }; + iopled1 { + on =3D <0x04 0x01>; + }; + iopled2 { + on =3D <0x04 0x02>; + }; + iopled3 { + on =3D <0x04 0x04>; + }; + iopled4 { + on =3D <0x04 0x08>; + }; + iopled5 { + on =3D <0x04 0x10>; + }; + iopled6 { + on =3D <0x04 0x20>; + }; + iopled7 { + on =3D <0x04 0x40>; + }; + iopled8 { + on =3D <0x04 0x80>; + }; + identifyled { + on =3D <0x05 0xC0>; + off =3D <0x05 0x40>; + }; + acm { + forceoff =3D <0x0A 0x01>; + removed =3D <0x0A 0x02>; + unlatchreq =3D <0x0A 0x04>; + }; + serverid { + lower =3D <0x01 0xFF>; + upper =3D <0x02 0xFF>; + }; + sideband { + disabled =3D <0x40 0x03>; + embedded =3D <0x40 0x02>; + adaptive =3D <0x40 0x01>; + }; + grp5intflag { + ack =3D <0xB0 0xFF>; + pwrbtn =3D <0xB0 0x01>; + uidpress =3D <0xB0 0x02>; + slpint =3D <0xB0 0x04>; + }; + grp5intmask { + pwrbtn =3D <0xB1 0x01>; + slpint =3D <0xB1 0x40>; + }; + grpintsmasks { + grp5 =3D <0x88 0x10>; + }; + grpintsflags { + grp5 =3D <0x8C 0x10>; + }; + pwrbtn { + latch =3D <0x0F 0xFF 0x04>; + }; }; diff --git a/arch/arm/boot/dts/hpe-gxp.dtsi b/arch/arm/boot/dts/hpe-gxp.dtsi index cf735b3c4f35..96003667bebe 100644 --- a/arch/arm/boot/dts/hpe-gxp.dtsi +++ b/arch/arm/boot/dts/hpe-gxp.dtsi @@ -56,9 +56,28 @@ compatible =3D "simple-bus"; #address-cells =3D <1>; #size-cells =3D <1>; - ranges =3D <0x0 0xc0000000 0x30000000>; + ranges =3D <0x0 0xc0000000 0x40000000>; dma-ranges; =20 + spifi: spi@200 { + compatible =3D "hpe,gxp-spifi"; + reg =3D <0x200 0x80>, <0xc000 0x100>, <0x38000000 0x8000000>; + interrupts =3D <20>; + interrupt-parent =3D <&vic0>; + #address-cells =3D <1>; + #size-cells =3D <0>; + status =3D "disabled"; + flash@0 { + reg =3D <0>; + compatible =3D "jedec,spi-nor"; + }; + + flash@1 { + reg =3D <1>; + compatible =3D "jedec,spi-nor"; + }; + }; + vic0: interrupt-controller@eff0000 { compatible =3D "arm,pl192-vic"; reg =3D <0xeff0000 0x1000>; @@ -122,6 +141,13 @@ interrupts =3D <6>; interrupt-parent =3D <&vic0>; }; + + plreg: plreg@d1000000 { + compatible =3D "hpe,gxp-plreg", "simple-mfd", "syscon"; + reg =3D <0xd1000000 0xff>; + interrupts =3D <26>; + interrupt-parent =3D <&vic0>; + }; }; }; }; --=20 2.17.1