[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <c1531549-29da-25dc-cada-f61edbc5f2fd@intel.com>
Date: Fri, 5 Feb 2021 08:33:04 +0200
From: Adrian Hunter <adrian.hunter@...el.com>
To: yann.gautier@...s.st.com, ulf.hansson@...aro.org
Cc: linux@...linux.org.uk, linus.walleij@...aro.org,
ludovic.barre@...s.st.com, per.forlin@...aro.org,
huyue2@...ong.com, wsa+renesas@...g-engineering.com,
vbadigan@...eaurora.org, p.zabel@...gutronix.de, marex@...x.de,
swboyd@...omium.org, linux-mmc@...r.kernel.org,
linux-kernel@...r.kernel.org
Subject: Re: [PATCH 2/2] mmc: mmc_test: use erase_arg for mmc_erase command
On 4/02/21 2:05 pm, yann.gautier@...s.st.com wrote:
> From: Yann Gautier <yann.gautier@...s.st.com>
>
> Since [1], the erase argument for mmc_erase() function is saved in
> erase_arg field of card structure. It is preferable to use it instead of
> hard-coded MMC_SECURE_ERASE_ARG, which from eMMC 4.51 spec is not
> recommended:
> "6.6.16 Secure Erase
> NOTE Secure Erase is included for backwards compatibility. New system
> level implementations (based on v4.51 devices and beyond) should use
> Erase combined with Sanitize instead of secure erase."
>
> [1] commit 01904ff77676 ("mmc: core: Calculate the discard arg only once")
>
Did you experience an issue because of this? You could add that to the
commit message.
There does not seem to be a need for secure erase, so:
Acked-by: Adrian Hunter <adrian.hunter@...el.com>
> Signed-off-by: Yann Gautier <yann.gautier@...s.st.com>
> ---
> drivers/mmc/core/mmc_test.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/drivers/mmc/core/mmc_test.c b/drivers/mmc/core/mmc_test.c
> index 39a478874ca3..63524551a13a 100644
> --- a/drivers/mmc/core/mmc_test.c
> +++ b/drivers/mmc/core/mmc_test.c
> @@ -2110,7 +2110,7 @@ static int mmc_test_rw_multiple(struct mmc_test_card *test,
> if (mmc_can_erase(test->card) &&
> tdata->prepare & MMC_TEST_PREP_ERASE) {
> ret = mmc_erase(test->card, dev_addr,
> - size / 512, MMC_SECURE_ERASE_ARG);
> + size / 512, test->card->erase_arg);
> if (ret)
> ret = mmc_erase(test->card, dev_addr,
> size / 512, MMC_ERASE_ARG);
>
Powered by blists - more mailing lists