From patchwork Tue Apr 9 09:07:03 2019
Content-Type: text/plain; charset="utf-8"
MIME-Version: 1.0
Content-Transfer-Encoding: 7bit
X-Patchwork-Submitter: Pascal Paillet
X-Patchwork-Id: 10890811
Return-Path:
Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org
[172.30.200.125])
by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id DBF9E17E6
for ;
Tue, 9 Apr 2019 09:09:03 +0000 (UTC)
Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1])
by mail.wl.linuxfoundation.org (Postfix) with ESMTP id BF29C28832
for ;
Tue, 9 Apr 2019 09:09:03 +0000 (UTC)
Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486)
id B048728898; Tue, 9 Apr 2019 09:09:03 +0000 (UTC)
X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on
pdx-wl-mail.web.codeaurora.org
X-Spam-Level:
X-Spam-Status: No, score=-5.2 required=2.0 tests=BAYES_00,DKIM_SIGNED,
DKIM_VALID,MAILING_LIST_MULTI,RCVD_IN_DNSWL_MED autolearn=ham version=3.3.1
Received: from bombadil.infradead.org (bombadil.infradead.org
[198.137.202.133])
(using TLSv1.2 with cipher AES256-GCM-SHA384 (256/256 bits))
(No client certificate requested)
by mail.wl.linuxfoundation.org (Postfix) with ESMTPS id 2CC8428832
for ;
Tue, 9 Apr 2019 09:09:03 +0000 (UTC)
DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed;
d=lists.infradead.org; s=bombadil.20170209; h=Sender:
Content-Transfer-Encoding:Content-Type:Cc:List-Subscribe:List-Help:List-Post:
List-Archive:List-Unsubscribe:List-Id:MIME-Version:In-Reply-To:References:
Message-ID:Date:Subject:To:From:Reply-To:Content-ID:Content-Description:
Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:
List-Owner; bh=KeZKpBpdV0exe+1ZoJxu/3mDCIsDO1xA8Dag4I5G0Iw=; b=XUgXHu88DG8p1F
vkZclw6mC+afaijokGOvCJ9QRBvy3khyW2pmvyPBzIJ0+RUo8ctVBB6ui+TxTfj+eSYwu64xaVu35
pEE2uOq7iuQzUADY9v4wXZim2eI7dI4d860FJv5vrKiv743R3shrkOWXHyTH79p90upjp2IbJc0uI
KUYVhz9EwBnnZKgM0qGDYOa67KxoeOfSmN7ep5ExrEr9pkZZ+phzp/SeKOmbHx6PZpE7RL7o2ZdC9
vi+tT8p+NKIXy6wd/Mj/1lNGl2UR6l78f3cgjk4eDMwELF5Bm8kN9FzeYUa1O9IjyxW0e2Q2FIgRr
vj6JqSxbT7kqDFFZ4lrQ==;
Received: from localhost ([127.0.0.1] helo=bombadil.infradead.org)
by bombadil.infradead.org with esmtp (Exim 4.90_1 #2 (Red Hat Linux))
id 1hDmkT-0008LW-5Q; Tue, 09 Apr 2019 09:08:57 +0000
Received: from mx08-00178001.pphosted.com ([91.207.212.93]
helo=mx07-00178001.pphosted.com)
by bombadil.infradead.org with esmtps (Exim 4.90_1 #2 (Red Hat Linux))
id 1hDmja-0007WE-TV
for linux-arm-kernel@lists.infradead.org; Tue, 09 Apr 2019 09:08:04 +0000
Received: from pps.filterd (m0046661.ppops.net [127.0.0.1])
by mx08-00178001.pphosted.com (8.16.0.27/8.16.0.27) with SMTP id
x398pmKP021436; Tue, 9 Apr 2019 11:07:11 +0200
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=st.com;
h=from : to : cc : subject
: date : message-id : references : in-reply-to : content-type :
content-transfer-encoding : mime-version; s=STMicroelectronics;
bh=hHT9Ly9nAzaF/qpOAbbdbqdWgGi3WGKDqJqHavDy+No=;
b=m0TAVI6aUx4Nw//2qtgQPB8Zw/uR0gF5JRbsNhqCcDWQfz7GuEXKjIFFa1gemlAk/SBT
rF7JoRKm7PJk8AS/9DADopvj1Rw7ITWFP72QRERLbtb+mUFkho9uvPEpvzOy0K4xWl/g
cjye7ltqZy6LAPa7TpJsH58AXHl3DC7D6vmhnE7dMF2VUzc6XoVJupi8Lv+UeFIBntV6
K/1m+ektXrfka61maqYRlUrzZiICbiJgtGedU5el+QyWBwOwYqKuh2WbuBwBQw4J0j5l
vW7vKhbpHbq46j4XeyJmkJsiXl93o2vXQljyuh2C6/GXKuoUOkTbdaKlqw1voGZsiA6F 8A==
Received: from beta.dmz-eu.st.com (beta.dmz-eu.st.com [164.129.1.35])
by mx08-00178001.pphosted.com with ESMTP id 2rpr7wgkf7-1
(version=TLSv1 cipher=ECDHE-RSA-AES256-SHA bits=256 verify=NOT);
Tue, 09 Apr 2019 11:07:11 +0200
Received: from zeta.dmz-eu.st.com (zeta.dmz-eu.st.com [164.129.230.9])
by beta.dmz-eu.st.com (STMicroelectronics) with ESMTP id B73CC41;
Tue, 9 Apr 2019 09:07:03 +0000 (GMT)
Received: from Webmail-eu.st.com (sfhdag3node1.st.com [10.75.127.7])
by zeta.dmz-eu.st.com (STMicroelectronics) with ESMTP id 864942723;
Tue, 9 Apr 2019 09:07:03 +0000 (GMT)
Received: from SFHDAG6NODE2.st.com (10.75.127.17) by SFHDAG3NODE1.st.com
(10.75.127.7) with Microsoft SMTP Server (TLS) id 15.0.1347.2; Tue, 9 Apr
2019 11:07:03 +0200
Received: from SFHDAG6NODE2.st.com ([fe80::a56f:c186:bab7:13d6]) by
SFHDAG6NODE2.st.com ([fe80::a56f:c186:bab7:13d6%20]) with mapi id
15.00.1347.000; Tue, 9 Apr 2019 11:07:03 +0200
From: Pascal PAILLET-LME
To: "mcoquelin.stm32@gmail.com" , Alexandre TORGUE
, "robh+dt@kernel.org" ,
"mark.rutland@arm.com" , "linux@armlinux.org.uk"
, "horms+renesas@verge.net.au"
,
"olof@lixom.net" , "arnd@arndb.de" ,
"geert+renesas@glider.be" ,
"biju.das@bp.renesas.com" ,
Yannick FERTRE ,
"m.szyprowski@samsung.com" ,
"linus.walleij@linaro.org" ,
"linux-stm32@st-md-mailman.stormreply.com"
,
"linux-arm-kernel@lists.infradead.org"
, "devicetree@vger.kernel.org"
, "linux-kernel@vger.kernel.org"
Subject: [PATCH v2 1/3] ARM: dts: stm32: add stpmic1 support on stm32mp157c
ed1 board
Thread-Topic: [PATCH v2 1/3] ARM: dts: stm32: add stpmic1 support on
stm32mp157c ed1 board
Thread-Index: AQHU7rOY2tQ9FLm5QkG9QC4VO8EW1g==
Date: Tue, 9 Apr 2019 09:07:03 +0000
Message-ID: <1554800820-5412-2-git-send-email-p.paillet@st.com>
References: <1554800820-5412-1-git-send-email-p.paillet@st.com>
In-Reply-To: <1554800820-5412-1-git-send-email-p.paillet@st.com>
Accept-Language: en-US
Content-Language: en-US
X-MS-Has-Attach:
X-MS-TNEF-Correlator:
x-ms-exchange-messagesentrepresentingtype: 1
x-ms-exchange-transport-fromentityheader: Hosted
x-originating-ip: [10.75.127.48]
MIME-Version: 1.0
X-Proofpoint-Virus-Version: vendor=fsecure engine=2.50.10434:, ,
definitions=2019-04-09_03:, , signatures=0
X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3
X-CRM114-CacheID: sfid-20190409_020803_248356_2AADFAC4
X-CRM114-Status: GOOD ( 15.25 )
X-BeenThere: linux-arm-kernel@lists.infradead.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id:
List-Unsubscribe:
,
List-Archive:
List-Post:
List-Help:
List-Subscribe:
,
Cc: Pascal PAILLET-LME ,
"linux-stm32@st-md-mailman.stormreply.com"
Sender: "linux-arm-kernel"
Errors-To:
linux-arm-kernel-bounces+patchwork-linux-arm=patchwork.kernel.org@lists.infradead.org
X-Virus-Scanned: ClamAV using ClamSMTP
This patch adds stpmic1 support on stm32mp157c ed1 board.
The STPMIC1 is a PMIC from STMicroelectronics. The STPMIC1 integrates 10
regulators, 3 power switches, a watchdog and an input for a power on key.
The DMAs are disabled because the PMIC generates a very few traffic and
DMA channels may lack for other usage.
Signed-off-by: Pascal Paillet
Reviewed-by: Linus Walleij
---
arch/arm/boot/dts/stm32mp157c-ed1.dts | 156 ++++++++++++++++++++++++++++++----
1 file changed, 140 insertions(+), 16 deletions(-)
diff --git a/arch/arm/boot/dts/stm32mp157c-ed1.dts b/arch/arm/boot/dts/stm32mp157c-ed1.dts
index 9fd7943..62a8c78 100644
--- a/arch/arm/boot/dts/stm32mp157c-ed1.dts
+++ b/arch/arm/boot/dts/stm32mp157c-ed1.dts
@@ -8,6 +8,7 @@
#include "stm32mp157c.dtsi"
#include "stm32mp157-pinctrl.dtsi"
#include
+#include
/ {
model = "STMicroelectronics STM32MP157C eval daughter";
@@ -42,22 +43,6 @@
regulator-always-on;
};
- vdd_sd: regulator-vdd_sd {
- compatible = "regulator-fixed";
- regulator-name = "vdd_sd";
- regulator-min-microvolt = <3300000>;
- regulator-max-microvolt = <3300000>;
- regulator-always-on;
- };
-
- vdd_usb: vdd-usb {
- compatible = "regulator-fixed";
- regulator-name = "vdd_usb";
- regulator-min-microvolt = <3300000>;
- regulator-max-microvolt = <3300000>;
- regulator-always-on;
- };
-
sd_switch: regulator-sd_switch {
compatible = "regulator-gpio";
regulator-name = "sd_switch";
@@ -82,6 +67,145 @@
i2c-scl-rising-time-ns = <185>;
i2c-scl-falling-time-ns = <20>;
status = "okay";
+ /* spare dmas for other usage */
+ /delete-property/dmas;
+ /delete-property/dma-names;
+
+ pmic: stpmic@33 {
+ compatible = "st,stpmic1";
+ reg = <0x33>;
+ interrupts-extended = <&gpioa 0 IRQ_TYPE_EDGE_FALLING>;
+ interrupt-controller;
+ #interrupt-cells = <2>;
+ status = "okay";
+
+ regulators {
+ compatible = "st,stpmic1-regulators";
+ ldo1-supply = <&v3v3>;
+ ldo2-supply = <&v3v3>;
+ ldo3-supply = <&vdd_ddr>;
+ ldo5-supply = <&v3v3>;
+ ldo6-supply = <&v3v3>;
+ pwr_sw1-supply = <&bst_out>;
+ pwr_sw2-supply = <&bst_out>;
+
+ vddcore: buck1 {
+ regulator-name = "vddcore";
+ regulator-min-microvolt = <800000>;
+ regulator-max-microvolt = <1350000>;
+ regulator-always-on;
+ regulator-initial-mode = <0>;
+ regulator-over-current-protection;
+ };
+
+ vdd_ddr: buck2 {
+ regulator-name = "vdd_ddr";
+ regulator-min-microvolt = <1350000>;
+ regulator-max-microvolt = <1350000>;
+ regulator-always-on;
+ regulator-initial-mode = <0>;
+ regulator-over-current-protection;
+ };
+
+ vdd: buck3 {
+ regulator-name = "vdd";
+ regulator-min-microvolt = <3300000>;
+ regulator-max-microvolt = <3300000>;
+ regulator-always-on;
+ st,mask-reset;
+ regulator-initial-mode = <0>;
+ regulator-over-current-protection;
+ };
+
+ v3v3: buck4 {
+ regulator-name = "v3v3";
+ regulator-min-microvolt = <3300000>;
+ regulator-max-microvolt = <3300000>;
+ regulator-always-on;
+ regulator-over-current-protection;
+ regulator-initial-mode = <0>;
+ };
+
+ vdda: ldo1 {
+ regulator-name = "vdda";
+ regulator-min-microvolt = <2900000>;
+ regulator-max-microvolt = <2900000>;
+ interrupts = ;
+ };
+
+ v2v8: ldo2 {
+ regulator-name = "v2v8";
+ regulator-min-microvolt = <2800000>;
+ regulator-max-microvolt = <2800000>;
+ interrupts = ;
+ };
+
+ vtt_ddr: ldo3 {
+ regulator-name = "vtt_ddr";
+ regulator-min-microvolt = <500000>;
+ regulator-max-microvolt = <750000>;
+ regulator-always-on;
+ regulator-over-current-protection;
+ };
+
+ vdd_usb: ldo4 {
+ regulator-name = "vdd_usb";
+ regulator-min-microvolt = <3300000>;
+ regulator-max-microvolt = <3300000>;
+ interrupts = ;
+ };
+
+ vdd_sd: ldo5 {
+ regulator-name = "vdd_sd";
+ regulator-min-microvolt = <2900000>;
+ regulator-max-microvolt = <2900000>;
+ interrupts = ;
+ regulator-boot-on;
+ };
+
+ v1v8: ldo6 {
+ regulator-name = "v1v8";
+ regulator-min-microvolt = <1800000>;
+ regulator-max-microvolt = <1800000>;
+ interrupts = ;
+ };
+
+ vref_ddr: vref_ddr {
+ regulator-name = "vref_ddr";
+ regulator-always-on;
+ regulator-over-current-protection;
+ };
+
+ bst_out: boost {
+ regulator-name = "bst_out";
+ interrupts = ;
+ };
+
+ vbus_otg: pwr_sw1 {
+ regulator-name = "vbus_otg";
+ interrupts = ;
+ };
+
+ vbus_sw: pwr_sw2 {
+ regulator-name = "vbus_sw";
+ interrupts = ;
+ regulator-active-discharge;
+ };
+ };
+
+ onkey {
+ compatible = "st,stpmic1-onkey";
+ interrupts = , ;
+ interrupt-names = "onkey-falling", "onkey-rising";
+ power-off-time-sec = <10>;
+ status = "okay";
+ };
+
+ watchdog {
+ compatible = "st,stpmic1-wdt";
+ status = "disabled";
+ };
+ };
};
&ipcc {
From patchwork Tue Apr 9 09:07:03 2019
Content-Type: text/plain; charset="utf-8"
MIME-Version: 1.0
Content-Transfer-Encoding: 7bit
X-Patchwork-Submitter: Pascal Paillet
X-Patchwork-Id: 10890809
Return-Path:
Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org
[172.30.200.125])
by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id 5751617E6
for ;
Tue, 9 Apr 2019 09:08:42 +0000 (UTC)
Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1])
by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 3DAA828832
for ;
Tue, 9 Apr 2019 09:08:42 +0000 (UTC)
Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486)
id 30DAD28898; Tue, 9 Apr 2019 09:08:42 +0000 (UTC)
X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on
pdx-wl-mail.web.codeaurora.org
X-Spam-Level:
X-Spam-Status: No, score=-5.2 required=2.0 tests=BAYES_00,DKIM_SIGNED,
DKIM_VALID,MAILING_LIST_MULTI,RCVD_IN_DNSWL_MED autolearn=ham version=3.3.1
Received: from bombadil.infradead.org (bombadil.infradead.org
[198.137.202.133])
(using TLSv1.2 with cipher AES256-GCM-SHA384 (256/256 bits))
(No client certificate requested)
by mail.wl.linuxfoundation.org (Postfix) with ESMTPS id A96D028832
for ;
Tue, 9 Apr 2019 09:08:41 +0000 (UTC)
DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed;
d=lists.infradead.org; s=bombadil.20170209; h=Sender:
Content-Transfer-Encoding:Content-Type:Cc:List-Subscribe:List-Help:List-Post:
List-Archive:List-Unsubscribe:List-Id:MIME-Version:In-Reply-To:References:
Message-ID:Date:Subject:To:From:Reply-To:Content-ID:Content-Description:
Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:
List-Owner; bh=zZqWa6pz9VWHOa0LxKAGW1XOwXxaM4F+fxG7SETu83A=; b=oE/LYHmHtK9+Tz
k4vPVjHGf8oyGHgMz7T6gHU/3qKmm1g6W2nf0e8NnFWYwhVWcSZE56AxhuGVbqTl6McW0KpILFqW3
Quj5O7fJ82DiR7ed70aYsCJi6FJY+2822T3EHt/DvFuHAKtzMrwPFnWnPKJZy074lp6dkSyanSzUr
WciPQHhUlUMsgVBwgby8ZPzg1ahH88CRc3ZwpM7OpRIoounxIoGRTEe84fEeAfKsWUeYGjWf6/htF
TNKxvsrbTnCd1AxGoUg99p1JnQwEMGo0wKsE2AZMy9kTyebAwC/Ap9OTcQEYICska42jYB1/XrHrZ
JTx4E2taW7DXgk5Kx/Hw==;
Received: from localhost ([127.0.0.1] helo=bombadil.infradead.org)
by bombadil.infradead.org with esmtp (Exim 4.90_1 #2 (Red Hat Linux))
id 1hDmkC-00084K-IY; Tue, 09 Apr 2019 09:08:40 +0000
Received: from mx08-00178001.pphosted.com ([91.207.212.93]
helo=mx07-00178001.pphosted.com)
by bombadil.infradead.org with esmtps (Exim 4.90_1 #2 (Red Hat Linux))
id 1hDmja-0007WF-TW
for linux-arm-kernel@lists.infradead.org; Tue, 09 Apr 2019 09:08:04 +0000
Received: from pps.filterd (m0046661.ppops.net [127.0.0.1])
by mx08-00178001.pphosted.com (8.16.0.27/8.16.0.27) with SMTP id
x398pmKO021436; Tue, 9 Apr 2019 11:07:10 +0200
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=st.com;
h=from : to : cc : subject
: date : message-id : references : in-reply-to : content-type :
content-transfer-encoding : mime-version; s=STMicroelectronics;
bh=Ihw2vSvs6AA0LkCRPUc9omKGsQLZXtdPzeoLMV4GV8M=;
b=bGE76B1mDj+fmCfRs1h/HgHbFOQti3turh+Z0DoL+8SRZAGp5cGdzmasNCHDBnbl76CH
+V9nTL4rn+IE5M43qX1ZGoG87IUs/RcHe101yFlh4uvavmKroLqd2ISJ++BCLN9IUUnw
itYBSF8MUl5T471hizzoQ3ao8hmpghiiL98yYuDsWejl9PiyRCP0wRkT84DQ/st3z9l5
ef+bVVXiSE+F4KtdPshtayDRkRQ5WTiuK7BqPJOyt8ooEqV/RYnvZ5h0K9XUy/odYS/0
Rp+XGC/SddDgmH512IlMD9DhiFYmfrMUY7g6N5oYy9y4EnyMrbRV4GuJhUfhbkcZ6WQz uA==
Received: from beta.dmz-eu.st.com (beta.dmz-eu.st.com [164.129.1.35])
by mx08-00178001.pphosted.com with ESMTP id 2rpr7wgkf6-1
(version=TLSv1 cipher=ECDHE-RSA-AES256-SHA bits=256 verify=NOT);
Tue, 09 Apr 2019 11:07:10 +0200
Received: from zeta.dmz-eu.st.com (zeta.dmz-eu.st.com [164.129.230.9])
by beta.dmz-eu.st.com (STMicroelectronics) with ESMTP id 4DD7F31;
Tue, 9 Apr 2019 09:07:04 +0000 (GMT)
Received: from Webmail-eu.st.com (sfhdag6node3.st.com [10.75.127.18])
by zeta.dmz-eu.st.com (STMicroelectronics) with ESMTP id 13E562748;
Tue, 9 Apr 2019 09:07:04 +0000 (GMT)
Received: from SFHDAG6NODE2.st.com (10.75.127.17) by SFHDAG6NODE3.st.com
(10.75.127.18) with Microsoft SMTP Server (TLS) id 15.0.1347.2; Tue, 9 Apr
2019 11:07:03 +0200
Received: from SFHDAG6NODE2.st.com ([fe80::a56f:c186:bab7:13d6]) by
SFHDAG6NODE2.st.com ([fe80::a56f:c186:bab7:13d6%20]) with mapi id
15.00.1347.000; Tue, 9 Apr 2019 11:07:03 +0200
From: Pascal PAILLET-LME
To: "mcoquelin.stm32@gmail.com" , Alexandre TORGUE
, "robh+dt@kernel.org" ,
"mark.rutland@arm.com" , "linux@armlinux.org.uk"
, "horms+renesas@verge.net.au"
,
"olof@lixom.net" , "arnd@arndb.de" ,
"geert+renesas@glider.be" ,
"biju.das@bp.renesas.com" ,
Yannick FERTRE ,
"m.szyprowski@samsung.com" ,
"linus.walleij@linaro.org" ,
"linux-stm32@st-md-mailman.stormreply.com"
,
"linux-arm-kernel@lists.infradead.org"
, "devicetree@vger.kernel.org"
, "linux-kernel@vger.kernel.org"
Subject: [PATCH v2 2/3] ARM: dts: stm32: add stpmic1 support on stm32mp157a
dk1 board
Thread-Topic: [PATCH v2 2/3] ARM: dts: stm32: add stpmic1 support on
stm32mp157a dk1 board
Thread-Index: AQHU7rOZC+/rg+MUg028eou+9g6Okw==
Date: Tue, 9 Apr 2019 09:07:03 +0000
Message-ID: <1554800820-5412-3-git-send-email-p.paillet@st.com>
References: <1554800820-5412-1-git-send-email-p.paillet@st.com>
In-Reply-To: <1554800820-5412-1-git-send-email-p.paillet@st.com>
Accept-Language: en-US
Content-Language: en-US
X-MS-Has-Attach:
X-MS-TNEF-Correlator:
x-ms-exchange-messagesentrepresentingtype: 1
x-ms-exchange-transport-fromentityheader: Hosted
x-originating-ip: [10.75.127.48]
MIME-Version: 1.0
X-Proofpoint-Virus-Version: vendor=fsecure engine=2.50.10434:, ,
definitions=2019-04-09_03:, , signatures=0
X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3
X-CRM114-CacheID: sfid-20190409_020803_251554_914BE048
X-CRM114-Status: GOOD ( 15.62 )
X-BeenThere: linux-arm-kernel@lists.infradead.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id:
List-Unsubscribe:
,
List-Archive:
List-Post:
List-Help:
List-Subscribe:
,
Cc: Pascal PAILLET-LME ,
"linux-stm32@st-md-mailman.stormreply.com"
Sender: "linux-arm-kernel"
Errors-To:
linux-arm-kernel-bounces+patchwork-linux-arm=patchwork.kernel.org@lists.infradead.org
X-Virus-Scanned: ClamAV using ClamSMTP
This patch adds stpmic1 support on stm32mp157a dk1 board.
The STPMIC1 is a PMIC from STMicroelectronics. The STPMIC1 integrates 10
regulators, 3 power switches, a watchdog and an input for a power on key.
The DMAs are disabled because the PMIC generates a very few traffic and
DMA channels may lack for other usage.
Signed-off-by: Pascal Paillet
Reviewed-by: Linus Walleij
---
arch/arm/boot/dts/stm32mp157a-dk1.dts | 158 ++++++++++++++++++++++++++++++++--
1 file changed, 150 insertions(+), 8 deletions(-)
diff --git a/arch/arm/boot/dts/stm32mp157a-dk1.dts b/arch/arm/boot/dts/stm32mp157a-dk1.dts
index 1b1886d..4bb91ab 100644
--- a/arch/arm/boot/dts/stm32mp157a-dk1.dts
+++ b/arch/arm/boot/dts/stm32mp157a-dk1.dts
@@ -9,6 +9,7 @@
#include "stm32mp157c.dtsi"
#include "stm32mp157-pinctrl.dtsi"
#include
+#include
/ {
model = "STMicroelectronics STM32MP157A-DK1 Discovery Board";
@@ -36,14 +37,6 @@
default-state = "off";
};
};
-
- v3v3: regulator-3v3 {
- compatible = "regulator-fixed";
- regulator-name = "v3v3";
- regulator-min-microvolt = <3300000>;
- regulator-max-microvolt = <3300000>;
- regulator-always-on;
- };
};
ðernet0 {
@@ -65,6 +58,155 @@
};
};
+
+&i2c4 {
+ pinctrl-names = "default";
+ pinctrl-0 = <&i2c4_pins_a>;
+ i2c-scl-rising-time-ns = <185>;
+ i2c-scl-falling-time-ns = <20>;
+ status = "okay";
+ /* spare dmas for other usage */
+ /delete-property/dmas;
+ /delete-property/dma-names;
+
+ pmic: stpmic@33 {
+ compatible = "st,stpmic1";
+ reg = <0x33>;
+ interrupts-extended = <&gpioa 0 IRQ_TYPE_EDGE_FALLING>;
+ interrupt-controller;
+ #interrupt-cells = <2>;
+ status = "okay";
+
+ regulators {
+ compatible = "st,stpmic1-regulators";
+ ldo1-supply = <&v3v3>;
+ ldo3-supply = <&vdd_ddr>;
+ ldo6-supply = <&v3v3>;
+ pwr_sw1-supply = <&bst_out>;
+ pwr_sw2-supply = <&bst_out>;
+
+ vddcore: buck1 {
+ regulator-name = "vddcore";
+ regulator-min-microvolt = <800000>;
+ regulator-max-microvolt = <1350000>;
+ regulator-always-on;
+ regulator-initial-mode = <0>;
+ regulator-over-current-protection;
+ };
+
+ vdd_ddr: buck2 {
+ regulator-name = "vdd_ddr";
+ regulator-min-microvolt = <1350000>;
+ regulator-max-microvolt = <1350000>;
+ regulator-always-on;
+ regulator-initial-mode = <0>;
+ regulator-over-current-protection;
+ };
+
+ vdd: buck3 {
+ regulator-name = "vdd";
+ regulator-min-microvolt = <3300000>;
+ regulator-max-microvolt = <3300000>;
+ regulator-always-on;
+ st,mask-reset;
+ regulator-initial-mode = <0>;
+ regulator-over-current-protection;
+ };
+
+ v3v3: buck4 {
+ regulator-name = "v3v3";
+ regulator-min-microvolt = <3300000>;
+ regulator-max-microvolt = <3300000>;
+ regulator-always-on;
+ regulator-over-current-protection;
+ regulator-initial-mode = <0>;
+ };
+
+ v1v8_audio: ldo1 {
+ regulator-name = "v1v8_audio";
+ regulator-min-microvolt = <1800000>;
+ regulator-max-microvolt = <1800000>;
+ regulator-always-on;
+ interrupts = ;
+ };
+
+ v3v3_hdmi: ldo2 {
+ regulator-name = "v3v3_hdmi";
+ regulator-min-microvolt = <3300000>;
+ regulator-max-microvolt = <3300000>;
+ regulator-always-on;
+ interrupts = ;
+ };
+
+ vtt_ddr: ldo3 {
+ regulator-name = "vtt_ddr";
+ regulator-min-microvolt = <500000>;
+ regulator-max-microvolt = <750000>;
+ regulator-always-on;
+ regulator-over-current-protection;
+ };
+
+ vdd_usb: ldo4 {
+ regulator-name = "vdd_usb";
+ regulator-min-microvolt = <3300000>;
+ regulator-max-microvolt = <3300000>;
+ interrupts = ;
+ };
+
+ vdda: ldo5 {
+ regulator-name = "vdda";
+ regulator-min-microvolt = <2900000>;
+ regulator-max-microvolt = <2900000>;
+ interrupts = ;
+ regulator-boot-on;
+ };
+
+ v1v2_hdmi: ldo6 {
+ regulator-name = "v1v2_hdmi";
+ regulator-min-microvolt = <1200000>;
+ regulator-max-microvolt = <1200000>;
+ regulator-always-on;
+ interrupts = ;
+ };
+
+ vref_ddr: vref_ddr {
+ regulator-name = "vref_ddr";
+ regulator-always-on;
+ regulator-over-current-protection;
+ };
+
+ bst_out: boost {
+ regulator-name = "bst_out";
+ interrupts = ;
+ };
+
+ vbus_otg: pwr_sw1 {
+ regulator-name = "vbus_otg";
+ interrupts = ;
+ };
+
+ vbus_sw: pwr_sw2 {
+ regulator-name = "vbus_sw";
+ interrupts = ;
+ regulator-active-discharge;
+ };
+ };
+
+ onkey {
+ compatible = "st,stpmic1-onkey";
+ interrupts = , ;
+ interrupt-names = "onkey-falling", "onkey-rising";
+ power-off-time-sec = <10>;
+ status = "okay";
+ };
+
+ watchdog {
+ compatible = "st,stpmic1-wdt";
+ status = "disabled";
+ };
+ };
+};
+
&ipcc {
status = "okay";
};
From patchwork Tue Apr 9 09:07:04 2019
Content-Type: text/plain; charset="utf-8"
MIME-Version: 1.0
Content-Transfer-Encoding: 7bit
X-Patchwork-Submitter: Pascal Paillet
X-Patchwork-Id: 10890807
Return-Path:
Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org
[172.30.200.125])
by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id 74A431800
for ;
Tue, 9 Apr 2019 09:08:24 +0000 (UTC)
Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1])
by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 5B1B028832
for ;
Tue, 9 Apr 2019 09:08:24 +0000 (UTC)
Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486)
id 4EA9828898; Tue, 9 Apr 2019 09:08:24 +0000 (UTC)
X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on
pdx-wl-mail.web.codeaurora.org
X-Spam-Level:
X-Spam-Status: No, score=-5.2 required=2.0 tests=BAYES_00,DKIM_SIGNED,
DKIM_VALID,MAILING_LIST_MULTI,RCVD_IN_DNSWL_MED autolearn=ham version=3.3.1
Received: from bombadil.infradead.org (bombadil.infradead.org
[198.137.202.133])
(using TLSv1.2 with cipher AES256-GCM-SHA384 (256/256 bits))
(No client certificate requested)
by mail.wl.linuxfoundation.org (Postfix) with ESMTPS id F367F28832
for ;
Tue, 9 Apr 2019 09:08:23 +0000 (UTC)
DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed;
d=lists.infradead.org; s=bombadil.20170209; h=Sender:
Content-Transfer-Encoding:Content-Type:Cc:List-Subscribe:List-Help:List-Post:
List-Archive:List-Unsubscribe:List-Id:MIME-Version:In-Reply-To:References:
Message-ID:Date:Subject:To:From:Reply-To:Content-ID:Content-Description:
Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:
List-Owner; bh=yqaXktM4bpuX0iBdcJUo1FvP5b2JT1pNBXOCaHqrAJk=; b=ZeLT6f08G7uuZA
FHdKmnZEqZMBzM3ToJsCBKlTYTfKQni1BvLtyN4d5M4nt8OWNr0N+G+f25fW6xIkkUfLLXbL+xUc5
VFxMpB4QGQoD8jo1iMUBKhS9+Ms+FJgnA73kyWsB0vrRTymYZ2TdJYpWFGukMIt+MWq5FueO4ZXP9
yn7QUVspZ2Aw5JBnKJkNa8StA36g1EzKDGfLyVUs/oLGy+OmtragSokfM4wXQyubO3wu90Vi/vTNP
52iuT3qzMH3OGUxcwkmkcnAZqoawR5cO9ljbqdokSPCpKb1urS/V7L9sdhyGGRISDMloKf1kXmAQS
B6cDUkI1Phh1a7EajPCw==;
Received: from localhost ([127.0.0.1] helo=bombadil.infradead.org)
by bombadil.infradead.org with esmtp (Exim 4.90_1 #2 (Red Hat Linux))
id 1hDmjp-0007je-Lj; Tue, 09 Apr 2019 09:08:17 +0000
Received: from mx07-00178001.pphosted.com ([62.209.51.94])
by bombadil.infradead.org with esmtps (Exim 4.90_1 #2 (Red Hat Linux))
id 1hDmjY-0007Vj-KD
for linux-arm-kernel@lists.infradead.org; Tue, 09 Apr 2019 09:08:02 +0000
Received: from pps.filterd (m0046037.ppops.net [127.0.0.1])
by mx07-00178001.pphosted.com (8.16.0.27/8.16.0.27) with SMTP id
x398pR2a001068; Tue, 9 Apr 2019 11:07:05 +0200
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=st.com;
h=from : to : cc : subject
: date : message-id : references : in-reply-to : content-type :
content-transfer-encoding : mime-version; s=STMicroelectronics;
bh=Ln+cE2iR3bWe9OqMk89pox5DsPtivX4AI1CiOXAnqAA=;
b=RtZgXR2aeQM2u5lA9pX+ROgBwwByMdF60SzHkIzM/u4DIUlBh3Zi4pTf6NhLdjKOlN87
OouRRHDcG1Ij6T2a7ouxU2tXFM+Tq9bZk72LL4oaAGEBk62nxOtmR41lYkXO1bTlsB47
LnLlGkdiGXQSbgcyTc68bNhWLFvvQE7ILsuuDwds2IYRm7BDLI1LHOugq8m7Gufdy/6Q
5ihxnh71sboMdHn37HRnqzb406EP4DGb4zEzqvL3urUB0Q93kzhVbLPXyFYtYhlyyaxg
Ra3HtNiPifznO6DhZ7r1e3a1qjlwFk7Yu2xy+scapAD7zYflz0nxBhE7+6tfts4rzm8/ RQ==
Received: from beta.dmz-eu.st.com (beta.dmz-eu.st.com [164.129.1.35])
by mx07-00178001.pphosted.com with ESMTP id 2rprkdfn0j-1
(version=TLSv1 cipher=ECDHE-RSA-AES256-SHA bits=256 verify=NOT);
Tue, 09 Apr 2019 11:07:05 +0200
Received: from zeta.dmz-eu.st.com (zeta.dmz-eu.st.com [164.129.230.9])
by beta.dmz-eu.st.com (STMicroelectronics) with ESMTP id B6D8138;
Tue, 9 Apr 2019 09:07:04 +0000 (GMT)
Received: from Webmail-eu.st.com (sfhdag6node1.st.com [10.75.127.16])
by zeta.dmz-eu.st.com (STMicroelectronics) with ESMTP id 819C92749;
Tue, 9 Apr 2019 09:07:04 +0000 (GMT)
Received: from SFHDAG6NODE2.st.com (10.75.127.17) by SFHDAG6NODE1.st.com
(10.75.127.16) with Microsoft SMTP Server (TLS) id 15.0.1347.2; Tue, 9 Apr
2019 11:07:04 +0200
Received: from SFHDAG6NODE2.st.com ([fe80::a56f:c186:bab7:13d6]) by
SFHDAG6NODE2.st.com ([fe80::a56f:c186:bab7:13d6%20]) with mapi id
15.00.1347.000; Tue, 9 Apr 2019 11:07:04 +0200
From: Pascal PAILLET-LME
To: "mcoquelin.stm32@gmail.com" , Alexandre TORGUE
, "robh+dt@kernel.org" ,
"mark.rutland@arm.com" , "linux@armlinux.org.uk"
, "horms+renesas@verge.net.au"
,
"olof@lixom.net" , "arnd@arndb.de" ,
"geert+renesas@glider.be" ,
"biju.das@bp.renesas.com" ,
Yannick FERTRE ,
"m.szyprowski@samsung.com" ,
"linus.walleij@linaro.org" ,
"linux-stm32@st-md-mailman.stormreply.com"
,
"linux-arm-kernel@lists.infradead.org"
, "devicetree@vger.kernel.org"
, "linux-kernel@vger.kernel.org"
Subject: [PATCH v2 3/3] ARM: multi_v7_defconfig: Enable support for STPMIC1
Thread-Topic: [PATCH v2 3/3] ARM: multi_v7_defconfig: Enable support for
STPMIC1
Thread-Index: AQHU7rOZF5uv7QhRukKTDkHEEhAoAA==
Date: Tue, 9 Apr 2019 09:07:04 +0000
Message-ID: <1554800820-5412-4-git-send-email-p.paillet@st.com>
References: <1554800820-5412-1-git-send-email-p.paillet@st.com>
In-Reply-To: <1554800820-5412-1-git-send-email-p.paillet@st.com>
Accept-Language: en-US
Content-Language: en-US
X-MS-Has-Attach:
X-MS-TNEF-Correlator:
x-ms-exchange-messagesentrepresentingtype: 1
x-ms-exchange-transport-fromentityheader: Hosted
x-originating-ip: [10.75.127.48]
MIME-Version: 1.0
X-Proofpoint-Virus-Version: vendor=fsecure engine=2.50.10434:, ,
definitions=2019-04-09_03:, , signatures=0
X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3
X-CRM114-CacheID: sfid-20190409_020801_004473_357D0831
X-CRM114-Status: GOOD ( 12.53 )
X-BeenThere: linux-arm-kernel@lists.infradead.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id:
List-Unsubscribe:
,
List-Archive:
List-Post:
List-Help:
List-Subscribe:
,
Cc: Pascal PAILLET-LME ,
"linux-stm32@st-md-mailman.stormreply.com"
Sender: "linux-arm-kernel"
Errors-To:
linux-arm-kernel-bounces+patchwork-linux-arm=patchwork.kernel.org@lists.infradead.org
X-Virus-Scanned: ClamAV using ClamSMTP
STPMIC1 is a PMIC from STMicroelectronics. The STPMIC1 integrates 10
regulators, 3 power switches, a watchdog and an input for a power on key.
Signed-off-by: Pascal Paillet
---
arch/arm/configs/multi_v7_defconfig | 4 ++++
1 file changed, 4 insertions(+)
diff --git a/arch/arm/configs/multi_v7_defconfig b/arch/arm/configs/multi_v7_defconfig
index c75051b..2e9fa53 100644
--- a/arch/arm/configs/multi_v7_defconfig
+++ b/arch/arm/configs/multi_v7_defconfig
@@ -299,6 +299,7 @@ CONFIG_INPUT_MAX8997_HAPTIC=m
CONFIG_INPUT_CPCAP_PWRBUTTON=m
CONFIG_INPUT_AXP20X_PEK=m
CONFIG_INPUT_ADXL34X=m
+CONFIG_INPUT_STPMIC1_ONKEY=y
CONFIG_SERIO_AMBAKMI=y
CONFIG_SERIAL_8250=y
CONFIG_SERIAL_8250_CONSOLE=y
@@ -486,6 +487,7 @@ CONFIG_TEGRA_WATCHDOG=m
CONFIG_MESON_WATCHDOG=y
CONFIG_DIGICOLOR_WATCHDOG=y
CONFIG_RENESAS_WDT=m
+CONFIG_STPMIC1_WATCHDOG=y
CONFIG_BCM47XX_WDT=y
CONFIG_BCM2835_WDT=y
CONFIG_BCM_KONA_WDT=y
@@ -527,6 +529,7 @@ CONFIG_MFD_TPS65218=y
CONFIG_MFD_TPS6586X=y
CONFIG_MFD_TPS65910=y
CONFIG_MFD_STM32_LPTIMER=m
+CONFIG_MFD_STPMIC1=y
CONFIG_REGULATOR_ACT8865=y
CONFIG_REGULATOR_ACT8945A=y
CONFIG_REGULATOR_ANATOP=y
@@ -559,6 +562,7 @@ CONFIG_REGULATOR_RN5T618=y
CONFIG_REGULATOR_S2MPS11=y
CONFIG_REGULATOR_S5M8767=y
CONFIG_REGULATOR_STM32_VREFBUF=m
+CONFIG_REGULATOR_STPMIC1=y
CONFIG_REGULATOR_TI_ABB=y
CONFIG_REGULATOR_TPS51632=y
CONFIG_REGULATOR_TPS62360=y