summaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeFilesLines
* Merge tag 'mmc-updates-for-3.13-rc1' of ↵Linus Torvalds2013-11-1854-1240/+1818
|\ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | git://git.kernel.org/pub/scm/linux/kernel/git/cjb/mmc Pull MMC updates from Chris Ball: "MMC highlights for 3.13: Core: - Improve runtime PM support, remove mmc_{suspend,resume}_host(). - Add MMC_CAP_RUNTIME_RESUME, for delaying MMC resume until we're outside of the resume sequence (in runtime_resume) to decrease system resume time. Drivers: - dw_mmc: Support HS200 mode. - sdhci-eshdc-imx: Support SD3.0 SDR clock tuning, DDR on IMX6. - sdhci-pci: Add support for Intel Clovertrail and Merrifield" * tag 'mmc-updates-for-3.13-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/cjb/mmc: (108 commits) mmc: wbsd: Silence compiler warning mmc: core: Silence compiler warning in __mmc_switch mmc: sh_mmcif: Convert to clk_prepare|unprepare mmc: sh_mmcif: Convert to PM macros when defining dev_pm_ops mmc: dw_mmc: exynos: Revert the sdr_timing assignment mmc: sdhci: Avoid needless loop while handling SDIO interrupts in sdhci_irq mmc: core: Add MMC_CAP_RUNTIME_RESUME to resume at runtime_resume mmc: core: Improve runtime PM support during suspend/resume for sd/mmc mmc: core: Remove redundant mmc_power_up|off at runtime callbacks mmc: Don't force card to active state when entering suspend/shutdown MIPS: db1235: Don't use MMC_CLKGATE mmc: core: Remove deprecated mmc_suspend|resume_host APIs mmc: mmci: Move away from using deprecated APIs mmc: via-sdmmc: Move away from using deprecated APIs mmc: tmio: Move away from using deprecated APIs mmc: sh_mmcif: Move away from using deprecated APIs mmc: sdricoh_cs: Move away from using deprecated APIs mmc: rtsx: Remove redundant suspend and resume callbacks mmc: wbsd: Move away from using deprecated APIs mmc: pxamci: Remove redundant suspend and resume callbacks ...
| * mmc: wbsd: Silence compiler warningUlf Hansson2013-11-081-1/+0Star
| | | | | | | | | | | | | | | | | | The commit "mmc: wbsd: Move away from using deprecated APIs" introduced a compiler warning, let's silence it. Cc: Pierre Ossman <pierre@ossman.eu> Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org> Signed-off-by: Chris Ball <cjb@laptop.org>
| * mmc: core: Silence compiler warning in __mmc_switchUlf Hansson2013-11-081-1/+1
| | | | | | | | | | Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org> Signed-off-by: Chris Ball <cjb@laptop.org>
| * mmc: sh_mmcif: Convert to clk_prepare|unprepareUlf Hansson2013-11-081-6/+6
| | | | | | | | | | | | | | | | | | | | Previously only clk_enable|disable were being used. Adapt properly to the clock API, by also using clk_prepare|unprepare. Cc: Guennadi Liakhovetski <g.liakhovetski@gmx.de> Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org> Acked-by: Guennadi Liakhovetski <g.liakhovetski@gmx.de> Signed-off-by: Chris Ball <cjb@laptop.org>
| * mmc: sh_mmcif: Convert to PM macros when defining dev_pm_opsUlf Hansson2013-11-081-7/+3Star
| | | | | | | | | | | | | | | | | | Use SET_SYSTEM_SLEEP_PM_OPS to simplify code. Cc: Guennadi Liakhovetski <g.liakhovetski@gmx.de> Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org> Acked-by: Guennadi Liakhovetski <g.liakhovetski@gmx.de> Signed-off-by: Chris Ball <cjb@laptop.org>
| * mmc: dw_mmc: exynos: Revert the sdr_timing assignmentYuvaraj Kumar C D2013-11-081-1/+2
| | | | | | | | | | | | | | | | | | | | e6c784eded7b3 ("mmc: dw_mmc: exynos: move the exynos private init") was wrongly assigning ddr_timing value to sdr_timing. This patch fixes this by reverting the sdr_timing assignment statement to the earlier location. Signed-off-by: Yuvaraj Kumar C D <yuvaraj.cd@samsung.com> Acked-by: Seungwon Jeon <tgih.jun@samsung.com> Signed-off-by: Chris Ball <cjb@laptop.org>
| * mmc: sdhci: Avoid needless loop while handling SDIO interrupts in sdhci_irqAlexey Neyman2013-11-081-0/+8
| | | | | | | | | | | | | | | | | | | | | | Ignore Card Interrupt bit in the interrupt status if we already know that mmc_signal_sdio_irq() is going to be called at the end of sdhci_irq(). This avoids a needless loop in sdhci_irq() repeatedly reading interrupt status and doing nothing. Signed-off-by: Alexey Neyman <stilor@att.net> Acked-by: Dong Aisheng <b29396@freescale.com> Signed-off-by: Chris Ball <cjb@laptop.org>
| * mmc: core: Add MMC_CAP_RUNTIME_RESUME to resume at runtime_resumeUlf Hansson2013-10-313-10/+15
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 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: Ulf Hansson <ulf.hansson@linaro.org> Signed-off-by: Chris Ball <cjb@laptop.org>
| * mmc: core: Improve runtime PM support during suspend/resume for sd/mmcUlf Hansson2013-10-312-17/+66
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 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: Ulf Hansson <ulf.hansson@linaro.org> Signed-off-by: Chris Ball <cjb@laptop.org>
| * mmc: core: Remove redundant mmc_power_up|off at runtime callbacksUlf Hansson2013-10-312-24/+2Star
| | | | | | | | | | | | | | | | | | | | | | | | | | 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: Ulf Hansson <ulf.hansson@linaro.org> Signed-off-by: Chris Ball <cjb@laptop.org>
| * mmc: Don't force card to active state when entering suspend/shutdownUlf Hansson2013-10-314-17/+55
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 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: Ulf Hansson <ulf.hansson@linaro.org> Signed-off-by: Chris Ball <cjb@laptop.org>
| * MIPS: db1235: Don't use MMC_CLKGATEUlf Hansson2013-10-311-1/+0Star
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | As a first step in removing code for MMC_CLKGATE, MIPS db1235 defconfig which is the only current user, shall move away from this option. The mmc host drivers au1xmmc and jz4740_mmc, which are used on MIPS don't support clock gating through MMC_CLKGATE, thus removing the config option will have no effect on power save - clock gating wise. Cc: Ralf Baechle <ralf@linux-mips.org> Cc: linux-mips@linux-mips.org Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org> Acked-by: Ralf Baechle <ralf@linux-mips.org> Signed-off-by: Chris Ball <cjb@laptop.org>
| * mmc: core: Remove deprecated mmc_suspend|resume_host APIsUlf Hansson2013-10-312-25/+0Star
| | | | | | | | | | | | | | | | The are no more users of the deprecated mmc_suspend|resume_host API, so let's remove it. Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org> Signed-off-by: Chris Ball <cjb@laptop.org>
| * mmc: mmci: Move away from using deprecated APIsUlf Hansson2013-10-311-13/+4Star
| | | | | | | | | | | | | | | | | | | | | | | | Suspend and resume of cards are being handled from the protocol layer and consequently the mmc_suspend|resume_host APIs are deprecated. This means we can simplify the suspend|resume callbacks by removing the use of the deprecated APIs. Cc: Russell King <linux@arm.linux.org.uk> Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org> Signed-off-by: Chris Ball <cjb@laptop.org>
| * mmc: via-sdmmc: Move away from using deprecated APIsUlf Hansson2013-10-311-6/+1Star
| | | | | | | | | | | | | | | | | | | | | | | | | | Suspend and resume of cards are being handled from the protocol layer and consequently the mmc_suspend|resume_host APIs are deprecated. This means we can simplify the suspend|resume callbacks by removing the use of the deprecated APIs. Cc: Bruce Chang <brucechang@via.com.tw> Cc: Harald Welte <HaraldWelte@viatech.com> Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org> Signed-off-by: Chris Ball <cjb@laptop.org>
| * mmc: tmio: Move away from using deprecated APIsUlf Hansson2013-10-311-6/+3Star
| | | | | | | | | | | | | | | | | | | | | | | | | | Suspend and resume of cards are being handled from the protocol layer and consequently the mmc_suspend|resume_host APIs are deprecated. This means we can simplify the suspend|resume callbacks by removing the use of the deprecated APIs. Cc: Guennadi Liakhovetski <g.liakhovetski@gmx.de> Cc: Ian Molton <ian@mnementh.co.uk> Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org> Signed-off-by: Chris Ball <cjb@laptop.org>
| * mmc: sh_mmcif: Move away from using deprecated APIsUlf Hansson2013-10-311-7/+3Star
| | | | | | | | | | | | | | | | | | | | | | | | Suspend and resume of cards are being handled from the protocol layer and consequently the mmc_suspend|resume_host APIs are deprecated. This means we can simplify the suspend|resume callbacks by removing the use of the deprecated APIs. Cc: Guennadi Liakhovetski <g.liakhovetski@gmx.de> Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org> Signed-off-by: Chris Ball <cjb@laptop.org>
| * mmc: sdricoh_cs: Move away from using deprecated APIsUlf Hansson2013-10-311-3/+0Star
| | | | | | | | | | | | | | | | | | | | | | | | | | Suspend and resume of cards are being handled from the protocol layer and consequently the mmc_suspend|resume_host APIs are deprecated. This means we can simplify the suspend|resume callbacks by removing the use of the deprecated APIs. Cc: Sascha Sommer <saschasommer@freenet.de> Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org> Acked-by: Sascha Sommer <saschasommer@freenet.de> Signed-off-by: Chris Ball <cjb@laptop.org>
| * mmc: rtsx: Remove redundant suspend and resume callbacksUlf Hansson2013-10-311-33/+0Star
| | | | | | | | | | | | | | | | | | | | | | | | | | Suspend and resume of cards are handled by the protocol layer and consequently the mmc_suspend|resume_host APIs are marked as deprecated. While moving away from using the deprecated APIs, there are nothing left to be done for the suspend and resume callbacks, so remove them. Cc: Wei WANG <wei_wang@realsil.com.cn> Cc: Samuel Ortiz <sameo@linux.intel.com> Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org> Signed-off-by: Chris Ball <cjb@laptop.org>
| * mmc: wbsd: Move away from using deprecated APIsUlf Hansson2013-10-311-28/+5Star
| | | | | | | | | | | | | | | | | | | | | | | | Suspend and resume of cards are being handled from the protocol layer and consequently the mmc_suspend|resume_host APIs are deprecated. This means we can simplify the suspend|resume callbacks by removing the use of the deprecated APIs. Cc: Pierre Ossman <pierre@ossman.eu> Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org> Signed-off-by: Chris Ball <cjb@laptop.org>
| * mmc: pxamci: Remove redundant suspend and resume callbacksUlf Hansson2013-10-311-32/+0Star
| | | | | | | | | | | | | | | | | | | | | | Suspend and resume of cards are handled by the protocol layer and consequently the mmc_suspend|resume_host APIs are marked as deprecated. While moving away from using the deprecated APIs, there are nothing left to be done for the suspend and resume callbacks, so remove them. Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org> Signed-off-by: Chris Ball <cjb@laptop.org>
| * mmc: s3cmci: Remove redundant suspend and resume callbacksUlf Hansson2013-10-311-29/+0Star
| | | | | | | | | | | | | | | | | | | | | | | | | | Suspend and resume of cards are handled by the protocol layer and consequently the mmc_suspend|resume_host APIs are marked as deprecated. While moving away from using the deprecated APIs, there are nothing left to be done for the suspend and resume callbacks, so remove them. Cc: Ben Dooks <ben-linux@fluff.org> Cc: linux-arm-kernel@lists.infradead.org Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org> Signed-off-by: Chris Ball <cjb@laptop.org>
| * mmc: wmt-sdmmc: Move away from using deprecated APIsUlf Hansson2013-10-311-17/+10Star
| | | | | | | | | | | | | | | | | | | | | | | | | | Suspend and resume of cards are being handled from the protocol layer and consequently the mmc_suspend|resume_host APIs are deprecated. This means we can simplify the suspend|resume callbacks by removing the use of the deprecated APIs. Cc: Tony Prisk <linux@prisktech.co.nz> Cc: linux-arm-kernel@lists.infradead.org Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org> Signed-off-by: Chris Ball <cjb@laptop.org>
| * mmc: mxcmmc: Move away from using deprecated APIsUlf Hansson2013-10-311-10/+2Star
| | | | | | | | | | | | | | | | | | | | | | | | | | | | Suspend and resume of cards are being handled from the protocol layer and consequently the mmc_suspend|resume_host APIs are deprecated. This means we can simplify the suspend|resume callbacks by removing the use of the deprecated APIs. Cc: Sascha Hauer <s.hauer@pengutronix.de> Cc: Anatolij Gustschin <agust@denx.de> Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org> Acked-by: Sascha Hauer <s.hauer@pengutronix.de> Signed-off-by: Chris Ball <cjb@laptop.org>
| * mmc: mxs-mmc: Move away from using deprecated APIsUlf Hansson2013-10-311-10/+2Star
| | | | | | | | | | | | | | | | | | | | | | | | | | | | Suspend and resume of cards are being handled from the protocol layer and consequently the mmc_suspend|resume_host APIs are deprecated. This means we can simplify the suspend|resume callbacks by removing the use of the deprecated APIs. Cc: Shawn Guo <shawn.guo@linaro.org> Cc: Fabio Estevam <fabio.estevam@freescale.com> Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org> Acked-by: Shawn Guo <shawn.guo@linaro.org> Signed-off-by: Chris Ball <cjb@laptop.org>
| * mmc: omap: Remove redundant suspend and resume callbacksUlf Hansson2013-10-312-86/+3Star
| | | | | | | | | | | | | | | | | | | | | | | | | | Suspend and resume of cards are handled by the protocol layer and consequently the mmc_suspend|resume_host APIs are marked as deprecated. While moving away from using the deprecated APIs, there are nothing left to be done for the suspend and resume callbacks, so remove them. Cc: Jarkko Lavinen <jarkko.lavinen@nokia.com> Cc: linux-omap@vger.kernel.org Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org> Signed-off-by: Chris Ball <cjb@laptop.org>
| * mmc: tifm_sd: Move away from using deprecated APIsUlf Hansson2013-10-311-3/+1Star
| | | | | | | | | | | | | | | | | | | | | | | | Suspend and resume of cards are being handled from the protocol layer and consequently the mmc_suspend|resume_host APIs are deprecated. This means we can simplify the suspend|resume callbacks by removing the use of the deprecated APIs. Cc: Alex Dubov <oakad@yahoo.com> Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org> Signed-off-by: Chris Ball <cjb@laptop.org>
| * mmc: sdhci: Move away from using deprecated APIsUlf Hansson2013-10-311-18/+2Star
| | | | | | | | | | | | | | | | | | | | | | Suspend and resume of cards are being handled from the protocol layer and consequently the mmc_suspend|resume_host APIs are deprecated. This means we can simplify the suspend|resume callbacks by removing the use of the deprecated APIs. Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org> Signed-off-by: Chris Ball <cjb@laptop.org>
| * mmc: vub300: Move away from using deprecated APIsUlf Hansson2013-10-311-16/+2Star
| | | | | | | | | | | | | | | | | | | | | | | | | | | | Suspend and resume of cards are handled by the protocol layer and consequently the mmc_suspend|resume_host APIs are marked as deprecated. This means we can simplify the suspend|resume callbacks by removing the use of the deprecated APIs. Cc: Tony Olech <tony.olech@elandigitalsystems.com> Cc: linux-usb@vger.kernel.org Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org> Cc: Alan Stern <stern@rowland.harvard.edu> Signed-off-by: Chris Ball <cjb@laptop.org>
| * mmc: mvsdio: Remove redundant suspend and resume callbacksUlf Hansson2013-10-311-29/+0Star
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Suspend and resume of cards are handled by the protocol layer and consequently the mmc_suspend|resume_host APIs are marked as deprecated. While moving away from using the deprecated APIs, there are nothing left to be done for the suspend and resume callbacks, so remove them. Cc: Nicolas Pitre <nico@fluxnic.net> Cc: Thomas Petazzoni <thomas.petazzoni@free-electrons.com> Cc: Jason Cooper <jason@lakedaemon.net> Cc: Andrew Lunn <andrew@lunn.ch> Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org> Signed-off-by: Chris Ball <cjb@laptop.org>
| * mmc: msm_sdcc: Move away from using deprecated APIsUlf Hansson2013-10-311-25/+2Star
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Suspend and resume of cards are being handled from the protocol layer and consequently the mmc_suspend|resume_host APIs are deprecated. This means we can simplify the suspend|resume callbacks by removing the use of the deprecated APIs. Additionally, remove dead code which also used the deprecated APIs. Cc: David Brown <davidb@codeaurora.org> Cc: Daniel Walker <dwalker@fifo99.com> Cc: Bryan Huntsman <bryanh@codeaurora.org> Cc: linux-arm-msm@vger.kernel.org Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org> Acked-by: David Brown <davidb@codeaurora.org> Signed-off-by: Chris Ball <cjb@laptop.org>
| * mmc: jz4740: Move away from using deprecated APIsUlf Hansson2013-10-311-4/+0Star
| | | | | | | | | | | | | | | | | | | | | | | | Suspend and resume of cards are being handled from the protocol layer and consequently the mmc_suspend|resume_host APIs are deprecated. This means we can simplify the suspend|resume callbacks by removing the use of the deprecated APIs. Cc: Lars-Peter Clausen <lars@metafoo.de> Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org> Signed-off-by: Chris Ball <cjb@laptop.org>
| * mmc: dw_mmc: Move away from using deprecated APIsUlf Hansson2013-10-311-21/+0Star
| | | | | | | | | | | | | | | | | | | | | | | | | | Suspend and resume of cards are being handled from the protocol layer and consequently the mmc_suspend|resume_host APIs are deprecated. This means we can simplify the suspend|resume callbacks by removing the use of the deprecated APIs. Cc: Seungwon Jeon <tgih.jun@samsung.com> Cc: Jaehoon Chung <jh80.chung@samsung.com> Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org> Signed-off-by: Chris Ball <cjb@laptop.org>
| * mmc: davinci_mmc: Move away from using deprecated APIsUlf Hansson2013-10-311-21/+5Star
| | | | | | | | | | | | | | | | | | | | | | | | | | | | Suspend and resume of cards are being handled from the protocol layer and consequently the mmc_suspend|resume_host APIs are deprecated. This means we can simplify the suspend|resume callbacks by removing the use of the deprecated APIs. Cc: Sekhar Nori <nsekhar@ti.com> Cc: Manjunathappa, Prakash <prakash.pm@ti.com> Cc: davinci-linux-open-source@linux.davincidsp.com Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org> Signed-off-by: Chris Ball <cjb@laptop.org>
| * mmc: cb710: Move away from using deprecated APIsUlf Hansson2013-10-311-9/+1Star
| | | | | | | | | | | | | | | | | | | | | | | | | | Suspend and resume of cards are being handled from the protocol layer and consequently the mmc_suspend|resume_host APIs are deprecated. This means we can simplify the suspend|resume callbacks by removing the use of the deprecated APIs. Cc: Michał Mirosław <mirq-linux@rere.qmqm.pl> Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org> Acked-by: Michał Mirosław <mirq-linux@rere.qmqm.pl> Signed-off-by: Chris Ball <cjb@laptop.org>
| * mmc: bfin_sdh: Move away from using deprecated APIsUlf Hansson2013-10-311-11/+1Star
| | | | | | | | | | | | | | | | | | | | | | | | | | | | Suspend and resume of cards are being handled from the protocol layer and consequently the mmc_suspend|resume_host APIs are deprecated. This means we can simplify the suspend|resume callbacks by removing the use of the deprecated APIs. Cc: Sonic Zhang <sonic.zhang@analog.com> Cc: uclinux-dist-devel@blackfin.uclinux.org Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org> Acked-by: Sonic Zhang <sonic.zhang@analog.com> Signed-off-by: Chris Ball <cjb@laptop.org>
| * mmc: au1xmmc: Move away from using deprecated APIsUlf Hansson2013-10-311-6/+1Star
| | | | | | | | | | | | | | | | | | | | | | | | Suspend and resume of cards are being handled from the protocol layer and consequently the mmc_suspend|resume_host APIs are deprecated. This means we can simplify the suspend|resume callbacks by removing the use of the deprecated APIs. Cc: Manuel Lauss <manuel.lauss@googlemail.com> Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org> Signed-off-by: Chris Ball <cjb@laptop.org>
| * mmc: atmel-mci: Remove redundant suspend and resume callbacksUlf Hansson2013-10-311-61/+0Star
| | | | | | | | | | | | | | | | | | | | | | | | | | Suspend and resume of cards are handled by the protocol layer and consequently the mmc_suspend|resume_host APIs are marked as deprecated. While moving away from using the deprecated APIs, there are nothing left to be done for the suspend and resume callbacks, so remove them. Cc: Ludovic Desroches <ludovic.desroches@atmel.com> Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org> Acked-by: Ludovic Desroches <ludovic.desroches@atmel.com> Signed-off-by: Chris Ball <cjb@laptop.org>
| * mmc: core: Signal wakeup event at card insert/removalUlf Hansson2013-10-311-12/+27
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | We want to give user space provision to fully consume a card insert/remove event, when the event was caused by a wakeup irq. By signaling the wakeup event for a time of 5 s for devices configured as wakeup capable, we likely will be prevent a sleep long enough to let user space consume the event. To enable this feature, host drivers must thus configure their devices as wakeup capable. This is a reworked implementation of the old wakelocks for the mmc subsystem, originally authored by Colin Cross and San Mehat for the Android kernel. Zoran Markovic shall also be given cred for recently re-trying to upstream this feature. Cc: San Mehat <san@google.com> Cc: Colin Cross <ccross@android.com> Cc: John Stultz <john.stultz@linaro.org> Cc: Zoran Markovic <zoran.markovic@linaro.org> Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org> Reviewed-by: Zoran Markovic <zoran.markovic@linaro.org> Signed-off-by: Chris Ball <cjb@laptop.org>
| * mmc: core: Collect common code for card ocr validationUlf Hansson2013-10-314-40/+10Star
| | | | | | | | | | | | | | | | | | 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: Ulf Hansson <ulf.hansson@linaro.org> Signed-off-by: Chris Ball <cjb@laptop.org>
| * mmc: core: Prevent violation of specs while initializing cardsUlf Hansson2013-10-314-37/+13Star
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 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: Ulf Hansson <ulf.hansson@linaro.org> Signed-off-by: Chris Ball <cjb@laptop.org>
| * mmc: core: Move cached value of the negotiated ocr mask to card structUlf Hansson2013-10-316-35/+41
| | | | | | | | | | | | | | | | | | 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: Ulf Hansson <ulf.hansson@linaro.org> Signed-off-by: Chris Ball <cjb@laptop.org>
| * mmc: core: Cleanup code for setting ocr mask for SDIOUlf Hansson2013-10-311-16/+10Star
| | | | | | | | | | | | | | | | | | At several places in mmc_sdio_init_card function the cached mask in host->ocr were being updated. To simplify code, we make use of an local ocr parameter instead. Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org> Signed-off-by: Chris Ball <cjb@laptop.org>
| * mmc: core: Remove unnecessary retry mechanism at SDIO attachUlf Hansson2013-10-311-11/+3Star
| | | | | | | | | | | | | | | | | | The retry and fallback mechanism when failing to switch to 1.8V signaling voltage is handled by the SDIO card init function. Thus we can remove the duplicated old code from the attach function. Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org> Signed-off-by: Chris Ball <cjb@laptop.org>
| * mmc: core: Let mmc_set_signal_voltage take ocr as parameterUlf Hansson2013-10-314-5/+7
| | | | | | | | | | | | | | | | This is yet another step of restructure code to be able to fixup the setup of the negotiated ocr mask. Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org> Signed-off-by: Chris Ball <cjb@laptop.org>
| * mmc: core: Let mmc_power_up|cycle take ocr as parameterUlf Hansson2013-10-315-24/+16Star
| | | | | | | | | | | | | | | | 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: Ulf Hansson <ulf.hansson@linaro.org> Signed-off-by: Chris Ball <cjb@laptop.org>
| * mmc: core: Do not poll for busy with status cmd for all switch cmdsUlf Hansson2013-10-314-10/+24
| | | | | | | | | | | | | | | | | | | | | | | | 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: Ulf Hansson <ulf.hansson@linaro.org> Cc: Jaehoon Chung <jh80.chung@samsung.com> Signed-off-by: Chris Ball <cjb@laptop.org>
| * mmc: sdhci-pci: Add SDIO/MMC device ID support for Intel ClovertrailEric Ernst2013-10-311-0/+46
| | | | | | | | | | | | | | | | | | This patch adds intel_mid clovertrail SDIO and eMMC device IDs to the sdhci-pci driver. Signed-off-by: Eric Ernst <eric.ernst@linux.intel.com> Signed-off-by: David Cohen <david.a.cohen@linux.intel.com> Signed-off-by: Chris Ball <cjb@laptop.org>
| * mmc: omap_hsmmc: remove unused no_offBalaji T K2013-10-311-7/+0Star
| | | | | | | | | | | | | | With lazy disable gone, no_off is not used any more in omap_hsmmc Signed-off-by: Balaji T K <balajitk@ti.com> Signed-off-by: Chris Ball <cjb@laptop.org>
| * mmc: omap_hsmmc: correct max value of clkdBalaji T K2013-10-311-2/+3
| | | | | | | | | | | | | | | | | | clock divisor can take a max value of 1023. Update code so that card init can be handled at f_min even at higher IP clock frequencies from which clock to the card is derived. Signed-off-by: Balaji T K <balajitk@ti.com> Signed-off-by: Chris Ball <cjb@laptop.org>