1. 12 2月, 2013 3 次提交
    • K
      mmc: sdhci: add IRQ wake up support · ad080d79
      Kevin Liu 提交于
      Don't disable SD Host IRQ during suspend if it is wake up source.
      Enable wakeup event during suspend.
      Signed-off-by: NJialing Fu <jlfu@marvell.com>
      Signed-off-by: NKevin Liu <kliu5@marvell.com>
      Signed-off-by: NChris Ball <cjb@laptop.org>
      ad080d79
    • K
      mmc: sdhci: disable interrupt before free_irq · b0a8dece
      Kevin Liu 提交于
      Current code missed disabling interrupts before free irq which is shared.
      
      Notice below comments for function free_irq (kernel/irq/manage.c):
      On a shared IRQ the caller must ensure the interrupt is disabled
      on the card it drives before calling this function.
      
      Original code has below issue during suspend/resume when multiple SD
      hosts share the same IRQ:
      1. Assume there are two hosts (host1 for emmc while host2 for sd) share
      the same mmc irq.
      2. When system suspend, host2 will be suspended before host1.
      So the sequence is below:
      	step1: irq handler for host2 removed ->
      	step2: irq handler for host1 removed and irq disabled ->
      	... system suspended ...
      	... system resumed ...
      	step3: irq enabled and the irq handler for host1 restored ->
      	step4: irq handler for host2 restored
      3. So there is the buggy time slot that the irq is enabled but the irq
      handler for host2 is removed. Then host2 interrupt can be triggered
      but can't be handled at that moment.
      Signed-off-by: NJialing Fu <jlfu@marvell.com>
      Signed-off-by: NKevin Liu <kliu5@marvell.com>
      Signed-off-by: NChris Ball <cjb@laptop.org>
      b0a8dece
    • S
      mmc: sdhci: query card presence from cd-gpio before asking SDHCI · 505a8680
      Shawn Guo 提交于
      Call mmc_gpio_get_cd() to query card presence from cd-gpio before
      asking SDHCI.  The rationale behind this change is that flag
      SDHCI_QUIRK_BROKEN_CARD_DETECTION is designed for SDHCI controller to
      tell that SDHCI_PRESENT_STATE is broken, and it should be used for this
      case only.  So when cd-gpio is being used, the controller should set
      the flag to tell that SDHCI_PRESENT_STATE is not available.
      
      However, the existing code will skip checking cd-gpio as long as flag
      SDHCI_QUIRK_BROKEN_CARD_DETECTION is set.  Change the querying order
      between cd-gpio and SDHCI to support the rationale above.
      Signed-off-by: NShawn Guo <shawn.guo@linaro.org>
      Signed-off-by: NChris Ball <cjb@laptop.org>
      505a8680
  2. 08 12月, 2012 1 次提交
  3. 07 12月, 2012 4 次提交
  4. 08 11月, 2012 3 次提交
  5. 08 10月, 2012 1 次提交
  6. 19 9月, 2012 1 次提交
    • G
      mmc: sdhci: Test cd-gpio instead of SDHCI presence when probing · bec9d4e5
      Guennadi Liakhovetski 提交于
      Previously to this patch, an SDHCI platform that uses a GPIO for
      card detection instead of the internal SDHCI_CARD_PRESENT bit on
      the presence register would fail to detect a new card.
      
      Some drivers worked around this in various ways: esdhc-imx defines
      an IO accessor to fake the presence bit being true, s3c turns on
      polling (which stops the SDHCI driver from checking the bit) after
      a card's inserted.  But none of this should be necessary; the real
      fix is to check whether we're using a GPIO and avoid relying on
      the presence bit if so, as this patch implements.
      Signed-off-by: NGuennadi Liakhovetski <g.liakhovetski@gmx.de>
      Signed-off-by: NChris Ball <cjb@laptop.org>
      bec9d4e5
  7. 05 9月, 2012 2 次提交
  8. 23 7月, 2012 8 次提交
  9. 21 7月, 2012 3 次提交
  10. 06 6月, 2012 1 次提交
  11. 22 4月, 2012 1 次提交
  12. 21 4月, 2012 1 次提交
    • D
      mmc: sdhci: refine non-removable card checking for card detection · 87b87a3f
      Daniel Drake 提交于
      Commit c79396c1 ("mmc: sdhci: prevent card detection activity
      for non-removable cards") disables card detection where the cards
      are marked as non-removable.
      
      This makes sense, but the implementation detail of calling
      mmc_card_is_removable() causes some problems, because
      mmc_card_is_removable() is overloaded with CONFIG_MMC_UNSAFE_RESUME
      semantics.
      
      In the OLPC XO case, we need CONFIG_MMC_UNSAFE_RESUME because our root
      filesystem is stored on SD, but we also have external SD card slots
      where we want automatic card detection.
      
      Refine the check to only apply to hosts marked as MMC_CAP_NONREMOVABLE,
      which is defined to mean that the card is *really* nonremovable. This
      could be revisited in future if we find a way to improve
      CONFIG_MMC_UNSAFE_RESUME semantics.
      Signed-off-by: NDaniel Drake <dsd@laptop.org>
      Acked-by: NChuanxiao Dong <chuanxiao.dong@intel.com>
      [stable@: please apply to 3.3-stable]
      Cc: stable <stable@vger.kernel.org>
      Signed-off-by: NChris Ball <cjb@laptop.org>
      87b87a3f
  13. 06 4月, 2012 1 次提交
  14. 28 3月, 2012 2 次提交
  15. 26 3月, 2012 1 次提交
  16. 13 1月, 2012 5 次提交
  17. 12 1月, 2012 2 次提交