lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <216262b8-fe48-6696-17a4-eaa82e776db7@linaro.org>
Date:   Fri, 17 Mar 2023 13:28:02 +0100
From:   Krzysztof Kozlowski <krzysztof.kozlowski@...aro.org>
To:     Henrik Grimler <henrik@...mler.se>, robh+dt@...nel.org,
        krzysztof.kozlowski+dt@...aro.org, alim.akhtar@...sung.com,
        m.szyprowski@...sung.com, jenneron@...tonmail.com,
        markuss.broks@...il.com, martin.juecker@...il.com,
        virag.david003@...il.com, devicetree@...r.kernel.org,
        linux-arm-kernel@...ts.infradead.org,
        linux-samsung-soc@...r.kernel.org, linux-kernel@...r.kernel.org,
        phone-devel@...r.kernel.org, ~postmarketos/upstreaming@...ts.sr.ht
Cc:     Valentine Iourine <iourine@...rine.msk.su>
Subject: Re: [PATCH v5 2/2] ARM: dts: exynos: add mmc aliases

On 16/03/2023 22:15, Henrik Grimler wrote:
> Add aliases for eMMC, SD card and WiFi where applicable, so that
> assigned mmc indeces are always the same.
> 
> Co-developed-by: Anton Bambura <jenneron@...tonmail.com>
> Signed-off-by: Anton Bambura <jenneron@...tonmail.com>
> [ Tested on exynos5800-peach-pi ]
> Tested-by: Valentine Iourine <iourine@...rine.msk.su>
> Signed-off-by: Henrik Grimler <henrik@...mler.se>
> Tested-by: Marek Szyprowski <m.szyprowski@...sung.com>
> 



