Skip to content

mmc: sunxi: Enable DM_MMC

Andre Przywara u-boot 8 versions – New

Get series with b4
b4 am [email protected]

Versions newest first · linked by author and title

  1. v4 Latest posting 4/40 of 9 patches 0 repliesNew
  2. v4 posting 3/40 of 9 patches 0 repliesSuperseded
  3. v4 posting 2/40 of 9 patches 0 repliesSuperseded
Earlier versions · 5
VersionPostedPatchesRepliesStatus
v4 posting 1/49 patches0 repliesSuperseded
v2 posting 4/40 of 7 patches0 repliesSuperseded
v2 posting 3/40 of 7 patches0 repliesSuperseded
v2 posting 2/40 of 7 patches0 repliesSuperseded
v2 posting 1/40 of 7 patches0 repliesSuperseded

Patches in v4 posting 4/4 No applies recorded yet

None of the 9 patches the cover letter announces are in this archive.

Reviews trailers per patch

No Reviewed-by, Acked-by or Tested-by trailers for v4 yet.

Read the v4 thread

Cover letter [U-Boot] [PATCH v4 0/9] mmc: sunxi: Enable DM_MMC
Quoted 44 lines · On Wed, 30 Jan 2019 18:20:31 +0530 Jagan Teki <[email protected]>…
Quoted 42 lines · Andre Przywara

On Wed, 30 Jan 2019 11:16:07 +0100
Tomas Novotny <[email protected]> wrote:

Hi,

Quoted 16 lines
Quoted 11 lines · Andre Przywara

This series gathers all remaining patches we need to enable DM_MMC for Allwinner boards. It relies on the clock gates framework already merged, and adds the respective gates and resets for each SoC. It then teaches the sunxi MMC driver to use the clock framework for those reset and gates clocks. The "mod clock", responsible for setting the actual interface speed, is still handled in the MMC driver, as the DM_CLK part of that is not ready yet (and is not trivial). This allows to turn on DM_MMC, and gets rid of the doomsday warning message every Allwinner board was blessed with for a while.

Quoted 2 lines

This series is available at:
https://github.com/apritzel/u-boot/commits/sunxi-dm-gates

Quoted 7 lines

I've briefly tested that branch on A83t mainlined tablet (TBS A711). I was able to boot from SD card and eMMC.

Just noticed that message:
MMC: Device 'mmc at 1c11000': seq 1 is in use by 'mmc at 1c10000'
mmc at 1c0f000: 0, mmc at 1c10000: 2, mmc at 1c11000: 1 I guess that this is the mmc1/2 renaming stuff?

I think so. So is this just a warning, and it continues anyway and works?

TBH, I don't like this patch 9/9 very much, I actually believe relying on this numbering scheme in /aliases is something odd and fragile. Especially since Linux (and other OSes) seem to get away without it.

For MMC, can't we just enumerate them dynamically? AFAIU the MMC driver would not probe a block device successfully on an SDIO device, would it?

Quoted 7 lines
Quoted 2 lines

But for the sake of having something working, I am fine with the patch, at least on a for-now basis.

It's not a simple think that 9/9 fix is for,It's something big like w/o that we can't get the default env and fastboot devices because we always assign mmc1 for these purposes and indeed mmc1 is SDIO for DT enumeration.

Yeah, but why is it enumerating mmc1 in the first place? It doesn't seem to be usable? The MMC layer should know that there is no block device behind this SDIO thing, so it shouldn't even bother with creating a device for it. Certainly Linux works this way.

I understand that it fixes the issue, but it's some sort of hack, especially as it's applied to all DTs.

Cheers,
Andre.