From cfa39fe78b34481de668b84263433f47e252eb7e Mon Sep 17 00:00:00 2001 From: Stefan Roese Date: Fri, 12 Mar 2021 09:48:27 +0100 Subject: [PATCH] mips: octeon: mrvl,octeon_ebb7304.dts: Add MMC DT node Add the MMC DT node to the Octeon EBB7304 DT file including the regulator node for the MMC power supply. Signed-off-by: Stefan Roese Cc: Aaron Williams Cc: Chandrakala Chavva Cc: Daniel Schwierzeck --- arch/mips/dts/mrvl,octeon-ebb7304.dts | 57 +++++++++++++++++++++++++++ 1 file changed, 57 insertions(+) diff --git a/arch/mips/dts/mrvl,octeon-ebb7304.dts b/arch/mips/dts/mrvl,octeon-ebb7304.dts index 993b4f6890..1bb34e1329 100644 --- a/arch/mips/dts/mrvl,octeon-ebb7304.dts +++ b/arch/mips/dts/mrvl,octeon-ebb7304.dts @@ -6,16 +6,36 @@ /dts-v1/; #include "mrvl,cn73xx.dtsi" +#include / { model = "cavium,ebb7304"; compatible = "cavium,ebb7304"; aliases { + mmc0 = &mmc0; + mmc1 = &mmc1; serial0 = &uart0; spi0 = &spi; }; + regulators { + compatible = "simple-bus"; + #address-cells = <1>; + #size-cells = <0>; + + /* Power on GPIO 8, active high */ + reg_mmc_3v3: regulator@0 { + compatible = "regulator-fixed"; + reg = <0>; + regulator-name = "mmc-3v3"; + regulator-min-microvolt = <3300000>; + regulator-max-microvolt = <3300000>; + gpio = <&gpio 8 GPIO_ACTIVE_HIGH>; + enable-active-high; + }; + }; + chosen { stdout-path = &uart0; }; @@ -137,3 +157,40 @@ */ power = <&gpio 21 0>; }; + +&mmc { + status = "okay"; + + /* The board has two MMC slots + * If both are occupied, the speed must be reduced, + * as extra data-line load increases slew time, + * and dat-skew adjustment does not help significantly. + */ + mmc0: mmc-slot@0 { + compatible = "cavium,octeon-6130-mmc-slot", "mmc-slot"; + reg = <0>; + vqmmc-supply = <®_mmc_3v3>; + voltage-ranges = <3300 3300>; + //spi-max-frequency = <52000000>; // just one + spi-max-frequency = <37000000>; // both slots + /* bus width can be 1, 4 or 8 */ + bus-width = <8>; /* new std property */ + cavium,bus-max-width = <8>; /* custom property */ + wp-gpios = <&gpio 22 0>; /* active high */ + cd-gpios = <&gpio 23 1>; /* active low */ + }; + + mmc1: mmc-slot@1 { + compatible = "cavium,octeon-6130-mmc-slot", "mmc-slot"; + reg = <1>; + vqmmc-supply = <®_mmc_3v3>; + voltage-ranges = <3300 3300>; + //spi-max-frequency = <52000000>; // just one + spi-max-frequency = <37000000>; // both slots + /* bus width can be 1, 4 or 8 */ + bus-width = <8>; /* new std property */ + cavium,bus-max-width = <8>; /* custom property */ + wp-gpios = <&gpio 24 0>; /* active high */ + cd-gpios = <&gpio 25 1>; /* active low */ + }; +}; -- 2.39.5