diff options
| author | Dov Levenglick <dovl@codeaurora.org> | 2015-07-01 14:24:20 +0300 |
|---|---|---|
| committer | Subhash Jadavani <subhashj@codeaurora.org> | 2016-05-31 15:26:55 -0700 |
| commit | b6c1c166809f7141efb13c2805027f189a75597a (patch) | |
| tree | 017c50bc9dd620506a8e14450b6309193ead39c6 /include | |
| parent | d3e52fdfea833ef55f07ce6b135fa35c600aa8d6 (diff) | |
mmc: core: add support for bkops during cmdq
Add support for handling both manual and auto
bkops when command queuing is running.
Change-Id: Ib967ca3c0420f4e54b3e93c497eb538d7347199a
Signed-off-by: Dov Levenglick <dovl@codeaurora.org>
[subhashj@codeaurora.org: fixed trivial merge conflicts]
Signed-off-by: Subhash Jadavani <subhashj@codeaurora.org>
Diffstat (limited to 'include')
| -rw-r--r-- | include/linux/mmc/card.h | 12 | ||||
| -rw-r--r-- | include/linux/mmc/core.h | 1 |
2 files changed, 12 insertions, 1 deletions
diff --git a/include/linux/mmc/card.h b/include/linux/mmc/card.h index 5c6c10be3fd1..2430ba0e1182 100644 --- a/include/linux/mmc/card.h +++ b/include/linux/mmc/card.h @@ -313,11 +313,14 @@ struct mmc_bkops_stats { /** * struct mmc_bkops_info - BKOPS data * @stats: statistic information regarding bkops - * @need_manual: indication whether have to send START_BKOPS + * @needs_check: indication whether need to check with the device + * whether it requires handling of BKOPS (CMD8) + * @needs_manual: indication whether have to send START_BKOPS * to the device */ struct mmc_bkops_info { struct mmc_bkops_stats stats; + bool needs_check; bool needs_manual; }; @@ -656,6 +659,13 @@ static inline bool mmc_card_configured_manual_bkops(const struct mmc_card *c) return c->ext_csd.man_bkops_en & EXT_CSD_BKOPS_MANUAL_EN; } +/* + * By software design, auto_bkops will be enabled on the device if it supports + * it. Therefore, testing if a card is configured to run bkops is synonymous + * to checking if it supports bkops + */ +#define mmc_card_configured_auto_bkops(c) mmc_card_support_auto_bkops(c) + #define mmc_card_name(c) ((c)->cid.prod_name) #define mmc_card_id(c) (dev_name(&(c)->dev)) diff --git a/include/linux/mmc/core.h b/include/linux/mmc/core.h index 014eb7e272c6..2f797fb527b0 100644 --- a/include/linux/mmc/core.h +++ b/include/linux/mmc/core.h @@ -201,6 +201,7 @@ extern void mmc_release_host(struct mmc_host *host); extern void mmc_get_card(struct mmc_card *card); extern void mmc_put_card(struct mmc_card *card); +extern void __mmc_put_card(struct mmc_card *card); extern void mmc_set_ios(struct mmc_host *host); extern int mmc_flush_cache(struct mmc_card *); |
