mmc: sunxi: add support for automatic delay calibration
A64 and H6 support automatic delay calibration and Linux driver uses it instead of hardcoded delays. Add support for it to u-boot driver. Fixes eMMC instability on Pinebook Signed-off-by: Vasily Khoruzhick <anarsoul@gmail.com> Acked-by: Maxime Ripard <maxime.ripard@bootlin.com> Tested-by: Maxime Ripard <maxime.ripard@bootlin.com> Reviewed-by: Andre Przywara <andre.przywara@arm.com> Cc: Vagrant Cascadian <vagrant@debian.org> Reviewed-by: Jagan Teki <jagan@openedev.com>
This commit is contained in:
committed by
Jagan Teki
parent
4f9d34e633
commit
20940ef2a3
@@ -46,7 +46,9 @@ struct sunxi_mmc {
|
||||
u32 cbda; /* 0x94 */
|
||||
u32 res2[26];
|
||||
#if defined(CONFIG_SUNXI_GEN_SUN6I) || defined(CONFIG_MACH_SUN50I_H6)
|
||||
u32 res3[64];
|
||||
u32 res3[17];
|
||||
u32 samp_dl;
|
||||
u32 res4[46];
|
||||
#endif
|
||||
u32 fifo; /* 0x100 / 0x200 FIFO access address */
|
||||
};
|
||||
@@ -130,5 +132,7 @@ struct sunxi_mmc {
|
||||
#define SUNXI_MMC_COMMON_CLK_GATE (1 << 16)
|
||||
#define SUNXI_MMC_COMMON_RESET (1 << 18)
|
||||
|
||||
#define SUNXI_MMC_CAL_DL_SW_EN (0x1 << 7)
|
||||
|
||||
struct mmc *sunxi_mmc_init(int sdc_no);
|
||||
#endif /* _SUNXI_MMC_H */
|
||||
|
||||
Reference in New Issue
Block a user