Skip to content

sunxi: Fix MMC driver crashes

Andre Przywara u-boot 1 version New

Get series with b4
b4 am [email protected]

Versions newest first

  1. v1 Latest2 patches 0 repliesNew

Patches in v1 No applies recorded yet

#Subject and filesSizeRepliesApplied
1/2arm: timer: factor out FSL arch timer erratum workaroundarch/arm/cpu/armv8/generic_timer.c+25 -67 replies
1/2arm: timer: factor out FSL arch timer erratum workaround+0 -02 replies
1/2arm: timer: factor out FSL arch timer erratum workaround+0 -01 reply
1/2arm: timer: factor out FSL arch timer erratum workaround+0 -00 replies
1/2arm: timer: factor out FSL arch timer erratum workaround+0 -00 replies
1/2arm: timer: factor out FSL arch timer erratum workaround+0 -00 replies
2/2arm: timer: sunxi: add Allwinner timer erratum workaroundarch/arm/cpu/armv8/generic_timer.c arch/arm/mach-sunxi/Kconfig+28 -02 replies

Reviews trailers per patch

1 of 7 patches has a Reviewed-by or Acked-by.

PatchPhilipp TomsichJagan Teki
1/2T-b
1/2T-b
1/2T-b
1/2T-b
1/2T-b
1/2T-b
2/2R-b T-b

Trailers given in replies are filled; those carried in the patches from earlier versions are outlined with dashes.

Read the v1 thread

Cover letter [U-Boot] [PATCH 0/2] sunxi: Fix MMC driver crashes

There were recent reports about MMC operations failing very often on boards with the Allwinner A64 SoC. Investigations pointed to a time issue, and indeed a recent patch [1] introduced frequent arch timer reads to the Allwinner MMC driver. Reverting this patch made the problems go away, but also hurt performance much.
Unrelated reports also confirmed an Allwinner A64 arch timer erratum[2], which can lead to erroneous counter reads, where the lower 11 bits become either all 0's or all 1's. This leads to random jumps forwards and backwards, with catastrophic consequences.
These two patches fix the issue, while retaining the much improved MMC performance.
The first patch refactors an already existing arch timer fix, to allow the second patch, introducing an Allwinner specific workaround, to fit it more nicely.

Please have a look and apply as soon as possible.

Cheers,
Andre.

[1] commit 5ff8e54888e4d26a352453564f7f599d29696dc9

Author: Philipp Tomsich <[email protected]>
Date:   Wed Mar 21 12:18:58 2018 +0100

sunxi: improve throughput in the sunxi_mmc driver

[2] http://lists.infradead.org/pipermail/linux-arm-kernel/2018-May/576886.html

Andre Przywara (2):
arm: timer: factor out FSL arch timer erratum workaround
arm: timer: sunxi: add Allwinner timer erratum workaround

 arch/arm/cpu/armv8/generic_timer.c | 55 +++++++++++++++++++++++++++++++++-----
 arch/arm/mach-sunxi/Kconfig        |  4 +++
 2 files changed, 53 insertions(+), 6 deletions(-)
Signature · 1 line
2.14.4