sunxi-mmc: don't double clock for new mode unconditionally
authorVasily Khoruzhick <anarsoul@gmail.com>
Sat, 10 Nov 2018 04:41:45 +0000 (20:41 -0800)
committerJagan Teki <jagan@amarulasolutions.com>
Thu, 22 Nov 2018 07:49:42 +0000 (13:19 +0530)
commit629d267a9738f0214853493968f114962de54642
tree1a523baf2edcc7ebfcff3b3e0200c5d141e7f308
parent2a8882ecefdeb9eb7ea2ea21427460e773a00e5a
sunxi-mmc: don't double clock for new mode unconditionally

Comment in Linux driver says that clock needs to be doubled only
if we use DDR modes, moreover divider has to be set accordingly.

U-boot driver doesn't declare support for any DDR modes and doesn't
set internal clock divider in CLKCR, so it doubles clock
unconditionally when new mode is used.

Some cards can't handle that and as result SPL fails to load u-boot.

Fixes: de9b1771c3b ("mmc: sunxi: Support new mode")
Signed-off-by: Vasily Khoruzhick <anarsoul@gmail.com>
Reviewed-by: Jagan Teki <jagan@openedev.com>
Tested-by: Jagan Teki <jagan@amarulasolutions.com> # Amarula A64-Relic
drivers/mmc/sunxi_mmc.c