public inbox for linux-mmc@vger.kernel.org
 help / color / mirror / Atom feed
From: Hans de Goede <hdegoede@redhat.com>
To: Chen-Yu Tsai <wens@csie.org>
Cc: Maxime Ripard <maxime.ripard@free-electrons.com>,
	linux-mmc@vger.kernel.org
Subject: sunxi mmc on A10 / A13 does not have a sample clock, cannot do ddr ?
Date: Sun, 3 Jul 2016 17:20:43 +0200	[thread overview]
Message-ID: <de974dc5-2192-a87f-d727-a8e9e9f4b079@redhat.com> (raw)

Hi Chen-Yu,

While working on some dts cleanups I tested
the latest sunxi-next kernel code on my A13
Utoo P66 tablet and the emmc no longer works.

The kernel tries to enable DDR52 mode on it,
since it apparently can do that and after that
the kernel can no longer talk to it.

Removing MMC_CAP_1_8V_DDR from sunxi-mmc.c
fixes this.

Part of the problem likely is that it seems
that the mmc clock on sun4i / sun5i do
not have sample / output phase clks.

It does not matter what one writes to
0x1c20088 / 0x1c20090, bits 8-10 and
20-22 are always 0.

I've observed this on both sun4i and sun5i,
and the sun4i / sun5i datasheets
also do not mention the phase bits
for register 0x1c20088 / 0x1c20090.

As such I'm thinking that the best way to fix
this is:

1) In sunxi-mmc.c make the sample clocks
optional; and if not present then do not
set MMC_CAP_1_8V_DDR (and do not try to
set sample clks)

2) Remove the sample clks from the base
sun4i / sun5i dtsi files

Regards,

Hans

             reply	other threads:[~2016-07-03 15:20 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-07-03 15:20 Hans de Goede [this message]
2016-07-05  8:29 ` sunxi mmc on A10 / A13 does not have a sample clock, cannot do ddr ? Maxime Ripard
2016-07-06  2:20   ` Chen-Yu Tsai

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=de974dc5-2192-a87f-d727-a8e9e9f4b079@redhat.com \
    --to=hdegoede@redhat.com \
    --cc=linux-mmc@vger.kernel.org \
    --cc=maxime.ripard@free-electrons.com \
    --cc=wens@csie.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox