diff mbox series

[2/3] ARM: dts: sun5i: Add port E pinmux settings for mmc2

Message ID 00d37ef9bf70785d05fb446ee6d0060c4a8d521a.1681580558.git.noodles@earth.li (mailing list archive)
State New, archived
Headers show
Series Minor device-tree additions for C.H.I.P | expand

Commit Message

Jonathan McDowell April 15, 2023, 5:46 p.m. UTC
These alternate pins for mmc2 are brought out to the 40 pin U14 header
on the C.H.I.P and can be used to add an external MMC device with a 4
bit interface. See

https://byteporter.com/ntc-chip-micro-sd-slot/

for further details on how.

Signed-off-by: Jonathan McDowell <noodles@earth.li>
---
 arch/arm/boot/dts/sun5i.dtsi | 8 ++++++++
 1 file changed, 8 insertions(+)

Comments

Andre Przywara April 16, 2023, 12:47 a.m. UTC | #1
On Sat, 15 Apr 2023 18:46:24 +0100
Jonathan McDowell <noodles@earth.li> wrote:

Hi,

> These alternate pins for mmc2 are brought out to the 40 pin U14 header
> on the C.H.I.P and can be used to add an external MMC device with a 4
> bit interface. See
> 
> https://byteporter.com/ntc-chip-micro-sd-slot/
> 
> for further details on how.
> 
> Signed-off-by: Jonathan McDowell <noodles@earth.li>
> ---
>  arch/arm/boot/dts/sun5i.dtsi | 8 ++++++++
>  1 file changed, 8 insertions(+)
> 
> diff --git a/arch/arm/boot/dts/sun5i.dtsi b/arch/arm/boot/dts/sun5i.dtsi
> index 250d6b87ab4d..e4922506ce22 100644
> --- a/arch/arm/boot/dts/sun5i.dtsi
> +++ b/arch/arm/boot/dts/sun5i.dtsi
> @@ -517,6 +517,14 @@ mmc2_4bit_pc_pins: mmc2-4bit-pc-pins {
>  				bias-pull-up;
>  			};
> 

As this seems to be a highly non-standard and rare modification, that
doesn't even get used in the mainline DT, please add a:
			/omit-if-no-ref/
line, so we don't get this into every sun5i board.

Otherwise looks good, though I don't know if that should belong into
the same DT overlay that is probably used to also enable the MMC2 node.

Cheers,
Andre


> +			mmc2_4bit_pe_pins: mmc2-4bit-pe-pins {
> +				pins = "PE4", "PE5", "PE6", "PE7",
> +				       "PE8", "PE9";
> +				function = "mmc2";
> +				drive-strength = <30>;
> +				bias-pull-up;
> +			};
> +
>  			mmc2_8bit_pins: mmc2-8bit-pins {
>  				pins = "PC6", "PC7", "PC8", "PC9",
>  				       "PC10", "PC11", "PC12", "PC13",
Jonathan McDowell April 20, 2023, 7:13 p.m. UTC | #2
On Sun, Apr 16, 2023 at 01:47:56AM +0100, Andre Przywara wrote:
> On Sat, 15 Apr 2023 18:46:24 +0100
> Jonathan McDowell <noodles@earth.li> wrote:
> 
> Hi,
> 
> > These alternate pins for mmc2 are brought out to the 40 pin U14 header
> > on the C.H.I.P and can be used to add an external MMC device with a 4
> > bit interface. See
> > 
> > https://byteporter.com/ntc-chip-micro-sd-slot/
> > 
> > for further details on how.
> > 
> > Signed-off-by: Jonathan McDowell <noodles@earth.li>
> > ---
> >  arch/arm/boot/dts/sun5i.dtsi | 8 ++++++++
> >  1 file changed, 8 insertions(+)
> > 
> > diff --git a/arch/arm/boot/dts/sun5i.dtsi b/arch/arm/boot/dts/sun5i.dtsi
> > index 250d6b87ab4d..e4922506ce22 100644
> > --- a/arch/arm/boot/dts/sun5i.dtsi
> > +++ b/arch/arm/boot/dts/sun5i.dtsi
> > @@ -517,6 +517,14 @@ mmc2_4bit_pc_pins: mmc2-4bit-pc-pins {
> >  				bias-pull-up;
> >  			};
> > 
> 
> As this seems to be a highly non-standard and rare modification, that
> doesn't even get used in the mainline DT, please add a:
> 			/omit-if-no-ref/
> line, so we don't get this into every sun5i board.

Neat, will add in v2.

> Otherwise looks good, though I don't know if that should belong into
> the same DT overlay that is probably used to also enable the MMC2 node.

I pondered that, but we already have the mmc2-4bit-pc-pins definition
here so it seemed helpful to add the pe-pins too.

> > +			mmc2_4bit_pe_pins: mmc2-4bit-pe-pins {
> > +				pins = "PE4", "PE5", "PE6", "PE7",
> > +				       "PE8", "PE9";
> > +				function = "mmc2";
> > +				drive-strength = <30>;
> > +				bias-pull-up;
> > +			};
> > +
> >  			mmc2_8bit_pins: mmc2-8bit-pins {
> >  				pins = "PC6", "PC7", "PC8", "PC9",
> >  				       "PC10", "PC11", "PC12", "PC13",
> 

J.
diff mbox series

Patch

diff --git a/arch/arm/boot/dts/sun5i.dtsi b/arch/arm/boot/dts/sun5i.dtsi
index 250d6b87ab4d..e4922506ce22 100644
--- a/arch/arm/boot/dts/sun5i.dtsi
+++ b/arch/arm/boot/dts/sun5i.dtsi
@@ -517,6 +517,14 @@  mmc2_4bit_pc_pins: mmc2-4bit-pc-pins {
 				bias-pull-up;
 			};
 
+			mmc2_4bit_pe_pins: mmc2-4bit-pe-pins {
+				pins = "PE4", "PE5", "PE6", "PE7",
+				       "PE8", "PE9";
+				function = "mmc2";
+				drive-strength = <30>;
+				bias-pull-up;
+			};
+
 			mmc2_8bit_pins: mmc2-8bit-pins {
 				pins = "PC6", "PC7", "PC8", "PC9",
 				       "PC10", "PC11", "PC12", "PC13",