>  	chosen {
> diff --git a/arch/arm/boot/dts/exynos4210-i9100.dts b/arch/arm/boot/dts/exynos4210-i9100.dts
> index bba85011ecc9..7051e2c4b391 100644
> --- a/arch/arm/boot/dts/exynos4210-i9100.dts
> +++ b/arch/arm/boot/dts/exynos4210-i9100.dts
> @@ -25,6 +25,12 @@ memory@...00000 {
>  		reg = <0x40000000 0x40000000>;
>  	};
>  
> +	aliases {
> +		mmc0 = &sdhci_0;
> +		mmc2 = &sdhci_2;
> +		mmc3 = &sdhci_3;

Here...

> +	};
> +
>  	chosen {
>  		stdout-path = "serial2:115200n8";
>  	};
> diff --git a/arch/arm/boot/dts/exynos4210-origen.dts b/arch/arm/boot/dts/exynos4210-origen.dts
> index 1103e7f92b57..1970c31410e5 100644
> --- a/arch/arm/boot/dts/exynos4210-origen.dts
> +++ b/arch/arm/boot/dts/exynos4210-origen.dts
> @@ -30,6 +30,11 @@ memory@...00000 {
>  		       0x70000000 0x10000000>;
>  	};
>  
> +	aliases {
> +		mmc0 = &sdhci_0;

here ....

> +		mmc2 = &sdhci_2;
> +	};
> +
>  	chosen {
>  		bootargs = "root=/dev/ram0 rw ramdisk=8192 initrd=0x41000000,8M init=/linuxrc";
>  		stdout-path = "serial2:115200n8";
> diff --git a/arch/arm/boot/dts/exynos4210-smdkv310.dts b/arch/arm/boot/dts/exynos4210-smdkv310.dts
> index 181c99eca675..cb74af41e17c 100644
> --- a/arch/arm/boot/dts/exynos4210-smdkv310.dts
> +++ b/arch/arm/boot/dts/exynos4210-smdkv310.dts
> @@ -25,6 +25,10 @@ memory@...00000 {
>  		reg = <0x40000000 0x80000000>;
>  	};
>  
> +	aliases {
> +		mmc2 = &sdhci_2;
> +	};
> +
>  	chosen {
>  		bootargs = "root=/dev/ram0 rw ramdisk=8192 initrd=0x41000000,8M init=/linuxrc";
>  		stdout-path = "serial1:115200n8";
> diff --git a/arch/arm/boot/dts/exynos4210-trats.dts b/arch/arm/boot/dts/exynos4210-trats.dts
> index b8e9dd23fc51..b6b0c116016c 100644
> --- a/arch/arm/boot/dts/exynos4210-trats.dts
> +++ b/arch/arm/boot/dts/exynos4210-trats.dts
> @@ -26,6 +26,12 @@ memory@...00000 {
>  			0x70000000 0x10000000>;
>  	};
>  
> +	aliases {
> +		mmc0 = &sdhci_0;
> +		mmc2 = &sdhci_2;
> +		mmc3 = &sdhci_3;
> +	};
> +
>  	chosen {
>  		bootargs = "root=/dev/mmcblk0p5 rootwait earlyprintk panic=5";
>  		stdout-path = "serial2:115200n8";
> diff --git a/arch/arm/boot/dts/exynos4210-universal_c210.dts b/arch/arm/boot/dts/exynos4210-universal_c210.dts
> index 140abfb38e1d..f42cfcbcdcfa 100644
> --- a/arch/arm/boot/dts/exynos4210-universal_c210.dts
> +++ b/arch/arm/boot/dts/exynos4210-universal_c210.dts
> @@ -24,6 +24,12 @@ memory@...00000 {
>  			0x50000000 0x10000000>;
>  	};
>  
> +	aliases {
> +		mmc0 = &sdhci_0;
> +		mmc2 = &sdhci_2;


Why this is 2? Aliases are continues and match the board. For example
Universal calls this mmc1 and the next mmc2, not 3.

I bet it is the same on Trats and all other boards.

> +		mmc3 = &sdhci_3;
> +	};
> +
>  	chosen {
>  		bootargs = "root=/dev/mmcblk0p5 rw rootwait earlyprintk panic=5 maxcpus=1";
>  		stdout-path = "serial2:115200n8";
> diff --git a/arch/arm/boot/dts/exynos4412-itop-elite.dts b/arch/arm/boot/dts/exynos4412-itop-elite.dts
> index 6260da187e92..0e5419c0eaff 100644
> --- a/arch/arm/boot/dts/exynos4412-itop-elite.dts
> +++ b/arch/arm/boot/dts/exynos4412-itop-elite.dts
> @@ -20,6 +20,10 @@ / {
>  	model = "TOPEET iTop 4412 Elite board based on Exynos4412";
>  	compatible = "topeet,itop4412-elite", "samsung,exynos4412", "samsung,exynos4";
>  
> +	aliases {
> +		mmc2 = &sdhci_2;

mmc1

> +	};
> +
>  	chosen {
>  		bootargs = "root=/dev/mmcblk0p2 rw rootfstype=ext4 rootdelay=1 rootwait";
>  		stdout-path = "serial2:115200n8";
> diff --git a/arch/arm/boot/dts/exynos4412-itop-scp-core.dtsi b/arch/arm/boot/dts/exynos4412-itop-scp-core.dtsi
> index ca8d42b2ce3b..7bc6968af9c3 100644
> --- a/arch/arm/boot/dts/exynos4412-itop-scp-core.dtsi
> +++ b/arch/arm/boot/dts/exynos4412-itop-scp-core.dtsi
> @@ -23,6 +23,10 @@ memory@...00000 {
>  		reg = <0x40000000 0x40000000>;
>  	};
>  
> +	aliases {
> +		mmc0 = &mshc_0;
> +	};
> +
>  	firmware@...f000 {
>  		compatible = "samsung,secure-firmware";
>  		reg = <0x0203f000 0x1000>;
> diff --git a/arch/arm/boot/dts/exynos4412-midas.dtsi b/arch/arm/boot/dts/exynos4412-midas.dtsi
> index 82aed59cba7c..e6b949c1a00f 100644
> --- a/arch/arm/boot/dts/exynos4412-midas.dtsi
> +++ b/arch/arm/boot/dts/exynos4412-midas.dtsi
> @@ -25,6 +25,9 @@ / {
>  	aliases {
>  		i2c11 = &i2c_max77693;
>  		i2c12 = &i2c_max77693_fuel;
> +		mmc0 = &mshc_0;
> +		mmc2 = &sdhci_2;
> +		mmc3 = &sdhci_3;

This is actually correct.

>  	};
>  
>  	chosen {
> diff --git a/arch/arm/boot/dts/exynos4412-odroid-common.dtsi b/arch/arm/boot/dts/exynos4412-odroid-common.dtsi
> index 25e082fda955..45ef7b7ba7e0 100644
> --- a/arch/arm/boot/dts/exynos4412-odroid-common.dtsi
> +++ b/arch/arm/boot/dts/exynos4412-odroid-common.dtsi
> @@ -13,6 +13,11 @@
>  #include "exynos-mfc-reserved-memory.dtsi"
>  
>  / {
> +	aliases {
> +		mmc0 = &mshc_0;
> +		mmc2 = &sdhci_2;

This is also correct.

> +	};

For all other cases, where schematics are missing, just make them linear.

Krzysztof

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