1. 27 Sep, 2019 2 commits
  2. 11 Sep, 2019 9 commits
  3. 06 Aug, 2019 1 commit
    • Baolin Wang's avatar
      mmc: sdhci-sprd: Fix the incorrect soft reset operation when runtime resuming · c6303c5d
      Baolin Wang authored
      The SD host controller specification defines 3 types software reset:
      software reset for data line, software reset for command line and software
      reset for all. Software reset for all means this reset affects the entire
      Host controller except for the card detection circuit.
      In sdhci_runtime_resume_host() we always do a software "reset for all",
      which causes the Spreadtrum variant controller to work abnormally after
      resuming. To fix the problem, let's do a software reset for the data and
      the command part, rather than "for all".
      However, as sdhci_runtime_resume() is a common sdhci function and we don't
      want to change the behaviour for other variants, let's introduce a new
      in-parameter for it. This enables the caller to decide if a "reset for all"
      shall be done or not.
      Signed-off-by: default avatarBaolin Wang <baolin.wang@linaro.org>
      Fixes: fb8bd90f
       ("mmc: sdhci-sprd: Add Spreadtrum's initial host controller")
      Cc: stable@vger.kernel.org
      Signed-off-by: default avatarUlf Hansson <ulf.hansson@linaro.org>
  4. 30 May, 2019 1 commit
  5. 28 May, 2019 1 commit
  6. 15 Apr, 2019 6 commits
  7. 08 Apr, 2019 1 commit
    • Will Deacon's avatar
      drivers: Remove explicit invocations of mmiowb() · fb24ea52
      Will Deacon authored
      mmiowb() is now implied by spin_unlock() on architectures that require
      it, so there is no reason to call it from driver code. This patch was
      generated using coccinelle:
      	- mmiowb();
      and invoked as:
      $ for d in drivers include/linux/qed sound; do \
      spatch --include-headers --sp-file mmiowb.cocci --dir $d --in-place; done
      NOTE: mmiowb() has only ever guaranteed ordering in conjunction with
      spin_unlock(). However, pairing each mmiowb() removal in this patch with
      the corresponding call to spin_unlock() is not at all trivial, so there
      is a small chance that this change may regress any drivers incorrectly
      relying on mmiowb() to order MMIO writes between CPUs using lock-free
      synchronisation. If you've ended up bisecting to this commit, you can
      reintroduce the mmiowb() calls using wmb() instead, which should restore
      the old behaviour on all architectures other than some esoteric ia64
      Acked-by: default avatarLinus Torvalds <torvalds@linux-foundation.org>
      Signed-off-by: default avatarWill Deacon <will.deacon@arm.com>
  8. 25 Feb, 2019 4 commits
  9. 08 Jan, 2019 1 commit
  10. 17 Dec, 2018 6 commits
  11. 06 Dec, 2018 1 commit
    • Alek Du's avatar
      mmc: sdhci: fix the timeout check window for clock and reset · b704441e
      Alek Du authored
      We observed some premature timeouts on a virtualization platform, the log
      is like this:
      case 1:
      [159525.255629] mmc1: Internal clock never stabilised.
      [159525.255818] mmc1: sdhci: ============ SDHCI REGISTER DUMP ===========
      [159525.256049] mmc1: sdhci: Sys addr:  0x00000000 | Version:  0x00001002
      [159525.257205] mmc1: sdhci: Wake-up:   0x00000000 | Clock:    0x0000fa03
      From the clock control register dump, we are pretty sure the clock was
      case 2:
      [  914.550127] mmc1: Reset 0x2 never completed.
      [  914.550321] mmc1: sdhci: ============ SDHCI REGISTER DUMP ===========
      [  914.550608] mmc1: sdhci: Sys addr:  0x00000010 | Version:  0x00001002
      After checking the sdhci code, we found the timeout check actually has a
      little window that the CPU can be scheduled out and when it comes back,
      the original time set or check is not valid.
      Fixes: 5a436cc0
       ("mmc: sdhci: Optimize delay loops")
      Cc: stable@vger.kernel.org      # v4.12+
      Signed-off-by: default avatarAlek Du <alek.du@intel.com>
      Acked-by: default avatarAdrian Hunter <adrian.hunter@intel.com>
      Signed-off-by: default avatarUlf Hansson <ulf.hansson@linaro.org>
  12. 08 Oct, 2018 7 commits