Skip to contentSkip to conversation

arm: dts: mt7623: fix mmc interrupt assignment

PATCH New Sean Wang 1 participant 2 messages Aug 2, 2017 2 messages not in the archive Arm MediaTek

lore
Share & tools
lore

A message that is not in the archive (sent off-list or not yet received): [email protected]

Sean Wang

author
#1 lore raw

PATCH 1/2 arm: dts: mt7623: fix mmc interrupt assignment

Quoted 13 lines · Matthias Brugger

The mmc1 interrupt should be connected to GIC_SPI 40, this patch fixes this.

---
 arch/arm/boot/dts/mt7623.dtsi | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
arch/arm/boot/dts/mt7623.dtsi +0 -0
index 4ae0ab07e053..2a877ed8ff23 100644

arch/arm/boot/dts/mt7623.dtsi line 654

Quoted 8 lines
arch/arm/boot/dts/mt7623.dtsi +1 -1
@@ -648,7 +648,7 @@
 		compatible = "mediatek,mt7623-mmc",
 			     "mediatek,mt8135-mmc";
 		reg = <0 0x11240000 0 0x1000>;
-		interrupts = <GIC_SPI 72 IRQ_TYPE_LEVEL_LOW>;
+		interrupts = <GIC_SPI 40 IRQ_TYPE_LEVEL_LOW>;
 		clocks = <&pericfg CLK_PERI_MSDC30_1>,
 			 <&topckgen CLK_TOP_MSDC30_1_SEL>;
 		clock-names = "source", "hclk";

Hi, Matthias

many thanks!

Sean

A message that is not in the archive (sent off-list or not yet received): [email protected]

author
#3 lore raw

PATCH 2/2 arm: dts: mt7623: Add SD-card to bananapi-r2

Quoted 22 lines · Matthias Brugger

The bananapi-r2 board has an SD-card controller, enable the device in the devicetree.

---
 arch/arm/boot/dts/mt7623n-bananapi-bpi-r2.dts | 13 +++++++++++++
 1 file changed, 13 insertions(+)
arch/arm/boot/dts/mt7623n-bananapi-bpi-r2.dts +6 -0
index 9f3e6ddd545f..d457544c3a1d 100644
@@ -179,6 +179,19 @@
 	status = "okay";
 };
 
+&mmc1 {
+	pinctrl-names = "default", "state_uhs";
+	pinctrl-0 = <&mmc1_pins_default>;
+	pinctrl-1 = <&mmc1_pins_uhs>;
+	status = "okay";
+	bus-width = <4>;

arch/arm/boot/dts/mt7623n-bananapi-bpi-r2.dts line 197

Quoted 10 lines
arch/arm/boot/dts/mt7623n-bananapi-bpi-r2.dts +7 -0
+	max-frequency = <50000000>;
+	cap-sd-highspeed;
+	cd-gpios = <&pio 261 0>;
+	vmmc-supply = <&mt6323_vmch_reg>;
+	vqmmc-supply = <&mt6323_vmc_reg>;
+};
+
 &pio {
 	cir_pins_a:cir at 0 {
 		pins_cir {

I can base the patch to fixup and add something in the next version

such as

1) to add property with extra wp-gpios

2) to correct power source from mt6323_vio18_reg instead of mt6323_vmc_reg based on the schematic

3) to enable mmc0 that is used as emmc

&mmc0 {
        pinctrl-names = "default", "state_uhs";
        pinctrl-0 = <&mmc0_pins_default>;
        pinctrl-1 = <&mmc0_pins_uhs>;
        status = "okay";
        bus-width = <8>;
        max-frequency = <50000000>;
        cap-mmc-highspeed;
        vmmc-supply = <&mt6323_vemc3v3_reg>;
        vqmmc-supply = <&mt6323_vio18_reg>;
        non-removable;
};
&mmc1 {
        pinctrl-names = "default", "state_uhs";
        pinctrl-0 = <&mmc1_pins_default>;
        pinctrl-1 = <&mmc1_pins_uhs>;
        status = "okay";
        bus-width = <4>;
        max-frequency = <50000000>;
        cap-sd-highspeed;
        cd-gpios = <&pio 261 0>;
        wp-gpios = <&pio 29 0>;
        vmmc-supply = <&mt6323_vmch_reg>;
        vqmmc-supply = <&mt6323_vio18_reg>;
};

those upper nodes could make sdhc sd card/emmc workable