From: <sean.wang@mediatek.com>
To: <robh+dt@kernel.org>, <matthias.bgg@gmail.com>,
<john@phrozen.org>, <mark.rutland@arm.com>,
<linux@armlinux.org.uk>, <linus.walleij@linaro.org>,
<devicetree@vger.kernel.org>,
<linux-mediatek@lists.infradead.org>
Cc: <linux-arm-kernel@lists.infradead.org>,
<linux-gpio@vger.kernel.org>, <linux-kernel@vger.kernel.org>,
Sean Wang <sean.wang@mediatek.com>
Subject: [PATCH v2 24/30] arm: dts: mt7623: add mt7623-mt6323.dtsi file
Date: Wed, 26 Apr 2017 17:26:08 +0800 [thread overview]
Message-ID: <1493198774-4478-25-git-send-email-sean.wang@mediatek.com> (raw)
In-Reply-To: <1493198774-4478-1-git-send-email-sean.wang@mediatek.com>
From: John Crispin <john@phrozen.org>
MediaTek produces various PMICs. Which one is used depends on the actual
circuit design. Instead of adding the correct PMIC node to every dts file
we instead add a new intermediate dtsi file which adds the PMIC node.
Additionally we also add the phandles for the regulators to various nodes.
Signed-off-by: John Crispin <john@phrozen.org>
Signed-off-by: Sean Wang <sean.wang@mediatek.com>
---
arch/arm/boot/dts/mt7623-evb.dts | 2 +-
arch/arm/boot/dts/mt7623-mt6323.dtsi | 269 +++++++++++++++++++++++++++++++++++
arch/arm/boot/dts/mt7623.dtsi | 8 +-
3 files changed, 274 insertions(+), 5 deletions(-)
create mode 100644 arch/arm/boot/dts/mt7623-mt6323.dtsi
diff --git a/arch/arm/boot/dts/mt7623-evb.dts b/arch/arm/boot/dts/mt7623-evb.dts
index b60b41c..a769149 100644
--- a/arch/arm/boot/dts/mt7623-evb.dts
+++ b/arch/arm/boot/dts/mt7623-evb.dts
@@ -13,7 +13,7 @@
*/
/dts-v1/;
-#include "mt7623.dtsi"
+#include "mt7623-mt6323.dtsi"
/ {
model = "MediaTek MT7623 evaluation board";
diff --git a/arch/arm/boot/dts/mt7623-mt6323.dtsi b/arch/arm/boot/dts/mt7623-mt6323.dtsi
new file mode 100644
index 0000000..93d3f71
--- /dev/null
+++ b/arch/arm/boot/dts/mt7623-mt6323.dtsi
@@ -0,0 +1,269 @@
+/*
+ * Copyright (c) 2016 MediaTek Inc.
+ * Author: John Crispin <john@phrozen.org>
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License version 2 as
+ * published by the Free Software Foundation.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ */
+
+#include "mt7623.dtsi"
+
+&cpu0 {
+ proc-supply = <&mt6323_vproc_reg>;
+};
+
+&cpu1 {
+ proc-supply = <&mt6323_vproc_reg>;
+};
+
+&cpu2 {
+ proc-supply = <&mt6323_vproc_reg>;
+};
+
+&cpu3 {
+ proc-supply = <&mt6323_vproc_reg>;
+};
+
+&pwrap {
+ pmic: mt6323 {
+ compatible = "mediatek,mt6323";
+ interrupt-parent = <&pio>;
+ interrupts = <150 IRQ_TYPE_LEVEL_HIGH>;
+ interrupt-controller;
+ #interrupt-cells = <2>;
+
+ mt6323regulator: mt6323regulator{
+ compatible = "mediatek,mt6323-regulator";
+
+ mt6323_vproc_reg: buck_vproc{
+ regulator-name = "vproc";
+ regulator-min-microvolt = < 700000>;
+ regulator-max-microvolt = <1350000>;
+ regulator-ramp-delay = <12500>;
+ regulator-always-on;
+ regulator-boot-on;
+ };
+
+ mt6323_vsys_reg: buck_vsys{
+ regulator-name = "vsys";
+ regulator-min-microvolt = <1400000>;
+ regulator-max-microvolt = <2987500>;
+ regulator-ramp-delay = <25000>;
+ regulator-always-on;
+ regulator-boot-on;
+ };
+
+ mt6323_vpa_reg: buck_vpa{
+ regulator-name = "vpa";
+ regulator-min-microvolt = < 500000>;
+ regulator-max-microvolt = <3650000>;
+ };
+
+ mt6323_vtcxo_reg: ldo_vtcxo{
+ regulator-name = "vtcxo";
+ regulator-min-microvolt = <2800000>;
+ regulator-max-microvolt = <2800000>;
+ regulator-enable-ramp-delay = <90>;
+ regulator-always-on;
+ regulator-boot-on;
+ };
+
+ mt6323_vcn28_reg: ldo_vcn28{
+ regulator-name = "vcn28";
+ regulator-min-microvolt = <2800000>;
+ regulator-max-microvolt = <2800000>;
+ regulator-enable-ramp-delay = <185>;
+ };
+
+ mt6323_vcn33_bt_reg: ldo_vcn33_bt{
+ regulator-name = "vcn33_bt";
+ regulator-min-microvolt = <3300000>;
+ regulator-max-microvolt = <3600000>;
+ regulator-enable-ramp-delay = <185>;
+ };
+
+ mt6323_vcn33_wifi_reg: ldo_vcn33_wifi{
+ regulator-name = "vcn33_wifi";
+ regulator-min-microvolt = <3300000>;
+ regulator-max-microvolt = <3600000>;
+ regulator-enable-ramp-delay = <185>;
+ };
+
+ mt6323_va_reg: ldo_va{
+ regulator-name = "va";
+ regulator-min-microvolt = <2800000>;
+ regulator-max-microvolt = <2800000>;
+ regulator-enable-ramp-delay = <216>;
+ regulator-always-on;
+ regulator-boot-on;
+ };
+
+ mt6323_vcama_reg: ldo_vcama{
+ regulator-name = "vcama";
+ regulator-min-microvolt = <1500000>;
+ regulator-max-microvolt = <2800000>;
+ regulator-enable-ramp-delay = <216>;
+ };
+
+ mt6323_vio28_reg: ldo_vio28{
+ regulator-name = "vio28";
+ regulator-min-microvolt = <2800000>;
+ regulator-max-microvolt = <2800000>;
+ regulator-enable-ramp-delay = <216>;
+ regulator-always-on;
+ regulator-boot-on;
+ };
+
+ mt6323_vusb_reg: ldo_vusb{
+ regulator-name = "vusb";
+ regulator-min-microvolt = <3300000>;
+ regulator-max-microvolt = <3300000>;
+ regulator-enable-ramp-delay = <216>;
+ regulator-boot-on;
+ };
+
+ mt6323_vmc_reg: ldo_vmc{
+ regulator-name = "vmc";
+ regulator-min-microvolt = <1800000>;
+ regulator-max-microvolt = <3300000>;
+ regulator-enable-ramp-delay = <36>;
+ regulator-boot-on;
+ };
+
+ mt6323_vmch_reg: ldo_vmch{
+ regulator-name = "vmch";
+ regulator-min-microvolt = <3000000>;
+ regulator-max-microvolt = <3300000>;
+ regulator-enable-ramp-delay = <36>;
+ regulator-boot-on;
+ };
+
+ mt6323_vemc3v3_reg: ldo_vemc3v3{
+ regulator-name = "vemc3v3";
+ regulator-min-microvolt = <3000000>;
+ regulator-max-microvolt = <3300000>;
+ regulator-enable-ramp-delay = <36>;
+ regulator-boot-on;
+ };
+
+ mt6323_vgp1_reg: ldo_vgp1{
+ regulator-name = "vgp1";
+ regulator-min-microvolt = <1200000>;
+ regulator-max-microvolt = <3300000>;
+ regulator-enable-ramp-delay = <216>;
+ };
+
+ mt6323_vgp2_reg: ldo_vgp2{
+ regulator-name = "vgp2";
+ regulator-min-microvolt = <1200000>;
+ regulator-max-microvolt = <3000000>;
+ regulator-enable-ramp-delay = <216>;
+ };
+
+ mt6323_vgp3_reg: ldo_vgp3{
+ regulator-name = "vgp3";
+ regulator-min-microvolt = <1200000>;
+ regulator-max-microvolt = <1800000>;
+ regulator-enable-ramp-delay = <216>;
+ };
+
+ mt6323_vcn18_reg: ldo_vcn18{
+ regulator-name = "vcn18";
+ regulator-min-microvolt = <1800000>;
+ regulator-max-microvolt = <1800000>;
+ regulator-enable-ramp-delay = <216>;
+ };
+
+ mt6323_vsim1_reg: ldo_vsim1{
+ regulator-name = "vsim1";
+ regulator-min-microvolt = <1800000>;
+ regulator-max-microvolt = <3000000>;
+ regulator-enable-ramp-delay = <216>;
+ };
+
+ mt6323_vsim2_reg: ldo_vsim2{
+ regulator-name = "vsim2";
+ regulator-min-microvolt = <1800000>;
+ regulator-max-microvolt = <3000000>;
+ regulator-enable-ramp-delay = <216>;
+ };
+
+ mt6323_vrtc_reg: ldo_vrtc{
+ regulator-name = "vrtc";
+ regulator-min-microvolt = <2800000>;
+ regulator-max-microvolt = <2800000>;
+ regulator-always-on;
+ regulator-boot-on;
+ };
+
+ mt6323_vcamaf_reg: ldo_vcamaf{
+ regulator-name = "vcamaf";
+ regulator-min-microvolt = <1200000>;
+ regulator-max-microvolt = <3300000>;
+ regulator-enable-ramp-delay = <216>;
+ };
+
+ mt6323_vibr_reg: ldo_vibr{
+ regulator-name = "vibr";
+ regulator-min-microvolt = <1200000>;
+ regulator-max-microvolt = <3300000>;
+ regulator-enable-ramp-delay = <36>;
+ };
+
+ mt6323_vrf18_reg: ldo_vrf18{
+ regulator-name = "vrf18";
+ regulator-min-microvolt = <1825000>;
+ regulator-max-microvolt = <1825000>;
+ regulator-enable-ramp-delay = <187>;
+ };
+
+ mt6323_vm_reg: ldo_vm{
+ regulator-name = "vm";
+ regulator-min-microvolt = <1200000>;
+ regulator-max-microvolt = <1800000>;
+ regulator-enable-ramp-delay = <216>;
+ regulator-always-on;
+ regulator-boot-on;
+ };
+
+ mt6323_vio18_reg: ldo_vio18{
+ regulator-name = "vio18";
+ regulator-min-microvolt = <1800000>;
+ regulator-max-microvolt = <1800000>;
+ regulator-enable-ramp-delay = <216>;
+ regulator-always-on;
+ regulator-boot-on;
+ };
+
+ mt6323_vcamd_reg: ldo_vcamd{
+ regulator-name = "vcamd";
+ regulator-min-microvolt = <1200000>;
+ regulator-max-microvolt = <1800000>;
+ regulator-enable-ramp-delay = <216>;
+ };
+
+ mt6323_vcamio_reg: ldo_vcamio{
+ regulator-name = "vcamio";
+ regulator-min-microvolt = <1800000>;
+ regulator-max-microvolt = <1800000>;
+ regulator-enable-ramp-delay = <216>;
+ };
+ };
+ };
+};
+
+&mmc0 {
+ vmmc-supply = <&mt6323_vemc3v3_reg>;
+ vqmmc-supply = <&mt6323_vio18_reg>;
+};
+
+&mmc1 {
+ vmmc-supply = <&mt6323_vmch_reg>;
+ vqmmc-supply = <&mt6323_vmc_reg>;
+};
diff --git a/arch/arm/boot/dts/mt7623.dtsi b/arch/arm/boot/dts/mt7623.dtsi
index d81158b2..e9e0974 100644
--- a/arch/arm/boot/dts/mt7623.dtsi
+++ b/arch/arm/boot/dts/mt7623.dtsi
@@ -32,22 +32,22 @@
#size-cells = <0>;
enable-method = "mediatek,mt6589-smp";
- cpu@0 {
+ cpu0: cpu@0 {
device_type = "cpu";
compatible = "arm,cortex-a7";
reg = <0x0>;
};
- cpu@1 {
+ cpu1: cpu@1 {
device_type = "cpu";
compatible = "arm,cortex-a7";
reg = <0x1>;
};
- cpu@2 {
+ cpu2: cpu@2 {
device_type = "cpu";
compatible = "arm,cortex-a7";
reg = <0x2>;
};
- cpu@3 {
+ cpu3: cpu@3 {
device_type = "cpu";
compatible = "arm,cortex-a7";
reg = <0x3>;
--
1.9.1
next prev parent reply other threads:[~2017-04-26 9:37 UTC|newest]
Thread overview: 46+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-04-26 9:25 [PATCH v2 00/30] arm: dts: extend mt7623 support sean.wang
2017-04-26 9:25 ` [PATCH v2 01/30] pinctrl: mediatek: Add missing pinctrl bindings for mt7623 sean.wang
2017-04-28 7:55 ` Linus Walleij
2017-04-26 9:25 ` [PATCH v2 02/30] pinctrl: mediatek: reuse pinctrl driver " sean.wang
2017-04-28 8:01 ` Linus Walleij
2017-05-01 6:44 ` Sean Wang
2017-04-26 9:25 ` [PATCH v2 03/30] arm: dts: mt7623: add clock controller device nodes sean.wang
2017-04-26 9:25 ` [PATCH v2 04/30] arm: dts: mt7623: add subsystem " sean.wang
2017-04-26 9:25 ` [PATCH v2 05/30] arm: dts: mt7623: add power domain controller device node sean.wang
2017-04-26 9:25 ` [PATCH v2 06/30] arm: dts: mt7623: add clock-frequency to the a7 timer node to mt7623.dtsi sean.wang
2017-04-26 9:25 ` [PATCH v2 07/30] arm: dts: mt7623: add pinctrl nodes to the mt7623 dtsi file sean.wang
2017-04-28 8:03 ` Linus Walleij
2017-04-26 9:25 ` [PATCH v2 08/30] arm: dts: mt7623: add pmic wrapper " sean.wang
2017-04-26 9:25 ` [PATCH v2 09/30] arm: dts: mt7623: add i2c nodes to the mt7623.dtsi file sean.wang
2017-04-26 9:25 ` [PATCH v2 10/30] arm: dts: mt7623: add spi " sean.wang
2017-04-26 9:25 ` [PATCH v2 11/30] arm: dts: mt7623: add nand " sean.wang
2017-04-26 9:25 ` [PATCH v2 12/30] arm: dts: mt7623: add mmc " sean.wang
2017-04-26 9:25 ` [PATCH v2 13/30] arm: dts: mt7623: add usb " sean.wang
2017-04-26 9:25 ` [PATCH v2 14/30] arm: dts: mt7623: add pwm " sean.wang
2017-04-26 9:25 ` [PATCH v2 15/30] arm: dts: mt7623: add ethernet " sean.wang
2017-04-26 9:26 ` [PATCH v2 16/30] arm: dts: mt7623: add crypto engine " sean.wang
2017-04-26 9:26 ` [PATCH v2 17/30] arm: dts: mt7623: add ir " sean.wang
2017-04-26 9:26 ` [PATCH v2 18/30] arm: dts: mt7623: add afe " sean.wang
2017-04-26 9:26 ` [PATCH v2 19/30] arm: dts: mt7623: add rng " sean.wang
2017-04-26 9:26 ` [PATCH v2 20/30] arm: dts: mt7623: add auxadc " sean.wang
2017-04-26 9:26 ` [PATCH v2 21/30] arm: dts: mt7623: add efuse " sean.wang
2017-04-26 9:26 ` [PATCH v2 22/30] arm: dts: mt7623: add thermal " sean.wang
2017-04-26 9:26 ` [PATCH v2 23/30] arm: dts: mt7623: add Sean as one of authors for mt7623.dtsi files sean.wang
2017-04-26 9:26 ` sean.wang [this message]
2017-04-26 9:26 ` [PATCH v2 25/30] arm: dts: mt7623: rename mt7623-evb.dts to arch/arm/boot/dts/mt7623n-rfb.dtsi sean.wang
2017-04-28 20:30 ` Rob Herring
2017-05-01 7:06 ` Sean Wang
2017-04-26 9:26 ` [PATCH v2 26/30] arm: dts: mt7623: cleanup the mt7623n rfb uart nodes sean.wang
2017-04-26 9:26 ` [PATCH v2 27/30] arm: dts: mt7623: enable the usb device on the mt7623n rfb sean.wang
2017-04-26 9:26 ` [PATCH v2 28/30] arm: dts: mt7623: enable the nand device on the mt7623n nand rfb sean.wang
2017-04-26 9:26 ` [PATCH v2 29/30] dt-bindings: add vendor prefix for bananapi sean.wang
2017-04-28 20:37 ` Rob Herring
2017-05-01 6:58 ` Sean Wang
2017-05-02 13:52 ` Rob Herring
2017-05-08 9:53 ` Sean Wang
2017-05-08 11:36 ` Arnd Bergmann
2017-05-09 7:49 ` Matthias Brugger
2017-05-09 8:03 ` Chen-Yu Tsai
2017-05-09 9:40 ` Sean Wang
2017-04-26 9:26 ` [PATCH v2 30/30] arm: dts: mt7623: add dts file for Bananapi R2 (BPI-R2) board sean.wang
2017-05-10 9:58 ` [PATCH v2 00/30] arm: dts: extend mt7623 support Matthias Brugger
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1493198774-4478-25-git-send-email-sean.wang@mediatek.com \
--to=sean.wang@mediatek.com \
--cc=devicetree@vger.kernel.org \
--cc=john@phrozen.org \
--cc=linus.walleij@linaro.org \
--cc=linux-arm-kernel@lists.infradead.org \
--cc=linux-gpio@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-mediatek@lists.infradead.org \
--cc=linux@armlinux.org.uk \
--cc=mark.rutland@arm.com \
--cc=matthias.bgg@gmail.com \
--cc=robh+dt@kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).