From: "Sverdlin, Alexander" <alexander.sverdlin@siemens.com>
To: "Haener, Michael" <michael.haener@siemens.com>,
"ulfh@kernel.org" <ulfh@kernel.org>
Cc: "ziniu.wang_1@nxp.com" <ziniu.wang_1@nxp.com>,
"stable@vger.kernel.org" <stable@vger.kernel.org>,
"avri.altman@sandisk.com" <avri.altman@sandisk.com>,
"linux-mmc@vger.kernel.org" <linux-mmc@vger.kernel.org>,
"linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>
Subject: Re: [PATCH 1/2] mmc: add ISSI IS22TF128G to fixed secure erase time quirk
Date: Thu, 26 Nov 2026 15:17:20 +0000 [thread overview]
Message-ID: <27db5e2bb9ac77193c504517f8fd96e6f2b305bb.camel@siemens.com> (raw)
In-Reply-To: <20261111120759.100830-2-michael.haener@siemens.com>
Hi!
On Wed, 2026-11-11 at 13:07 +0100, Michael Haener wrote:
> The ISSI IS22TF128G eMMC (CID manfid 0x9d, oemid 0x0101, name "IS128G")
> reports SECURE_REMOVAL_TYPE 0x01 (overwrite, then erase) and has a large
> per-command overhead for secure erase. Secure erasing a 33.5GiB
> partition with blkdiscard -s on an NXP i.MX8 (sdhci-esdhc-imx, HS400ES)
> is split into max_discard sized requests of about 3.5MiB, i.e. roughly
> 10000 secure erase commands, which takes 5-7 hours once ~27GiB of the
> partition have been written.
>
> Since the per-command overhead dominates, apply
> MMC_QUIRK_FIXED_SECURE_ERASE_TRIM_TIME so secure erase requests are no
> longer limited by max_discard. With the quirk, secure erasing the same
> partition with ~27GiB written takes about 6 minutes.
>
> Card parameters: ERASE_GROUP_DEF 0x01, HC_ERASE_GRP_SIZE 0x01 (512KiB),
> ERASE_TIMEOUT_MULT 0x12, SEC_ERASE_MULT 0x64, SEC_TRIM_MULT 0x64.
>
> Cc: stable@vger.kernel.org
> Signed-off-by: Michael Haener <michael.haener@siemens.com>
Reviewed-by: Alexander Sverdlin <alexander.sverdlin@siemens.com>
> ---
> drivers/mmc/core/card.h | 1 +
> drivers/mmc/core/quirks.h | 9 +++++++++
> 2 files changed, 10 insertions(+)
>
> diff --git a/drivers/mmc/core/card.h b/drivers/mmc/core/card.h
> index a7c364d0030a..dc99242a0af2 100644
> --- a/drivers/mmc/core/card.h
> +++ b/drivers/mmc/core/card.h
> @@ -93,6 +93,7 @@ struct mmc_fixup {
> #define CID_MANFID_SWISSBIT 0x5D
> #define CID_MANFID_KINGSTON 0x70
> #define CID_MANFID_HYNIX 0x90
> +#define CID_MANFID_ISSI 0x9D
> #define CID_MANFID_KINGSTON_SD 0x9F
> #define CID_MANFID_NUMONYX 0xFE
>
> diff --git a/drivers/mmc/core/quirks.h b/drivers/mmc/core/quirks.h
> index 98cb680e3ace..be29be8ec413 100644
> --- a/drivers/mmc/core/quirks.h
> +++ b/drivers/mmc/core/quirks.h
> @@ -162,6 +162,15 @@ static const struct mmc_fixup __maybe_unused mmc_blk_fixups[] = {
> MMC_FIXUP("IB2932", CID_MANFID_KINGSTON, 0x0100, add_quirk_mmc,
> MMC_QUIRK_FIXED_SECURE_ERASE_TRIM_TIME),
>
> + /*
> + * ISSI IS22TF128G has a large per-command overhead for secure erase
> + * once data has been written: splitting a 33GB secure erase into
> + * max_discard sized chunks takes hours, while a single command over
> + * the same range finishes in about 10 seconds.
> + */
> + MMC_FIXUP("IS128G", CID_MANFID_ISSI, CID_OEMID_ANY, add_quirk_mmc,
> + MMC_QUIRK_FIXED_SECURE_ERASE_TRIM_TIME),
> +
> END_FIXUP
> };
--
Alexander Sverdlin
Siemens AG
www.siemens.com
next prev parent reply other threads:[~2026-11-26 15:17 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-11-11 12:07 [PATCH 0/2] mmc: speed up secure erase on ISSI IS22TF128G eMMC Michael Haener
2026-11-11 12:07 ` [PATCH 1/2] mmc: add ISSI IS22TF128G to fixed secure erase time quirk Michael Haener
2026-11-26 15:17 ` Sverdlin, Alexander [this message]
2026-11-11 12:07 ` [PATCH 2/2] mmc: core: saturate erase timeout instead of overflowing Michael Haener
2026-11-26 15:17 ` Sverdlin, Alexander
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=27db5e2bb9ac77193c504517f8fd96e6f2b305bb.camel@siemens.com \
--to=alexander.sverdlin@siemens.com \
--cc=avri.altman@sandisk.com \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-mmc@vger.kernel.org \
--cc=michael.haener@siemens.com \
--cc=stable@vger.kernel.org \
--cc=ulfh@kernel.org \
--cc=ziniu.wang_1@nxp.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®