summaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeFilesLines
* mmc: mmci: Get rid of dead code in mmci_dma_setupPramod Gurav2015-01-281-5/+0
| | | | | | | | | DMA configuration has been removed from function mmci_dma_setup but the local mask variable was not removed. This remains unused hence remove it from the function and operations on it Signed-off-by: Pramod Gurav <pramod.gurav@smartplayin.com> Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org>
* mmc: sdhci-pxav3: fix race between runtime pm and irqJisheng Zhang2015-01-281-10/+5
| | | | | | | | | | | | | | | | | | | | | | | | | | | This patch is to fix a race condition that may cause an unhandled irq, which results in big sdhci interrupt numbers and endless "mmc1: got irq while runtime suspended" msgs before v3.15. Consider following scenario: CPU0 CPU1 sdhci_pxav3_runtime_suspend() spin_lock_irqsave(&host->lock, flags); sdhci_irq() spining on the &host->lock host->runtime_suspended = true; spin_unlock_irqrestore(&host->lock, flags); get the &host->lock runtime_suspended is true now return IRQ_NONE; Fix this race by using the core sdhci.c supplied sdhci_runtime_suspend_host() in runtime suspend hook which will disable card interrupts. We also use the sdhci_runtime_resume_host() in the runtime resume hook accordingly. Signed-off-by: Jisheng Zhang <jszhang@marvell.com> Cc: <stable@vger.kernel.org> # v3.9+ Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org>
* mmc: block: Remove unnecessary temporary variableTobias Klauser2015-01-281-3/+1
| | | | | | | | Directly return the result of mmc_blk_alloc_req() instead of assigning and returning the variable md. Signed-off-by: Tobias Klauser <tklauser@distanz.ch> Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org>
* mmc: pwrseq_simple: Add support for a reset GPIO pinUlf Hansson2015-01-281-0/+38
| | | | | | | | | | | | | | | | | The need for reset GPIOs has several times been pointed out from erlier posted patchsets. Especially some WLAN chips which are attached to an SDIO interface may use a GPIO reset. The reset GPIO is asserted at initialization and prior we start the power up procedure. The GPIO will be de-asserted right after the power has been provided to the card, from the ->post_power_on() callback. Note, the reset GPIO is optional. Thus we don't return an error even if we can't find a GPIO for the consumer. Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org> Tested-by: Javier Martinez Canillas <javier.martinez@collabora.co.uk> Reviewed-by: Javier Martinez Canillas <javier.martinez@collabora.co.uk>
* mmc: pwrseq: Initial support for the simple MMC power sequence providerUlf Hansson2015-01-284-2/+111
| | | | | | | | | | | | | | | | | | To add the core part for the MMC power sequence, let's start by adding initial support for the simple MMC power sequence provider. In this initial step, the MMC power sequence node are fetched and the compatible string for the simple MMC power sequence provider are verified. At this point we don't parse the node for any properties, but instead that will be handled from following patches. Since there are no properties supported yet, let's just implement the ->alloc() and the ->free() callbacks. Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org> Tested-by: Javier Martinez Canillas <javier.martinez@collabora.co.uk> Reviewed-by: Javier Martinez Canillas <javier.martinez@collabora.co.uk>
* mmc: pwrseq: Document DT bindings for the simple MMC power sequenceUlf Hansson2015-01-282-0/+34
| | | | | | | | | | | | | | | | | | | | | | To support SOCs which specifies specific MMC power sequences, document some MMC DT bindings to be able to describe these hardwares. Let's also document bindings for a simple MMC power sequence provider, which purpose is to support a set of common properties between various SOCs. In this initial step, let's also document a top level description of the MMC power sequence and describe the compatible string used for the simple MMC power sequence provider. The simple MMC power sequence provider will initially support a reset GPIO. From several earlier posted patches, it's clear that such hardware exists. Especially some WLAN chips which are attached to an SDIO interface may use a GPIO reset. Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org> Tested-by: Javier Martinez Canillas <javier.martinez@collabora.co.uk> Reviewed-by: Javier Martinez Canillas <javier.martinez@collabora.co.uk>
* mmc: core: Initial support for MMC power sequencesUlf Hansson2015-01-286-2/+103
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | System on chip designs may specify a specific MMC power sequence. To successfully detect an (e)MMC/SD/SDIO card, that power sequence must be followed while initializing the card. To be able to handle these SOC specific power sequences, let's add a MMC power sequence interface. It provides the following functions to help the mmc core to deal with these power sequences. mmc_pwrseq_alloc() - Invoked from mmc_of_parse(), to initialize data. mmc_pwrseq_pre_power_on()- Invoked in the beginning of mmc_power_up(). mmc_pwrseq_post_power_on()- Invoked at the end in mmc_power_up(). mmc_pwrseq_power_off()- Invoked from mmc_power_off(). mmc_pwrseq_free() - Invoked from mmc_free_host(), to free data. Each MMC power sequence provider will be responsible to implement a set of callbacks. These callbacks mirrors the functions above. This patch adds the skeleton, following patches will extend the core of the MMC power sequence and add support for a specific simple MMC power sequence. Do note, since the mmc_pwrseq_alloc() is invoked from mmc_of_parse(), host drivers needs to make use of this API to enable the support for MMC power sequences. Moreover the MMC power sequence support depends on CONFIG_OF. Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org> Tested-by: Javier Martinez Canillas <javier.martinez@collabora.co.uk> Reviewed-by: Javier Martinez Canillas <javier.martinez@collabora.co.uk>
* mmc: sdhci-pxav3: Remove checks for optional core clock in error/remove pathJisheng Zhang2015-01-211-4/+2
| | | | | | | | | | | | | | Commit 63589e92c2d9 ("clk: Ignore error and NULL pointers passed to clk_{unprepare, disable}()") allows NULL or error pointer to be passed unconditionally. This patch is to simplify probe error and remove code paths. However, we reserve the core clock checks in runtime suspend/resume code because we want a little smaller latency. Signed-off-by: Jisheng Zhang <jszhang@marvell.com> Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org>
* mmc: rtsx: check sg_count before long data xferMicky Ching2015-01-211-2/+9
| | | | | | | | | Check sg_count before sending long data xfer. Because dma_map_sg() return int, and sg_count may be negative, so using int instead of unsigned. Signed-off-by: Micky Ching <micky_ching@realsil.com.cn> Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org>
* mmc: rtsx: finish request if no card existMicky Ching2015-01-211-2/+7
| | | | | | | | Return error-code directly if no card exist, this can make card remove faster. Signed-off-by: Micky Ching <micky_ching@realsil.com.cn> Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org>
* mmc: sdhci: host: fix odd_ptr_err.cocci warningsWu Fengguang2015-01-211-1/+1
| | | | | | | | | | | | | | | | drivers/mmc/host/sdhci_f_sdh30.c:143:5-11: inconsistent IS_ERR and PTR_ERR, PTR_ERR on line 144 PTR_ERR should access the value just tested by IS_ERR Semantic patch information: There can be false positives in the patch case, where it is the call IS_ERR that is wrong. Generated by: scripts/coccinelle/tests/odd_ptr_err.cocci CC: Vincent Yang <vincent.yang.fujitsu@gmail.com> Signed-off-by: Fengguang Wu <fengguang.wu@intel.com> Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org>
* mmc: vub300: remove unreachable return value handlingNicholas Mc Guire2015-01-211-3/+1
| | | | | Signed-off-by: Nicholas Mc Guire <der.herr@hofr.at> Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org>
* mmc: block: fix format string warningAsaf Vertz2015-01-211-1/+1
| | | | | | | | | Fixed the following warning (reported by cppcheck): [drivers/mmc/card/block.c:2149]: (warning) %d in format string (no. 1) requires 'int' but the argument type is 'unsigned int'. Signed-off-by: Asaf Vertz <asaf.vertz@tandemg.com> Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org>
* Merge branch 'tmio' into nextUlf Hansson2015-01-207-151/+166
|\
| * mmc: tmio: remove TMIO_MMC_HAVE_CTL_DMA_REG flagKuninori Morimoto2015-01-203-13/+0
| | | | | | | | | | | | | | | | | | | | tmio_mmc_host has .enable_dma callback now. We don't need TMIO_MMC_HAVE_CTL_DMA_REG anymore. Let's remove it Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com> Acked-by: Lee Jones <lee.jones@linaro.org> Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org>
| * mmc: sh_mobile_sdhi: enable 32bit DMA accessKuninori Morimoto2015-01-201-9/+33
| | | | | | | | | | | | | | | | Now, sh_mobile_sdhi can use 32bit DMA access in R-Cer Gen2. Let's use it. Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com> Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org>
| * mmc: sh_mobile_sdhi: use .enable_dmaKuninori Morimoto2015-01-201-0/+6
| | | | | | | | | | | | | | | | tmio_mmc_dma has .enable_dma callback now. let's use it. Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com> Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org>
| * mmc: sh_mobile_sdhi: add new macro for mmc_host to sh_mobile_sdhiKuninori Morimoto2015-01-201-2/+4
| | | | | | | | | | | | | | | | | | getting struct sh_mobile_sdhi from struct mmc_host needs to use complex container_of(). This patch adds new host_to_priv macro to get it easily. Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com> Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org>
| * mmc: sh_mobile_sdhi: tidyup mmc_data->bus_shift for latest SoCKuninori Morimoto2015-01-201-1/+4
| | | | | | | | | | | | | | | | Latest SDHI on Renesas has expand register mapping. update mmc_data->bus_shift for it. Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com> Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org>
| * mmc: sh_mobile_sdhi: remove .init/.cleanupKuninori Morimoto2015-01-202-40/+1
| | | | | | | | | | | | | | | | | | No one is using .init/.cleanup callback function. Let's remove these. sdhi_ops and .cd_wakeup are also removed Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com> Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org>
| * mmc: tmio: enable SoC specific DMA buswidth settingsKuninori Morimoto2015-01-202-2/+8
| | | | | | | | | | | | | | | | | | | | Renesas SDHI which is based on TMIO driver has 2 type SoC. 1st one is used as SH-Mobile series, and 2nd is R-Car series. R-Car series SoC has DMA buswidth setting register which enables 32bit access. This patch adds .dma_buswidth and enables it. Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com> Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org>
| * mmc: tmio: add .enable_dma on tmio_mmc_dmaKuninori Morimoto2015-01-202-0/+5
| | | | | | | | | | | | | | | | Some controllers need DMA special register/setting. This patch adds new .enable_dma callback for it. Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com> Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org>
| * mmc: tmio: tmio_mmc_data has .dma_rx_offsetKuninori Morimoto2015-01-204-3/+3
| | | | | | | | | | | | | | | | | | Current .dma_rx_offset is implemented under tmio_mmc_dma. It goes to tmio_mmc_data by this patch. Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com> Acked-by: Lee Jones <lee.jones@linaro.org> Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org>
| * mmc: tmio: tmio_mmc_data has .alignment_shiftKuninori Morimoto2015-01-204-5/+5
| | | | | | | | | | | | | | | | | | Current .alignment_shift is implemented under tmio_mmc_dma. It goes to tmio_mmc_data by this patch. Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com> Acked-by: Lee Jones <lee.jones@linaro.org> Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org>
| * mmc: tmio: tmio_mmc_host has .bus_shiftKuninori Morimoto2015-01-205-15/+15
| | | | | | | | | | | | | | | | | | Current .bus_shift is implemented under tmio_mmc_data. It goes to tmio_mmc_host by this patch. Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com> Acked-by: Lee Jones <lee.jones@linaro.org> Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org>
| * mmc: tmio: tmio_mmc_host has .multi_io_quirkKuninori Morimoto2015-01-204-7/+5
| | | | | | | | | | | | | | | | | | Current .multi_io_quirk is implemented under tmio_mmc_data. It goes to tmio_mmc_host by this patch. Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com> Acked-by: Lee Jones <lee.jones@linaro.org> Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org>
| * mmc: tmio: tmio_mmc_host has .clk_disableKuninori Morimoto2015-01-204-5/+5
| | | | | | | | | | | | | | | | | | Current .clk_disable is implemented under tmio_mmc_data. It goes to tmio_mmc_host by this patch. Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com> Acked-by: Lee Jones <lee.jones@linaro.org> Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org>
| * mmc: tmio: tmio_mmc_host has .clk_enableKuninori Morimoto2015-01-204-5/+4
| | | | | | | | | | | | | | | | | | Current .clk_enable is implemented under tmio_mmc_data. It goes to tmio_mmc_host by this patch. Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com> Acked-by: Lee Jones <lee.jones@linaro.org> Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org>
| * mmc: tmio: tmio_mmc_host has .write16_hookKuninori Morimoto2015-01-204-6/+5
| | | | | | | | | | | | | | | | | | Current .write16_hook is implemented under tmio_mmc_data. It goes to tmio_mmc_host by this patch. Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com> Acked-by: Lee Jones <lee.jones@linaro.org> Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org>
| * mmc: tmio: tmio_mmc_host has .dmaKuninori Morimoto2015-01-204-26/+24
| | | | | | | | | | | | | | | | | | Current .dma is implemented under tmio_mmc_data. It goes to tmio_mmc_host by this patch. Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com> Acked-by: Lee Jones <lee.jones@linaro.org> Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org>
| * mmc: tmio: add tmio_mmc_host_alloc/free()Kuninori Morimoto2015-01-205-24/+51
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Current tmio_mmc driver is using tmio_mmc_data for driver/platform specific data/callback, and it is needed for tmio_mmc_host_probe() function. Because of this style, include/linux/mfd/tmio.h header has tmio driver/framework specific data which is not needed from platform. This patch adds new tmio_mmc_host_alloc/free() as cleanup preparation. tmio driver specific data/callback will be implemented in tmio_mmc_host, and platform specific data/callback will be implemented in tmio_mmc_data in this cleanup. Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com> Acked-by: Lee Jones <lee.jones@linaro.org> Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org>
* | mmc: sdhci: host: add new f_sdh30Vincent Yang2015-01-204-0/+279
| | | | | | | | | | | | | | | | | | | | This patch adds new host controller driver for Fujitsu SDHCI controller f_sdh30. Signed-off-by: Vincent Yang <Vincent.Yang@tw.fujitsu.com> Signed-off-by: Andy Green <andy.green@linaro.org> Signed-off-by: Tetsuya Takinishi <t.takinishi@jp.fujitsu.com> Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org>
* | mmc: sdhci: add a quirk for single block transactionsVincent Yang2015-01-202-3/+7
| | | | | | | | | | | | | | | | | | | | This patch defines a quirk to disable the block count for single block transactions. It is a preparation and will be used by Fujitsu SDHCI controller f_sdh30 driver. Signed-off-by: Vincent Yang <Vincent.Yang@tw.fujitsu.com> Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org>
* | mmc: sdhci: add a quirk for tuning work aroundVincent Yang2015-01-202-0/+4
| | | | | | | | | | | | | | | | | | | | | | | | This patch defines a quirk for tuning work around for some sdhci host controller. It sets both SDHCI_CTRL_EXEC_TUNING and SDHCI_CTRL_TUNED_CLK for tuning. It is a preparation and will be used by Fujitsu SDHCI controller f_sdh30 driver. Signed-off-by: Vincent Yang <Vincent.Yang@tw.fujitsu.com> Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org>
* | mmc: sdhci: add a voltage switch callback functionVincent Yang2015-01-202-0/+5
| | | | | | | | | | | | | | | | | | | | This patch adds a callback function to do controller-specific actions when switching voltages. It is a preparation and will be used by Fujitsu SDHCI controller f_sdh30 driver. Signed-off-by: Vincent Yang <Vincent.Yang@tw.fujitsu.com> Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org>
* | mmc: dw_mmc: Power on vqmmc in MMC_POWER_ON, not MMC_POWER_UPDoug Anderson2015-01-191-4/+6
| | | | | | | | | | | | | | | | | | | | | | | | | | | | If we power up vqmmc in MMC_POWER_ON then we end up turning it on before mmc_power_up() sets the signal voltage. That's not so great since we might be powering it up at the wrong voltage. Note that this is how Yuvaraj originally coded things up in <https://patchwork.kernel.org/patch/4401231/> but he changed it on my suggestion. Apparently I was wrong. Reported-by: Alexandru M Stan <amstan@chromium.org> Signed-off-by: Doug Anderson <dianders@chromium.org> Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org>
* | mmc: host: sdhci: Added a space before (Mohammad Jamal2015-01-191-1/+1
| | | | | | | | | | | | | | | | This patch solves the coding style issue by adding a space before ( Signed-off-by: Mohammad Jamal <md.jamalmohiuddin@gmail.com> Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org>
* | mmc: sdhci-pxav3: fix pm unbalanced issue in -> remove()Jisheng Zhang2015-01-191-1/+3
| | | | | | | | | | | | | | | | This patch calls pm_runtime_put_noidle() to restore the device's usage counter in the ->remove() implementation. Signed-off-by: Jisheng Zhang <jszhang@marvell.com> Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org>
* | mmc: sdhci-pxav3: fix unbalanced clock issues during probeJisheng Zhang2015-01-191-3/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Commit 0dcaa2499b7d ("sdhci-pxav3: Fix runtime PM initialization") tries to fix one hang issue caused by calling sdhci_add_host() on a suspended device. The fix enables the clock twice, once by clk_prepare_enable() and another by pm_runtime_get_sync(), meaning that the clock will never be gated at runtime PM suspend. I observed the power consumption regression on Marvell BG2Q SoCs. In fact, the fix is not correct. There still be a very small window during which a runtime suspend might somehow occur after pm_runtime_enable() but before pm_runtime_get_sync(). This patch fixes all of the two problems by just incrementing the usage counter before pm_runtime_enable(). It also adjust the order of disabling runtime pm and storing the usage count in the error path to handle clock gating properly. Signed-off-by: Jisheng Zhang <jszhang@marvell.com> Cc: <stable@vger.kernel.org> # v3.11+ Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org>
* | mmc: sdhci: Always init buf_ready_intAdrian Hunter2015-01-191-2/+2
| | | | | | | | | | | | | | | | | | | | | | | | There is no point making the initialization of buf_ready_int conditional on host version. Simplify by just doing it always. Note that the other conditional initializations will be removed when the new way of doing re-tuning is taken into use. Signed-off-by: Adrian Hunter <adrian.hunter@intel.com> Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org>
* | mmc: core: Move mmc_card_removed() into mmc_start_request()Adrian Hunter2015-01-191-12/+20
| | | | | | | | | | | | | | | | | | | | Both callers of mmc_start_request() call mmc_card_removed() so move that call into mmc_start_request(). This patch is preparation for adding re-tuning support. Signed-off-by: Adrian Hunter <adrian.hunter@intel.com> Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org>
* | mmc: core: Simplify by adding mmc_execute_tuning()Adrian Hunter2015-01-195-32/+36
| | | | | | | | | | | | | | | | | | | | For each MMC, SD and SDIO there is code that holds the clock, calls ops->execute_tuning, and releases the clock. Simplify the code a bit by providing a separate function to do that. Signed-off-by: Adrian Hunter <adrian.hunter@intel.com> Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org>
* | mmc: omap_hsmmc: use mmc_of_parse to parse common mmc configuration.NeilBrown2015-01-191-25/+8
| | | | | | | | | | | | | | | | This ensures that all standard options are available to hsmmc, In particular, I need cap-power-off-card. Signed-off-by: NeilBrown <neilb@suse.de> Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org>
* | mmc: omap_hsmmc: use slot-gpio library for gpio support.NeilBrown2015-01-191-54/+13
| | | | | | | | | | | | | | | | | | | | | | | | Using the common code removes some code duplication, and makes it easier to switch to using mmc_of_parse() which will remove more duplication. This uses the new mmc_gpio_request_cd_isr to provide a non-standard interrupt service routine for card-detect interrupts. Signed-off-by: NeilBrown <neilb@suse.de> Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org>
* | mmc: slot-gpio: Allow host driver to provide isr for card-detect interruptsNeilBrown2015-01-192-1/+19
| | | | | | | | | | | | | | | | | | | | | | | | | | One of the reasons omap_hsmmc doesn't use the slot-gpio library is that it has some non-standard functionality in the card-detect interrupt service routine. To make it possible for omap_hsmmc (and maybe others) to be converted to use slot-gpio, add 'mmc_gpio_request_cd_isr' which provide an alternate isr to be register by the slot-gpio code. Signed-off-by: NeilBrown <neilb@suse.de> Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org>
* | mmc: sdhci-acpi: fix copy'n'paste typos in the commentsAndy Shevchenko2015-01-191-3/+3
| | | | | | | | | | | | | | Just fix the comments, no functional changes. Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org>
* | mmc: sd: add reset bus_ops callbackJohan Rudholm2015-01-191-0/+7
| | | | | | | | | | | | | | | | | | Enable power cycle and re-initialization of SD cards via the reset bus_ops. Power cycling a buggy SD card sometimes helps it get back on track. Signed-off-by: Johan Rudholm <johanru@axis.com> Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org>
* | mmc: core: refactor the hw_reset routinesJohan Rudholm2015-01-193-34/+51
| | | | | | | | | | | | | | | | | | Move the (e)MMC specific hw_reset code from core.c into mmc.c. Call the code from the new bus_ops member "reset". This also allows for adding a SD card specific reset procedure. Signed-off-by: Johan Rudholm <johanru@axis.com> Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org>
* | mmc: core: always check status after resetJohan Rudholm2015-01-193-31/+12
| | | | | | | | | | | | | | | | | | Always check if the card is alive after a successful reset. This allows us to remove mmc_hw_reset_check(), leaving mmc_hw_reset() as the only card reset interface. Signed-off-by: Johan Rudholm <johanru@axis.com> Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org>
* | mmc: Add SDIO function devicetree subnode parsingSascha Hauer2015-01-194-0/+46
| | | | | | | | | | | | | | | | | | | | | | | | | | | | This adds SDIO devicetree subnode parsing to the mmc core. While SDIO devices are runtime probable they sometimes need nonprobable additional information on embedded systems, like an additional gpio interrupt or a clock. This patch makes it possible to supply this information from the devicetree. SDIO drivers will find a pointer to the devicenode in their devices of_node pointer. Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de> [hdegoede@redhat.com: Misc. cleanups] Signed-off-by: Hans de Goede <hdegoede@redhat.com> Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org>
OpenPOWER on IntegriCloud