diff options
author | Andres Rodriguez <andresx7@gmail.com> | 2022-11-08 17:32:25 -0500 |
---|---|---|
committer | Cristian Ciocaltea <cristian.ciocaltea@collabora.com> | 2023-09-11 23:31:24 +0300 |
commit | b049538b926da3c157cc204234a6d30de477316b (patch) | |
tree | 4f90f9ba65e872acf39f1d03458274dfadd8def5 /include | |
parent | 702cde8d6a95a9b5f7be4d54f5222ae142d33b9e (diff) | |
download | linux-b049538b926da3c157cc204234a6d30de477316b.tar.gz |
mmc: core: add safe_trim_quirk attribute
This attribute is intended to be used by userspace tools to identify if trimming a device is safe or not. It helps in cases where a userspace tool is aware of the necessity of the quirk and a user accidentally downgrades their kernel to a one that doesn't have support for the quirk. Signed-off-by: Andres Rodriguez <andresx7@gmail.com> (cherry picked from commit dfc5952c55f58d0e0863ccba0aa598fdae16ed14) Signed-off-by: Cristian Ciocaltea <cristian.ciocaltea@collabora.com>
Diffstat (limited to 'include')
-rw-r--r-- | include/linux/mmc/card.h | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/include/linux/mmc/card.h b/include/linux/mmc/card.h index daa2f40d9ce6..6b7cb137def8 100644 --- a/include/linux/mmc/card.h +++ b/include/linux/mmc/card.h @@ -277,6 +277,7 @@ struct mmc_card { unsigned int state; /* (our) card state */ unsigned int quirks; /* card quirks */ unsigned int quirk_max_rate; /* max rate set by quirks */ + unsigned int safe_trim_quirk_version; /* advertise if we have protection for cards which misbehave with trim */ #define MMC_QUIRK_LENIENT_FN0 (1<<0) /* allow SDIO FN0 writes outside of the VS CCCR range */ #define MMC_QUIRK_BLKSZ_FOR_BYTE_MODE (1<<1) /* use func->cur_blksize */ /* for byte mode */ |