diff mbox series

[v2] mmc: core: document mmc_hw_reset()

Message ID 20200918215446.65654-1-wsa+renesas@sang-engineering.com (mailing list archive)
State New, archived
Headers show
Series [v2] mmc: core: document mmc_hw_reset() | expand

Commit Message

Wolfram Sang Sept. 18, 2020, 9:54 p.m. UTC
Add documentation for mmc_hw_reset to make sure the intended use case is
clear.

Signed-off-by: Wolfram Sang <wsa+renesas@sang-engineering.com>
---

Changes since v1:
* make clear it is a full reset
* don't say "remote card"

 drivers/mmc/core/core.c | 10 ++++++++++
 1 file changed, 10 insertions(+)

Comments

Ulf Hansson Sept. 24, 2020, 12:49 p.m. UTC | #1
On Fri, 18 Sep 2020 at 23:54, Wolfram Sang
<wsa+renesas@sang-engineering.com> wrote:
>
> Add documentation for mmc_hw_reset to make sure the intended use case is
> clear.
>
> Signed-off-by: Wolfram Sang <wsa+renesas@sang-engineering.com>

Applied for next, thanks!

Kind regards
Uffe


> ---
>
> Changes since v1:
> * make clear it is a full reset
> * don't say "remote card"
>
>  drivers/mmc/core/core.c | 10 ++++++++++
>  1 file changed, 10 insertions(+)
>
> diff --git a/drivers/mmc/core/core.c b/drivers/mmc/core/core.c
> index 8ccae6452b9c..d42037f0f10d 100644
> --- a/drivers/mmc/core/core.c
> +++ b/drivers/mmc/core/core.c
> @@ -2063,6 +2063,16 @@ static void mmc_hw_reset_for_init(struct mmc_host *host)
>         host->ops->hw_reset(host);
>  }
>
> +/**
> + * mmc_hw_reset - reset the card in hardware
> + * @host: MMC host to which the card is attached
> + *
> + * Hard reset the card. This function is only for upper layers, like the
> + * block layer or card drivers. You cannot use it in host drivers (struct
> + * mmc_card might be gone then).
> + *
> + * Return: 0 on success, -errno on failure
> + */
>  int mmc_hw_reset(struct mmc_host *host)
>  {
>         int ret;
> --
> 2.28.0
>
diff mbox series

Patch

diff --git a/drivers/mmc/core/core.c b/drivers/mmc/core/core.c
index 8ccae6452b9c..d42037f0f10d 100644
--- a/drivers/mmc/core/core.c
+++ b/drivers/mmc/core/core.c
@@ -2063,6 +2063,16 @@  static void mmc_hw_reset_for_init(struct mmc_host *host)
 	host->ops->hw_reset(host);
 }
 
+/**
+ * mmc_hw_reset - reset the card in hardware
+ * @host: MMC host to which the card is attached
+ *
+ * Hard reset the card. This function is only for upper layers, like the
+ * block layer or card drivers. You cannot use it in host drivers (struct
+ * mmc_card might be gone then).
+ *
+ * Return: 0 on success, -errno on failure
+ */
 int mmc_hw_reset(struct mmc_host *host)
 {
 	int ret;