Commit d385f8f2 authored by Jorge Ramirez-Ortiz's avatar Jorge Ramirez-Ortiz Committed by Pierre Couillaud
Browse files

UPSTREAM: mmc: core: Do not force a retune before RPMB switch



Requesting a retune before switching to the RPMB partition has been
observed to cause CRC errors on the RPMB reads (-EILSEQ).

Since RPMB reads can not be retried, the clients would be directly
affected by the errors.

This commit disables the retune request prior to switching to the RPMB
partition: mmc_retune_pause() no longer triggers a retune before the
pause period begins.

This was verified with the sdhci-of-arasan driver (ZynqMP) configured
for HS200 using two separate eMMC cards (DG4064 and 064GB2). In both
cases, the error was easy to reproduce triggering every few tenths of
reads.

With this commit, systems that were utilizing OP-TEE to access RPMB
variables will experience an enhanced performance. Specifically, when
OP-TEE is configured to employ RPMB as a secure storage solution, it not
only writes the data but also the secure filesystem within the
partition. As a result, retrieving any variable involves multiple RPMB
reads, typically around five.

For context, on ZynqMP, each retune request consumed approximately
8ms. Consequently, reading any RPMB variable used to take at the very
minimum 40ms.

After droping the need to retune before switching to the RPMB partition,
this is no longer the case.

Change-Id: I2320a38436b05b435ac528c6656b621a1e2eaeb7
Signed-off-by: default avatarJorge Ramirez-Ortiz <jorge@foundries.io>
Acked-by: default avatarAvri Altman <avri.altman@wdc.com>
Acked-by: default avatarAdrian Hunter <adrian.hunter@intel.com>
Link: https://lore.kernel.org/r/20240103112911.2954632-1-jorge@foundries.io


Signed-off-by: default avatarUlf Hansson <ulf.hansson@linaro.org>
(cherry picked from commit 67380251)
Signed-off-by: default avatarDanesh Petigara <danesh.petigara@broadcom.com>
parent 5c4b00b7
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please to comment