mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Adrian Hunter <adrian.hunter@intel.com>
To: yann.gautier@foss.st.com, ulf.hansson@linaro.org
Cc: linux@armlinux.org.uk, linus.walleij@linaro.org,
	ludovic.barre@foss.st.com, per.forlin@linaro.org,
	huyue2@yulong.com, wsa+renesas@sang-engineering.com,
	vbadigan@codeaurora.org, p.zabel@pengutronix.de, marex@denx.de,
	swboyd@chromium.org, linux-mmc@vger.kernel.org,
	linux-kernel@vger.kernel.org
Subject: Re: [PATCH 2/2] mmc: mmc_test: use erase_arg for mmc_erase command
Date: Fri, 5 Feb 2021 08:33:04 +0200	[thread overview]
Message-ID: <c1531549-29da-25dc-cada-f61edbc5f2fd@intel.com> (raw)
In-Reply-To: <20210204120547.15381-3-yann.gautier@foss.st.com>

On 4/02/21 2:05 pm, yann.gautier@foss.st.com wrote:
> From: Yann Gautier <yann.gautier@foss.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@intel.com>


> Signed-off-by: Yann Gautier <yann.gautier@foss.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);
> 


  reply	other threads:[~2021-02-05  6:34 UTC|newest]

Thread overview: 15+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-02-04 12:05 [PATCH 0/2] mmc: mmci/mmc_test: update mmc_erase management yann.gautier
2021-02-04 12:05 ` [PATCH 1/2] mmc: mmci: enable MMC_CAP_NEED_RSP_BUSY yann.gautier
2021-02-04 12:26   ` Marek Vasut
2021-02-04 12:54     ` Yann GAUTIER
2021-02-04 13:07       ` Marek Vasut
2021-02-05  9:53   ` Ulf Hansson
2021-02-05 12:19     ` Yann GAUTIER
2021-02-08 12:16       ` Yann GAUTIER
2021-02-08 13:31         ` Yann GAUTIER
2021-02-08 15:03         ` Ulf Hansson
2021-02-09 14:01           ` Yann Gautier
2021-02-10 12:03             ` Ulf Hansson
2021-02-04 12:05 ` [PATCH 2/2] mmc: mmc_test: use erase_arg for mmc_erase command yann.gautier
2021-02-05  6:33   ` Adrian Hunter [this message]
2021-02-05  9:05     ` Yann GAUTIER

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=c1531549-29da-25dc-cada-f61edbc5f2fd@intel.com \
    --to=adrian.hunter@intel.com \
    --cc=huyue2@yulong.com \
    --cc=linus.walleij@linaro.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-mmc@vger.kernel.org \
    --cc=linux@armlinux.org.uk \
    --cc=ludovic.barre@foss.st.com \
    --cc=marex@denx.de \
    --cc=p.zabel@pengutronix.de \
    --cc=per.forlin@linaro.org \
    --cc=swboyd@chromium.org \
    --cc=ulf.hansson@linaro.org \
    --cc=vbadigan@codeaurora.org \
    --cc=wsa+renesas@sang-engineering.com \
    --cc=yann.gautier@foss.st.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®