Re: [PATCH 1/3] mmc: omap_hsmmc: Errata i705: SD hot unplug

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Fri, May 25, 2012 at 1:44 AM, Viswanath Puttagunta <vishp@xxxxxx> wrote:
> Turn off IO & PBIAS cells and then SD card VMMC as soon
> as we get disconnect interrupt. Failure to do so might
> cause current spikes (latch-up issue) which can potentially
> burn the IO cells.
>
> Signed-off-by: Viswanath Puttagunta <vishp@xxxxxx>
> ---
>  drivers/mmc/host/omap_hsmmc.c |   13 ++++++++++---
>  1 files changed, 10 insertions(+), 3 deletions(-)
>
> diff --git a/drivers/mmc/host/omap_hsmmc.c b/drivers/mmc/host/omap_hsmmc.c
> index 56d4499..61d830f 100644
> --- a/drivers/mmc/host/omap_hsmmc.c
> +++ b/drivers/mmc/host/omap_hsmmc.c
> @@ -1177,10 +1177,17 @@ static irqreturn_t omap_hsmmc_detect(int irq, void *dev_id)
>                carddetect = -ENOSYS;
>        }
>
> -       if (carddetect)
> +       if (carddetect) {
>                mmc_detect_change(host->mmc, (HZ * 200) / 1000);
> -       else
> -               mmc_detect_change(host->mmc, (HZ * 50) / 1000);
> +       } else {
> +               if ((MMC_POWER_OFF != host->power_mode) &&

Should be if((host->power_mode != MMC_POWER_OFF)

> +                               (mmc_slot(host).set_power != NULL)) {
> +                       mmc_slot(host).set_power(host->dev, host->slot_id,
> +                                               0, 0);
> +                       host->power_mode = MMC_POWER_OFF;

This is just changing the default behaviour, irrespective of whether
the errata is applicable.
What is the effect of this change for other boards / platforms ?

> +               }
> +               mmc_detect_change(host->mmc, 0);
> +       }
>        return IRQ_HANDLED;
>  }
>
> --
> 1.7.4.1
>
--
To unsubscribe from this list: send the line "unsubscribe linux-mmc" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[Index of Archives]     [Linux USB Devel]     [Linux Media]     [Video for Linux]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux