
Hi Heiner,
On 04/13/2017 03:24 AM, Heiner Kallweit wrote:
This patch set implements eMMC on Amlogic Meson GX (S905). It's based on Carlo Caione's work submitted here: http://lists.denx.de/pipermail/u-boot/2016-May/254391.html
Changes to the original version:
- BLK support added
- fully DT-based now
- minor general refactoring
The driver was successfully tested on a Odroid C2.
Note: On Odroid C2 eMMC is MMC device 1. So you have to switch from MMC device 0 to 1 first when testing from uboot prompt.
I'm not sure but i think that you can use the fixed index for eMMC. Maybe you can refer to below commit.
commit 02ad33aa3a84821c8d9a6c4f167f143f6248b084 Refs: v2017.03-rc1-170-g02ad33a Author: Jaehoon Chung jh80.chung@samsung.com AuthorDate: Thu Feb 2 13:41:14 2017 +0900 Commit: Jaehoon Chung jh80.chung@samsung.com CommitDate: Thu Feb 9 20:37:05 2017 +0900
mmc: mmc-uclass: use the fixed devnum with alias node
If there are alias nodes as "mmc", use the devnum as alias index number. This patch is for fixing a problem of Exynos4 series. Problem is the below thing.
Current legacy mode: EXYNOS DWMMC: 0, SAMSUNG SDHCI: 1
After using DM: SAMSUNG SDHCI: 0, EXYNOS DWMMC: 1
Dev index is swapped. Then u-boot can't find the kernel image..because it is already set to 0 as mmcdev. If change from legacy to DM, also needs to touch all exynos4 config file. For using simply, just supporting the fixed devnum with alias node is better than it.
Usage: alaise { .... mmc0 = &sdhci2; /* eMMC */ mmc1 = &sdhci1; /* SD */ ... }
Anyway, I'm testing your patches with buildman..after that, i will apply.. But this patchset was delegated to Minkyu, so i will change it. if you are ok.
Best Regards, Jaehoon Chung
Latest change in v7:
- rebase due to other recent mmc changes
Heiner Kallweit (3): arm: dts: update Meson GXBB / Odroid-C2 DT with recent Linux version mmc: meson: add MMC driver for Meson GX (S905) odroid-c2: enable new Meson GX MMC driver in board defconfig
arch/arm/dts/meson-gx.dtsi | 447 +++++++++++++++++++ arch/arm/dts/meson-gxbb-odroidc2.dts | 147 +++++- arch/arm/dts/meson-gxbb.dtsi | 718 ++++++++++++++++++------------ arch/arm/include/asm/arch-meson/sd_emmc.h | 89 ++++ configs/odroid-c2_defconfig | 5 +- drivers/mmc/Kconfig | 6 + drivers/mmc/Makefile | 1 + drivers/mmc/meson_gx_mmc.c | 291 ++++++++++++ include/dt-bindings/clock/gxbb-aoclkc.h | 66 +++ include/dt-bindings/clock/gxbb-clkc.h | 34 ++ include/dt-bindings/reset/gxbb-aoclkc.h | 66 +++ 11 files changed, 1594 insertions(+), 276 deletions(-) create mode 100644 arch/arm/dts/meson-gx.dtsi create mode 100644 arch/arm/include/asm/arch-meson/sd_emmc.h create mode 100644 drivers/mmc/meson_gx_mmc.c create mode 100644 include/dt-bindings/clock/gxbb-aoclkc.h create mode 100644 include/dt-bindings/clock/gxbb-clkc.h create mode 100644 include/dt-bindings/reset/gxbb-aoclkc.h