• Haibo Chen's avatar
    mmc: sdhci: call sdhci_init() before request irq · 14a7b416
    Haibo Chen authored
    sdhci_init() will clear all irqs and set the needed irqs. So
    logically sdhci_init() should be called before request irq.
    
    If not, some irqs may be triggled and handled wrongly. Take
    the following into consideration, after request irq, if
    SDIO card interrupt enabled, a sd card in the sd slot will
    trigger a mass of interrupt(SDHCI_INT_CARD_INT), because at
    this time, the vmmc-regulator still not restore, no voltage
    supply for the sd card, so the pin of data0~data3 change and
    keep low, interrupt(SDHCI_INT_CARD_INT) will rise up ceaselessly.
    Due to we already reguest irq, system will be busy in handling
    this endless irq, can't response to other event.
    
    So we should call sdhci_init() before request irq in sd resume.
    Signed-off-by: default avatarHaibo Chen <haibo.chen@freescale.com>
    Signed-off-by: default avatarUlf Hansson <ulf.hansson@linaro.org>
    14a7b416
sdhci.c 91.4 KB