linux-pwm.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: AngeloGioacchino Del Regno  <angelogioacchino.delregno@collabora.com>
To: matthias.bgg@gmail.com
Cc: p.zabel@pengutronix.de, airlied@gmail.com, daniel@ffwll.ch,
	robh+dt@kernel.org, krzysztof.kozlowski+dt@linaro.org,
	jassisinghbrar@gmail.com, chunfeng.yun@mediatek.com,
	vkoul@kernel.org, kishon@kernel.org, thierry.reding@gmail.com,
	u.kleine-koenig@pengutronix.de, chunkuang.hu@kernel.org,
	angelogioacchino.delregno@collabora.com, ck.hu@mediatek.com,
	jitao.shi@mediatek.com, xinlei.lee@mediatek.com,
	houlong.wei@mediatek.com, dri-devel@lists.freedesktop.org,
	linux-mediatek@lists.infradead.org, devicetree@vger.kernel.org,
	linux-kernel@vger.kernel.org,
	linux-arm-kernel@lists.infradead.org,
	linux-phy@lists.infradead.org, linux-pwm@vger.kernel.org,
	kernel@collabora.com, phone-devel@vger.kernel.org,
	~postmarketos/upstreaming@lists.sr.ht
Subject: [PATCH 25/27] arm64: dts: mediatek: mt6795-xperia-m5: Add eMMC, MicroSD slot, SDIO
Date: Wed, 12 Apr 2023 13:27:37 +0200	[thread overview]
Message-ID: <20230412112739.160376-26-angelogioacchino.delregno@collabora.com> (raw)
In-Reply-To: <20230412112739.160376-1-angelogioacchino.delregno@collabora.com>

Configure and enable the MMC0/1/2 controllers, used for the eMMC chip,
MicroSD card slot and SDIO (WiFi) respectively.

Signed-off-by: AngeloGioacchino Del Regno <angelogioacchino.delregno@collabora.com>
---
 .../dts/mediatek/mt6795-sony-xperia-m5.dts    | 91 +++++++++++++++++++
 1 file changed, 91 insertions(+)

diff --git a/arch/arm64/boot/dts/mediatek/mt6795-sony-xperia-m5.dts b/arch/arm64/boot/dts/mediatek/mt6795-sony-xperia-m5.dts
index debe0f2553d9..155a573eac4c 100644
--- a/arch/arm64/boot/dts/mediatek/mt6795-sony-xperia-m5.dts
+++ b/arch/arm64/boot/dts/mediatek/mt6795-sony-xperia-m5.dts
@@ -17,6 +17,7 @@ / {
 	aliases {
 		mmc0 = &mmc0;
 		mmc1 = &mmc1;
+		mmc2 = &mmc2;
 		serial0 = &uart0;
 		serial1 = &uart1;
 	};
@@ -121,7 +122,97 @@ proximity@48 {
 	};
 };
 
+&mmc0 {
+	/* eMMC controller */
+	mediatek,latch-ck = <0x14>; /* hs400 */
+	mediatek,hs200-cmd-int-delay = <1>;
+	mediatek,hs400-cmd-int-delay = <1>;
+	mediatek,hs400-ds-dly3 = <0x1a>;
+	non-removable;
+	pinctrl-names = "default", "state_uhs";
+	pinctrl-0 = <&mmc0_pins_default>;
+	pinctrl-1 = <&mmc0_pins_uhs>;
+	vmmc-supply = <&mt6331_vemc33_reg>;
+	vqmmc-supply = <&mt6331_vio18_reg>;
+	status = "okay";
+};
+
+&mmc1 {
+	/* MicroSD card slot */
+	vmmc-supply = <&mt6331_vmc_reg>;
+	vqmmc-supply = <&mt6331_vmch_reg>;
+	status = "okay";
+};
+
+&mmc2 {
+	/* SDIO WiFi on MMC2 */
+	vmmc-supply = <&mt6331_vmc_reg>;
+	vqmmc-supply = <&mt6331_vmch_reg>;
+	status = "okay";
+};
+
 &pio {
+	mmc0_pins_default: emmc-sdr-pins {
+		pins-cmd-dat {
+			pinmux = <PINMUX_GPIO154__FUNC_MSDC0_DAT0>,
+				 <PINMUX_GPIO155__FUNC_MSDC0_DAT1>,
+				 <PINMUX_GPIO156__FUNC_MSDC0_DAT2>,
+				 <PINMUX_GPIO157__FUNC_MSDC0_DAT3>,
+				 <PINMUX_GPIO158__FUNC_MSDC0_DAT4>,
+				 <PINMUX_GPIO159__FUNC_MSDC0_DAT5>,
+				 <PINMUX_GPIO160__FUNC_MSDC0_DAT6>,
+				 <PINMUX_GPIO161__FUNC_MSDC0_DAT7>,
+				 <PINMUX_GPIO162__FUNC_MSDC0_CMD>;
+			input-enable;
+			bias-pull-up = <MTK_PUPD_SET_R1R0_01>;
+		};
+
+		pins-clk {
+			pinmux = <PINMUX_GPIO163__FUNC_MSDC0_CLK>;
+			bias-pull-down = <MTK_PUPD_SET_R1R0_10>;
+		};
+
+		pins-rst {
+			pinmux = <PINMUX_GPIO165__FUNC_MSDC0_RSTB>;
+			bias-pull-up = <MTK_PUPD_SET_R1R0_10>;
+		};
+	};
+
+	mmc0_pins_uhs: emmc-uhs-pins {
+		pins-cmd-dat {
+			pinmux = <PINMUX_GPIO154__FUNC_MSDC0_DAT0>,
+				 <PINMUX_GPIO155__FUNC_MSDC0_DAT1>,
+				 <PINMUX_GPIO156__FUNC_MSDC0_DAT2>,
+				 <PINMUX_GPIO157__FUNC_MSDC0_DAT3>,
+				 <PINMUX_GPIO158__FUNC_MSDC0_DAT4>,
+				 <PINMUX_GPIO159__FUNC_MSDC0_DAT5>,
+				 <PINMUX_GPIO160__FUNC_MSDC0_DAT6>,
+				 <PINMUX_GPIO161__FUNC_MSDC0_DAT7>,
+				 <PINMUX_GPIO162__FUNC_MSDC0_CMD>;
+			input-enable;
+			drive-strength = <MTK_DRIVE_6mA>;
+			bias-pull-up = <MTK_PUPD_SET_R1R0_01>;
+		};
+
+		pins-clk {
+			pinmux = <PINMUX_GPIO163__FUNC_MSDC0_CLK>;
+			drive-strength = <MTK_DRIVE_6mA>;
+			bias-pull-down = <MTK_PUPD_SET_R1R0_10>;
+		};
+
+		pins-rst {
+			pinmux = <PINMUX_GPIO165__FUNC_MSDC0_RSTB>;
+			drive-strength = <MTK_DRIVE_6mA>;
+			bias-pull-up = <MTK_PUPD_SET_R1R0_10>;
+		};
+
+		pins-ds {
+			pinmux = <PINMUX_GPIO164__FUNC_MSDC0_DSL>;
+			drive-strength = <MTK_DRIVE_6mA>;
+			bias-pull-down = <MTK_PUPD_SET_R1R0_10>;
+		};
+	};
+
 	nfc_pins: nfc-pins {
 		pins-irq {
 			pinmux = <PINMUX_GPIO3__FUNC_GPIO3>;
-- 
2.40.0


  parent reply	other threads:[~2023-04-12 11:30 UTC|newest]

Thread overview: 99+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-04-12 11:27 [PATCH 00/27] MediaTek Helio X10 - Mailbox, Display, MMC/SD/SDIO AngeloGioacchino Del Regno
2023-04-12 11:27 ` [PATCH 01/27] dt-bindings: pwm: Add compatible for MediaTek MT6795 AngeloGioacchino Del Regno
2023-04-12 12:30   ` Matthias Brugger
2023-04-12 21:03   ` Rob Herring
2023-04-13  8:52     ` Matthias Brugger
2023-04-13  9:28       ` AngeloGioacchino Del Regno
2023-04-18  0:58       ` Rob Herring
2023-04-14  5:43   ` Uwe Kleine-König
2023-04-18 11:56     ` Matthias Brugger
2023-04-14  8:21   ` Krzysztof Kozlowski
2023-04-14  8:30     ` Uwe Kleine-König
2023-04-14  8:34       ` Krzysztof Kozlowski
2023-04-14 10:25         ` AngeloGioacchino Del Regno
2023-04-14 10:31           ` Krzysztof Kozlowski
2023-04-14 10:31   ` Krzysztof Kozlowski
2023-05-29 13:51   ` Matthias Brugger
2023-04-12 11:27 ` [PATCH 02/27] dt-bindings: phy: mediatek,dsi-phy: Add compatible for MT6795 Helio X10 AngeloGioacchino Del Regno
2023-04-12 12:34   ` Matthias Brugger
2023-04-12 12:59   ` Alexandre Mergnat
2023-04-12 13:03     ` AngeloGioacchino Del Regno
2023-04-12 13:12       ` Alexandre Mergnat
2023-04-12 13:17         ` AngeloGioacchino Del Regno
2023-04-13  8:58           ` Matthias Brugger
2023-04-14  8:22   ` Krzysztof Kozlowski
2023-05-29 14:05     ` Matthias Brugger
2023-04-12 11:27 ` [PATCH 03/27] dt-bindings: display: mediatek: dpi: Add compatible for MediaTek MT6795 AngeloGioacchino Del Regno
2023-04-12 12:35   ` Matthias Brugger
2023-04-14  8:23     ` Krzysztof Kozlowski
2023-04-12 13:13   ` Alexandre Mergnat
2023-04-12 21:03   ` Rob Herring
2023-04-14  8:23   ` Krzysztof Kozlowski
2023-05-29 14:07   ` Matthias Brugger
2023-06-13  0:12     ` Chun-Kuang Hu
2023-04-12 11:27 ` [PATCH 04/27] dt-bindings: display: mediatek: aal: " AngeloGioacchino Del Regno
2023-04-12 12:35   ` Matthias Brugger
2023-04-12 13:03   ` Alexandre Mergnat
2023-04-14  8:24   ` Krzysztof Kozlowski
2023-04-12 11:27 ` [PATCH 05/27] dt-bindings: display: mediatek: dsi: " AngeloGioacchino Del Regno
2023-04-12 12:36   ` Matthias Brugger
2023-04-12 13:21     ` AngeloGioacchino Del Regno
2023-04-12 21:03   ` Rob Herring
2023-04-14  8:24   ` Krzysztof Kozlowski
2023-04-12 11:27 ` [PATCH 06/27] dt-bindings: display: mediatek: ovl: " AngeloGioacchino Del Regno
2023-04-12 21:03   ` Rob Herring
2023-04-14  8:24   ` Krzysztof Kozlowski
2023-04-12 11:27 ` [PATCH 07/27] dt-bindings: display: mediatek: rdma: " AngeloGioacchino Del Regno
2023-04-12 21:03   ` Rob Herring
2023-04-14  8:26   ` Krzysztof Kozlowski
2023-04-12 11:27 ` [PATCH 08/27] dt-bindings: display: mediatek: wdma: " AngeloGioacchino Del Regno
2023-04-12 12:36   ` Matthias Brugger
2023-04-14  8:26   ` Krzysztof Kozlowski
2023-04-12 11:27 ` [PATCH 09/27] dt-bindings: display: mediatek: color: " AngeloGioacchino Del Regno
2023-04-12 12:37   ` Matthias Brugger
2023-04-12 21:03   ` Rob Herring
2023-04-14  8:26   ` Krzysztof Kozlowski
2023-04-12 11:27 ` [PATCH 10/27] dt-bindings: display: mediatek: gamma: " AngeloGioacchino Del Regno
2023-04-14  8:27   ` Krzysztof Kozlowski
2023-04-12 11:27 ` [PATCH 11/27] dt-bindings: display: mediatek: merge: " AngeloGioacchino Del Regno
2023-04-12 12:37   ` Matthias Brugger
2023-04-14  8:33   ` Krzysztof Kozlowski
2023-04-12 11:27 ` [PATCH 12/27] dt-bindings: display: mediatek: split: " AngeloGioacchino Del Regno
2023-04-12 12:37   ` Matthias Brugger
2023-04-14  8:34   ` Krzysztof Kozlowski
2023-04-12 11:27 ` [PATCH 13/27] dt-bindings: display: mediatek: ufoe: " AngeloGioacchino Del Regno
2023-04-12 12:38   ` Matthias Brugger
2023-04-12 21:03   ` Rob Herring
2023-04-14  8:44   ` Krzysztof Kozlowski
2023-04-12 11:27 ` [PATCH 14/27] dt-bindings: display: mediatek: od: " AngeloGioacchino Del Regno
2023-04-12 12:38   ` Matthias Brugger
2023-04-12 21:03   ` Rob Herring
2023-04-14  8:45   ` Krzysztof Kozlowski
2023-04-12 11:27 ` [PATCH 15/27] dt-bindings: mailbox: mediatek,gce-mailbox: Add support for MT6795 AngeloGioacchino Del Regno
2023-04-12 12:38   ` Matthias Brugger
2023-04-12 11:27 ` [PATCH 16/27] arm64: dts: mediatek: mt6795: Add support for the CMDQ/GCE mailbox AngeloGioacchino Del Regno
2023-05-29 13:54   ` Matthias Brugger
2023-04-12 11:27 ` [PATCH 17/27] arm64: dts: mediatek: mt6795: Add MMSYS node for multimedia clocks AngeloGioacchino Del Regno
2023-05-29 13:55   ` Matthias Brugger
2023-04-12 11:27 ` [PATCH 18/27] arm64: dts: mediatek: mt6795: Add support for IOMMU and LARBs AngeloGioacchino Del Regno
2023-05-29 13:56   ` Matthias Brugger
2023-04-12 11:27 ` [PATCH 19/27] arm64: dts: mediatek: mt6795: Add support for display blocks and DPI/DSI AngeloGioacchino Del Regno
2023-04-12 11:27 ` [PATCH 20/27] arm64: dts: mediatek: mt6795: Add tertiary PWM node AngeloGioacchino Del Regno
2023-04-12 12:43   ` Matthias Brugger
2023-04-12 11:27 ` [PATCH 21/27] arm64: dts: mediatek: mt6795: Add PMIC Wrapper node AngeloGioacchino Del Regno
2023-05-29 13:57   ` Matthias Brugger
2023-04-12 11:27 ` [PATCH 22/27] arm64: dts: mediatek: mt6795: Copyright header additions AngeloGioacchino Del Regno
2023-04-12 12:41   ` Matthias Brugger
2023-04-12 13:23     ` AngeloGioacchino Del Regno
2023-04-14  8:46   ` Krzysztof Kozlowski
2023-04-14 10:28     ` AngeloGioacchino Del Regno
2023-04-12 11:27 ` [PATCH 23/27] arm64: dts: mediatek: Add MT6331 PMIC devicetree AngeloGioacchino Del Regno
2023-05-29 13:59   ` Matthias Brugger
2023-04-12 11:27 ` [PATCH 24/27] arm64: dts: mediatek: mt6795-xperia-m5: Add MT6331 Combo PMIC AngeloGioacchino Del Regno
2023-05-29 14:00   ` Matthias Brugger
2023-04-12 11:27 ` AngeloGioacchino Del Regno [this message]
2023-05-29 14:01   ` [PATCH 25/27] arm64: dts: mediatek: mt6795-xperia-m5: Add eMMC, MicroSD slot, SDIO Matthias Brugger
2023-04-12 11:27 ` [PATCH 26/27] arm64: dts: mediatek: mt6795-xperia-m5: Add Bosch BMA255 Accelerometer AngeloGioacchino Del Regno
2023-04-12 12:44   ` Matthias Brugger
2023-04-12 11:27 ` [PATCH 27/27] arm64: dts: mediatek: mt6795-xperia-m5: Add Bosch BMM050 Magnetometer AngeloGioacchino Del Regno
2023-04-12 12:44   ` 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=20230412112739.160376-26-angelogioacchino.delregno@collabora.com \
    --to=angelogioacchino.delregno@collabora.com \
    --cc=airlied@gmail.com \
    --cc=chunfeng.yun@mediatek.com \
    --cc=chunkuang.hu@kernel.org \
    --cc=ck.hu@mediatek.com \
    --cc=daniel@ffwll.ch \
    --cc=devicetree@vger.kernel.org \
    --cc=dri-devel@lists.freedesktop.org \
    --cc=houlong.wei@mediatek.com \
    --cc=jassisinghbrar@gmail.com \
    --cc=jitao.shi@mediatek.com \
    --cc=kernel@collabora.com \
    --cc=kishon@kernel.org \
    --cc=krzysztof.kozlowski+dt@linaro.org \
    --cc=linux-arm-kernel@lists.infradead.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-mediatek@lists.infradead.org \
    --cc=linux-phy@lists.infradead.org \
    --cc=linux-pwm@vger.kernel.org \
    --cc=matthias.bgg@gmail.com \
    --cc=p.zabel@pengutronix.de \
    --cc=phone-devel@vger.kernel.org \
    --cc=robh+dt@kernel.org \
    --cc=thierry.reding@gmail.com \
    --cc=u.kleine-koenig@pengutronix.de \
    --cc=vkoul@kernel.org \
    --cc=xinlei.lee@mediatek.com \
    --cc=~postmarketos/upstreaming@lists.sr.ht \
    /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).