1. 10 11月, 2014 6 次提交
  2. 24 9月, 2014 1 次提交
  3. 23 9月, 2014 1 次提交
  4. 19 9月, 2014 3 次提交
  5. 09 9月, 2014 2 次提交
  6. 09 7月, 2014 1 次提交
  7. 13 5月, 2014 5 次提交
  8. 22 4月, 2014 1 次提交
  9. 21 4月, 2014 1 次提交
  10. 23 2月, 2014 3 次提交
  11. 14 2月, 2014 4 次提交
  12. 14 1月, 2014 1 次提交
  13. 31 10月, 2013 9 次提交
    • U
      mmc: core: Add MMC_CAP_RUNTIME_RESUME to resume at runtime_resume · 4d223782
      Ulf Hansson 提交于
      In some environments it is to prefer to postpone the resume of the card
      device until runtime_resume is being carried out, since it will mean a
      signficant decrease of the total system resume time.
      
      The reason of the decreased resume time is simply because of the actual
      re-initalization of the card, which typically takes hundreds of
      milliseconds, is performed outside the resume sequence and wont thus
      affect it.
      
      For removable card, the detect work tries to re-detect the card to make
      sure it is still present, as a part of that sequence the card will also
      be runtime_resumed and thus also fully resumed.
      
      For a non-removable card, typically a mmc blk request will trigger a
      runtime_resume and thus fully resume the card. This also means the
      first request will likely suffer from an inital latency since the
      re-initialization of the card needs to be performed.
      Signed-off-by: NUlf Hansson <ulf.hansson@linaro.org>
      Signed-off-by: NChris Ball <cjb@laptop.org>
      4d223782
    • U
      mmc: core: Improve runtime PM support during suspend/resume for sd/mmc · 0cb403a2
      Ulf Hansson 提交于
      The card device is considered as in-active after it has been suspended.
      To prevent any further runtime PM requests in suspend state, we then
      disable runtime PM.
      
      After the card device has been resumed, we shall consider it as active,
      like we also do after a probe sequence. When resumed, we can safely
      enable runtime PM again.
      
      This will make sure the PM core can request the card device to go to
      in-active state after a resume has been completed. Previously we had to
      wait for new pm_runtime_get->pm_runtime_put cycle to be executed.
      
      Additionally, once a resume has been carried out, update the last busy
      mark. At the moment this will have no effect but if the PM core will
      respect autosuspend enabled devices, when it directly triggers a
      runtime_suspend from a runtime_idle, it will mean the card device will
      be scheduled for a delayed runtime_suspend instead of done immediately.
      Signed-off-by: NUlf Hansson <ulf.hansson@linaro.org>
      Signed-off-by: NChris Ball <cjb@laptop.org>
      0cb403a2
    • U
      mmc: core: Remove redundant mmc_power_up|off at runtime callbacks · 0cc81a8c
      Ulf Hansson 提交于
      Commit "mmc: core: Push common suspend|resume code into each bus_ops"
      moved the responsibility for doing mmc_power_up|off into each
      suspend/resume bus_ops. When using MMC_CAP_AGGRESSIVE_PM, through the
      runtime callbacks, calls to mmc_power_up|off became redundant.
      
      When removing them, we are also able to remove the calls to
      mmc_claim|release_host, thus simplifing code a bit more.
      Signed-off-by: NUlf Hansson <ulf.hansson@linaro.org>
      Signed-off-by: NChris Ball <cjb@laptop.org>
      0cc81a8c
    • U
      mmc: Don't force card to active state when entering suspend/shutdown · 9ec775f7
      Ulf Hansson 提交于
      By adding a card state that records if it is suspended or resumed, we
      can accept asyncronus suspend/resume requests for the mmc and sd
      bus_ops.
      
      MMC_CAP_AGGRESSIVE_PM, will at request inactivity through the runtime
      bus_ops callbacks, execute a suspend of the the card. In the state were
      this has been done, we can receive a suspend request for the mmc bus,
      which for sd and mmc forced the card to active state by a
      pm_runtime_get_sync. In other words, the card was resumed and then
      immediately suspended again, completely unnecessary.
      
      Since the suspend/resume bus_ops callbacks for sd and mmc are now
      capable of handling asynchronous requests, we no longer need to force
      the card to active state before executing suspend. Evidently preventing
      the above sequence for MMC_CAP_AGGRESSIVE_PM.
      Signed-off-by: NUlf Hansson <ulf.hansson@linaro.org>
      Signed-off-by: NChris Ball <cjb@laptop.org>
      9ec775f7
    • U
      mmc: core: Collect common code for card ocr validation · 726d6f23
      Ulf Hansson 提交于
      Since mmc_select_voltage now only gets called from the attach sequence,
      it makes sense to move the out of spec validations of the card ocr into
      this function.
      Signed-off-by: NUlf Hansson <ulf.hansson@linaro.org>
      Signed-off-by: NChris Ball <cjb@laptop.org>
      726d6f23
    • U
      mmc: core: Prevent violation of specs while initializing cards · ce69d37b
      Ulf Hansson 提交于
      According to eMMC/SD/SDIO specs, the VDD (VCC) voltage level must be
      maintained during the initialization sequence. If we want/need to tune
      the voltage level, a complete power cycle of the card must be executed.
      
      Most host drivers conforms to the specifications by only allowing to
      change VDD voltage level at the MMC_POWER_UP state, but some also cares
      about MMC_POWER_ON state, which they should'nt. This patch will not
      break those drivers, but they could clean up code to better reflect
      what is expected from the protocol layer.
      
      A big re-work of the mmc_select_voltage function is done to only change
      VDD voltage level if the host supports MMC_CAP2_FULL_PWR_CYCLE.
      Otherwise only validation of the host and card ocr mask will be done.
      
      A very nice side-effect of this patch is that we now don't need to
      reset the negotiated ocr mask at the mmc_power_off function, since now
      it will actually reflect the present voltage level, which safely can be
      used at the next power up and re-initialization. Moreover, we then only
      need to execute mmc_select_voltage from the attach sequence.
      Signed-off-by: NUlf Hansson <ulf.hansson@linaro.org>
      Signed-off-by: NChris Ball <cjb@laptop.org>
      ce69d37b
    • U
      mmc: core: Move cached value of the negotiated ocr mask to card struct · 69041150
      Ulf Hansson 提交于
      The negotiated ocr mask is directly related to the card. Once a card
      gets removed, the mask shall be dropped. By moving the cache of the ocr
      mask from the host struct to the card struct we have accomplished this.
      Signed-off-by: NUlf Hansson <ulf.hansson@linaro.org>
      Signed-off-by: NChris Ball <cjb@laptop.org>
      69041150
    • U
      mmc: core: Let mmc_power_up|cycle take ocr as parameter · 4a065193
      Ulf Hansson 提交于
      As a step to fixup the setup of the negotiated ocr mask, we need the
      mmc_power_up|cycle functions to take the ocr as a parameter.
      Signed-off-by: NUlf Hansson <ulf.hansson@linaro.org>
      Signed-off-by: NChris Ball <cjb@laptop.org>
      4a065193
    • U
      mmc: core: Do not poll for busy with status cmd for all switch cmds · 878e200b
      Ulf Hansson 提交于
      Some switch operations like poweroff notify, shall according to the
      spec not be followed by any other new commands. For these cases and
      when the host does'nt support MMC_CAP_WAIT_WHILE_BUSY, we must not
      send status commands to poll for busy detection. Instead wait for
      the stated timeout from the EXT_CSD before completing the request.
      Signed-off-by: NUlf Hansson <ulf.hansson@linaro.org>
      Cc: Jaehoon Chung <jh80.chung@samsung.com>
      Signed-off-by: NChris Ball <cjb@laptop.org>
      878e200b
  14. 06 7月, 2013 1 次提交
    • R
      mmc: core: production year for eMMC 4.41 and later · 7c4f10ac
      Romain Izard 提交于
      The field containing the production date in the CID register only uses
      4 bits to encode the year, starting from 1997 in the original standard.
      In 2013, the production year field contains 0, and the kernel reports a
      1997 production date.
      
      The eMMC 4.51 specification adds a new interpretation rule. For all
      devices implementing the 4.41 specification or later, the production
      year field will be interpreted as a value between 2010 and 2025, with
      0 corresponding to 2013.
      Signed-off-by: NRomain Izard <romain.izard.pro@gmail.com>
      Signed-off-by: NChris Ball <cjb@laptop.org>
      7c4f10ac
  15. 28 6月, 2013 1 次提交
    • U
      mmc: core: Invent MMC_CAP2_FULL_PWR_CYCLE · 53275c21
      Ulf Hansson 提交于
      MMC_CAP2_FULL_PWR_CYCLE shall be set by host drivers which are able to
      do a complete power cycle of the card. In the eMMC case that includes
      both vcc and vccq.
      
      This CAP is providing the protocol layer with important information,
      needed to take optimized decisions during card initialization and in
      the suspend/resume sequence.
      
      MMC_CAP2_POWEROFF_NOTIFY is replaced by MMC_CAP2_FULL_PWR_CYCLE, since
      it makes sense to use a wider scope for it.
      Signed-off-by: NUlf Hansson <ulf.hansson@linaro.org>
      Signed-off-by: NChris Ball <cjb@laptop.org>
      53275c21