• Adrian Hunter's avatar
    mmc: sdhci: Move busy signal handling into sdhci_finish_cmd() · 6bde8681
    Adrian Hunter authored
    In order to support commands during data transfer, command and data
    handling needs to be untangled.
    
    That means sdhci_finish_cmd() must not be called from the data IRQ
    handler. It is being called because of busy signal handling, which
    is treating the command as not finished until the busy signal is
    released.
    
    Instead, move busy signal handling from sdhci_cmd_irq() into
    sdhci_finish_cmd(). Then the data IRQ handler does not need to call
    sdhci_finish_cmd() and can instead finish the request.
    
    What this means in practice for a command with busy signaling, is that
    the command response is read from the host controller when the command
    complete interrupt is received, thus freeing up the command circuit for
    other commands.
    Signed-off-by: default avatarAdrian Hunter <adrian.hunter@intel.com>
    Signed-off-by: default avatarUlf Hansson <ulf.hansson@linaro.org>
    6bde8681
sdhci.c 92.4 KB