[U-Boot] [PATCH 00/25] sunxi: Enable DM_MMC for U-Boot proper
Chen-Yu Tsai
wens at csie.org
Mon Jul 16 08:35:09 UTC 2018
On Mon, Jul 16, 2018 at 4:19 PM, Jagan Teki <jagan at amarulasolutions.com> wrote:
> Enabling DM_MMC is not straight forward for Allwinner SoC's to
> make proper compatibility in mmc driver vs DT nodes.
>
> Existing dm code for ahb gate clock will be suitable to handle
> sun4i,5i,6i and 7i U-Boot specific mmc dt nodes, which are different
> from Linux in terms of clocks phandle notation.
>
> U-Boot DT clocks phandle follow direct ahb and clock address on
> node definition with specific bit position, but Linux clocks phandle
> follow macros to define AHB and MMC clocks so-that the ccu driver
> will set the bits accordingly.
And that has been deprecated upstream.
> Clocks phandle notations in U-Boot for higher Allwinner SoC start
> from sun8i, sun50i are following Linux notation so-that both Linux
> and U-Boot can have common node definition.
So basically you're saying the additional code for clock/reset
handling through the device tree only works for half of the SoCs,
based on a deprecated device tree binding. Which means we're
going to throw it out some time in the future. Is it worth the
churn of driver and device tree changes?
IMHO the new clock handling code is no better than the old. The only
thing that has changed is how the clock register address is derived.
Not even the index numbers, which BTW are actual bit offsets, for
the AHB gates from the device tree are used. Neither is the device
tree used for the AHB resets.
If we remove that portion from the series, and also sync up all
device tree files to Linux 4.17 (or a later -rc or -next), instead
of manually adding device nodes based on the old device tree binding,
it probably would still work.
Regards
ChenYu
> This series will address the ahb gate, clock setup to handle all
> type of Allwinner SoCs. and sync mmc node definitions from Linux
> for sun4i and sun5i.
>
> Note:
> - sun6i, A23, A33, V3S were untested these need to have a closer look
> on dt nodes along with default ENV_FAT device.
>
> All these changes available at u-boot-sunxi/next
>
> Let me know if any questions or missings,
> Jagan.
>
> Jagan Teki (25):
> ARM: dts: sun4i: Sync A10 MMC nodes from Linux
> ARM: dts: sun4i: Sync A10 board dts mmc0 node from Linux
> ARM: dts: sun4i: Add mmc0 node for iNet 3F
> ARM: dts: sun4i: Add mmc0 node for iNet 3W
> dm: mmc: sunxi: Refactor ahb gate and clock setup
> dm: mmc: sunxi: Add ahb reset0 register write
> ARM: dts: sun7i: Sync A20 MMC nodes from Linux
> ARM: dts: sun7i: Add mmc0 node for Primo73 tablet
> ARM: dts: sun7i: Add mmc0 node for Ainol AW1
> ARM: dts: sun7i: Add mmc0 node for Mele M5
> ARM: dts: sun7i: Add mmc0 node for Toptech BD1078
> sunxi: A20: Enable DM_MMC
> mmc: sunxi: Add mmc, emmc H5/A64 compatible
> sunxi: H3_H5: Enable DM_MMC
> sunxi: A64: Enable DM_MMC
> ARM: dts: sun8i: Update A83T dts(i) files from Linux
> mmc: sunxi: Add A83T emmc compatible
> sunxi: A83T: Enable DM_MMC
> ARM: dts: sun8i: Update R40 dts(i) files from Linux
> sunxi: V40: Enable DM_MMC
> fastboot: sunxi: Update fastboot mmc default device
> env: sunxi: Update default env fat device
> sunxi: Use mmc_bootdev=2 for MMC2 boot
> [DO NOT MERGE] sunxi: A13/A31: Enable DM_MMC
> [DO NOT MERGE] sunxi: A23/A33/V3S: Enable DM_MMC
>
> arch/arm/dts/axp81x.dtsi | 169 ++++
> arch/arm/dts/sun4i-a10-a1000.dts | 5 +-
> arch/arm/dts/sun4i-a10-ba10-tvbox.dts | 5 +-
> arch/arm/dts/sun4i-a10-chuwi-v7-cw0825.dts | 5 +-
> arch/arm/dts/sun4i-a10-cubieboard.dts | 5 +-
> arch/arm/dts/sun4i-a10-dserve-dsrv9703c.dts | 5 +-
> arch/arm/dts/sun4i-a10-gemei-g9.dts | 5 +-
> arch/arm/dts/sun4i-a10-hackberry.dts | 5 +-
> arch/arm/dts/sun4i-a10-hyundai-a7hd.dts | 5 +-
> arch/arm/dts/sun4i-a10-inet-3f.dts | 9 +
> arch/arm/dts/sun4i-a10-inet-3w.dts | 9 +
> arch/arm/dts/sun4i-a10-inet1.dts | 5 +-
> arch/arm/dts/sun4i-a10-inet97fv2.dts | 5 +-
> arch/arm/dts/sun4i-a10-inet9f-rev03.dts | 5 +-
> .../dts/sun4i-a10-itead-iteaduino-plus.dts | 5 +-
> arch/arm/dts/sun4i-a10-jesurun-q5.dts | 5 +-
> arch/arm/dts/sun4i-a10-marsboard.dts | 5 +-
> arch/arm/dts/sun4i-a10-mini-xplus.dts | 5 +-
> arch/arm/dts/sun4i-a10-mk802.dts | 5 +-
> arch/arm/dts/sun4i-a10-mk802ii.dts | 5 +-
> arch/arm/dts/sun4i-a10-olinuxino-lime.dts | 5 +-
> arch/arm/dts/sun4i-a10-pcduino.dts | 5 +-
> arch/arm/dts/sun4i-a10-pov-protab2-ips9.dts | 5 +-
> arch/arm/dts/sun4i-a10.dtsi | 112 +--
> arch/arm/dts/sun7i-a20-ainol-aw1.dts | 13 +
> arch/arm/dts/sun7i-a20-m5.dts | 12 +
> arch/arm/dts/sun7i-a20-primo73.dts | 20 +-
> .../dts/sun7i-a20-yones-toptech-bd1078.dts | 13 +
> arch/arm/dts/sun7i-a20.dtsi | 102 +-
> .../dts/sun8i-a83t-allwinner-h8homlet-v2.dts | 195 +++-
> arch/arm/dts/sun8i-a83t-bananapi-m3.dts | 298 +++++-
> arch/arm/dts/sun8i-a83t-cubietruck-plus.dts | 322 ++++++-
> arch/arm/dts/sun8i-a83t-tbs-a711.dts | 355 ++++++-
> arch/arm/dts/sun8i-a83t.dtsi | 885 ++++++++++++++++--
> arch/arm/dts/sun8i-r40-bananapi-m2-ultra.dts | 197 +++-
> arch/arm/dts/sun8i-r40.dtsi | 616 +++++++++++-
> arch/arm/dts/sun8i-v40-bananapi-m2-berry.dts | 50 +
> arch/arm/mach-sunxi/Kconfig | 10 +
> board/sunxi/board.c | 2 +-
> configs/A20-OLinuXino-Lime2-eMMC_defconfig | 2 +
> configs/A20-OLinuXino_MICRO-eMMC_defconfig | 1 +
> configs/A20-OLinuXino_MICRO_defconfig | 1 +
> configs/A20-Olimex-SOM-EVB_defconfig | 1 +
> configs/A20-Olimex-SOM204-EVB-eMMC_defconfig | 1 +
> configs/Mele_M3_defconfig | 1 +
> configs/Orangepi_mini_defconfig | 1 +
> configs/Sinlinx_SinA33_defconfig | 2 +
> configs/Yones_Toptech_BD1078_defconfig | 1 +
> configs/amarula_a64_relic_defconfig | 2 +
> drivers/fastboot/Kconfig | 3 +-
> drivers/mmc/sunxi_mmc.c | 81 +-
> env/Kconfig | 3 +-
> include/configs/sunxi-common.h | 4 +-
> include/dt-bindings/clock/sun4i-a10-ccu.h | 202 ++++
> include/dt-bindings/clock/sun7i-a20-ccu.h | 53 ++
> include/dt-bindings/clock/sun8i-a83t-ccu.h | 140 +++
> include/dt-bindings/reset/sun8i-a83t-ccu.h | 98 ++
> 57 files changed, 3715 insertions(+), 371 deletions(-)
> create mode 100644 arch/arm/dts/axp81x.dtsi
> create mode 100644 include/dt-bindings/clock/sun4i-a10-ccu.h
> create mode 100644 include/dt-bindings/clock/sun7i-a20-ccu.h
> create mode 100644 include/dt-bindings/clock/sun8i-a83t-ccu.h
> create mode 100644 include/dt-bindings/reset/sun8i-a83t-ccu.h
>
> --
> 2.17.1
>
More information about the U-Boot
mailing list