1. 22 12月, 2015 1 次提交
    • A
      mmc: sdhci: 64-bit DMA actually has 4-byte alignment · 04a5ae6f
      Adrian Hunter 提交于
      The version 3.00 SDHCI spec. was a bit unclear about the
      required data alignment for 64-bit DMA, whereas the version
      4.10 spec. uses different language and indicates that only
      4-byte alignment is required rather than the 8-byte alignment
      currently implemented.  That make no difference to SD and EMMC
      which invariably transfer data in sector-aligned blocks.
      However with SDIO, it results in using more DMA descriptors
      than necessary.  Theoretically that slows DMA slightly although
      DMA is not the limiting factor for throughput, so there is no
      discernable impact on performance.  Nevertheless, the driver
      should follw the spec unless there is good reason not to, so
      this patch corrects the alignment criterion.
      
      There is a more complicated criterion for the DMA descriptor
      table itself.  However the table is allocated by dma_alloc_coherent()
      which allocates pages (i.e. aligned to a page boundary).
      For simplicity just check it is 8-byte aligned, but add a comment
      that some Intel controllers actually require 8-byte alignment
      even when using 32-bit DMA.
      Signed-off-by: NAdrian Hunter <adrian.hunter@intel.com>
      Signed-off-by: NUlf Hansson <ulf.hansson@linaro.org>
      04a5ae6f
  2. 09 10月, 2015 1 次提交
  3. 27 8月, 2015 1 次提交
    • H
      mmc: sdhci: fix dma memory leak in sdhci_pre_req() · d31911b9
      Haibo Chen 提交于
      Currently one mrq->data maybe execute dma_map_sg() twice
      when mmc subsystem prepare over one new request, and the
      following log show up:
      	sdhci[sdhci_pre_dma_transfer] invalid cookie: 24, next-cookie 25
      
      In this condition, mrq->date map a dma-memory(1) in sdhci_pre_req
      for the first time, and map another dma-memory(2) in sdhci_prepare_data
      for the second time. But driver only unmap the dma-memory(2), and
      dma-memory(1) never unmapped, which cause the dma memory leak issue.
      
      This patch use another method to map the dma memory for the mrq->data
      which can fix this dma memory leak issue.
      
      Fixes: 348487cb ("mmc: sdhci: use pipeline mmc requests to improve performance")
      Reported-and-tested-by: NJiri Slaby <jslaby@suse.cz>
      Signed-off-by: NHaibo Chen <haibo.chen@freescale.com>
      Signed-off-by: NUlf Hansson <ulf.hansson@linaro.org>
      d31911b9
  4. 17 8月, 2015 1 次提交
  5. 01 6月, 2015 2 次提交
  6. 23 3月, 2015 1 次提交
  7. 20 1月, 2015 1 次提交
  8. 05 12月, 2014 1 次提交
  9. 26 11月, 2014 2 次提交
    • A
      mmc: sdhci: Add HS400 support to SDHCI driver · e9fb05d5
      Adrian Hunter 提交于
      MMC core already has support for HS400.  Add HS400
      support to SDHCI driver.  The SDHC Standard specification
      does not define HS400 so consequently HS400 support is
      non-standard.  However HS400 is not selected without
      the host controller setting the corresponding capability
      flags so host controllers not yet supporting HS400
      will not be affected.  To support that, a quirk
      SDHCI_QUIRK2_CAPS_BIT63_FOR_HS400 is introduced to
      enable the use of capabilities register reserved bit-63
      to indicate HS400 support.
      
      Because HS400 is non-standard for SDHCI, it is possible
      that different vendors will do things in different ways.
      However HS200 support faced the same issue but currently
      there is only one solution.  As such, no attempt has
      been made to provide for alternate HS400 solutions except
      for SDHCI_QUIRK2_CAPS_BIT63_FOR_HS400.
      Signed-off-by: NAdrian Hunter <adrian.hunter@intel.com>
      Signed-off-by: NUlf Hansson <ulf.hansson@linaro.org>
      e9fb05d5
    • A
      mmc: sdhci: Remove unused SDHCI_CTRL_HS_SDR200 · 04834a78
      Adrian Hunter 提交于
      SDHCI_CTRL_HS_SDR200 is unused.  Remove it.
      Signed-off-by: NAdrian Hunter <adrian.hunter@intel.com>
      Signed-off-by: NUlf Hansson <ulf.hansson@linaro.org>
      04834a78
  10. 10 11月, 2014 4 次提交
  11. 24 9月, 2014 1 次提交
  12. 09 9月, 2014 2 次提交
  13. 22 5月, 2014 7 次提交
  14. 26 9月, 2013 2 次提交
  15. 06 7月, 2013 1 次提交
  16. 25 2月, 2013 2 次提交
    • K
      mmc: sdhci: enhance preset value function · 52983382
      Kevin Liu 提交于
      4d55c5a1 ("mmc: sdhci: enable preset value after uhs initialization")
      added preset value support and enabled it by default during sd card init.
      
      Below are the enhancements introduced by this patch:
      
      1. In current code, preset value is enabled after setting clock finished,
      which means the clock is manually set by driver firstly and then suddenly
      switched to preset value at this point. So the first setting is useless
      and unnecessary. What's more, the first clock setting may differ from the
      preset one.  The better way is enable preset value just after switch to
      UHS mode so the preset value can take effect immediately. So move preset
      value enable from mmc_sd_init_card to sdhci_set_ios which will be called
      during set timing.
      
      2. In current code, preset value is disabled at the beginning of
      mmc_attach_sd.  It's too late since low freq (400khz) should be set in
      mmc_power_up.  So move preset value disable to sdhci_set_ios which will
      be called during power up.
      
      3. host->clock and ios->drv_type should also be updated according to the
      preset value if it's enabled. Current code missed this.
      
      4. This patch also introduce a quirk to disable preset value in case
      preset value doesn't work.
      
      This patch has been verified on sdhci-pxav3 platform with both preset
      enabled and disabled.
      Signed-off-by: NKevin Liu <kliu5@marvell.com>
      Reviewed-by: NUlf Hansson <ulf.hansson@linaro.org>
      Signed-off-by: NChris Ball <cjb@laptop.org>
      52983382
    • S
      mmc: sdhci: rename platform_8bit_width to platform_bus_width · 7bc088d3
      Sascha Hauer 提交于
      The 8bit in the function name is misleading. When set, it will be
      used to set the bus width, regardless of whether 8bit or another
      bus width is requested, so change the function name to
      platform_bus_width.
      Signed-off-by: NSascha Hauer <s.hauer@pengutronix.de>
      Signed-off-by: NShawn Guo <shawn.guo@linaro.org>
      Tested-by: NDirk Behme <dirk.behme@de.bosch.com>
      Signed-off-by: NChris Ball <cjb@laptop.org>
      7bc088d3
  17. 07 12月, 2012 1 次提交
  18. 08 11月, 2012 1 次提交
  19. 21 7月, 2012 1 次提交
  20. 26 3月, 2012 1 次提交
  21. 13 1月, 2012 1 次提交
  22. 20 12月, 2011 1 次提交
  23. 27 10月, 2011 2 次提交
  24. 26 5月, 2011 2 次提交