- 13 2月, 2017 40 次提交
-
-
由 Maxime Ripard 提交于
The MMC core assumes that the code will gate the clock when the bus frequency is set to 0, which we've been ignoring so far. Handle that. Signed-off-by: NMaxime Ripard <maxime.ripard@free-electrons.com> Tested-by: NFlorian Vaussard <florian.vaussard@heig-vd.ch> Acked-by: NChen-Yu Tsai <wens@csie.org> Signed-off-by: NUlf Hansson <ulf.hansson@linaro.org>
-
由 Maxime Ripard 提交于
The SD specification documents that the clock frequency should only be changed once gated (Section 3.2.3 - SD Clock Frequency Change Sequence). The current code first modifies the parent clock, gates it and then modifies the internal divider. This means that since the parent clock rate might be changed, the bus clock might be changed as well before it is gated, which breaks the specification. Move the gating before the parent rate modification. Signed-off-by: NMaxime Ripard <maxime.ripard@free-electrons.com> Tested-by: NFlorian Vaussard <florian.vaussard@heig-vd.ch> Acked-by: NChen-Yu Tsai <wens@csie.org> Signed-off-by: NUlf Hansson <ulf.hansson@linaro.org>
-
由 Heiner Kallweit 提交于
Properly reverse everything if mmc_gpio_alloc(host) fails. Signed-off-by: NHeiner Kallweit <hkallweit1@gmail.com> Signed-off-by: NUlf Hansson <ulf.hansson@linaro.org>
-
由 Heiner Kallweit 提交于
ida handling can be simplified by switching to the ida_simple_ functions. Signed-off-by: NHeiner Kallweit <hkallweit1@gmail.com> Signed-off-by: NUlf Hansson <ulf.hansson@linaro.org>
-
由 Ritesh Harjani 提交于
This removes CDC init sequence comments which are not useful anyway. Signed-off-by: NRitesh Harjani <riteshh@codeaurora.org> Acked-by: NAdrian Hunter <adrian.hunter@intel.com> Signed-off-by: NUlf Hansson <ulf.hansson@linaro.org>
-
由 Ritesh Harjani 提交于
platform_execute_tuning should not really exist as it does not do anything useful. So remove this ops and directly plug sdhci_msm_execute_tuning with mmc_host_ops. Also in case of HS400 tuning clear SDHCI_HS400_TUNING flag once HS400 related mode selection is done. Signed-off-by: NRitesh Harjani <riteshh@codeaurora.org> Acked-by: NAdrian Hunter <adrian.hunter@intel.com> Signed-off-by: NUlf Hansson <ulf.hansson@linaro.org>
-
由 Ulf Hansson 提交于
When mmc_of_parse() finds the binding, it sets the mmc cap, MMC_CAP_3_3V_DDR, which informs the core whether eMMC DDR at 3.3V I/O is supported by the mmc host. Signed-off-by: NUlf Hansson <ulf.hansson@linaro.org> Reviewed-by: NShawn Lin <shawn.lin@rock-chips.com> Tested-by: NJan Glauber <jglauber@cavium.com> Tested-by: NStefan Wahren <stefan.wahren@i2se.com>
-
由 Ulf Hansson 提交于
Cc: <devicetree@vger.kernel.org> Cc: Rob Herring <robh@kernel.org> Signed-off-by: NUlf Hansson <ulf.hansson@linaro.org> Reviewed-by: NShawn Lin <shawn.lin@rock-chips.com> Tested-by: NJan Glauber <jglauber@cavium.com> Tested-by: NStefan Wahren <stefan.wahren@i2se.com> Acked-by: NRob Herring <robh@kernel.org>
-
由 Ulf Hansson 提交于
According the JEDEC specification an eMMC card supporting 1.8V vccq in DDR mode should also be capable of 3.3V. However, it's been reported that some mmc hosts supports 3.3V, but not 1.8V. Currently the mmc core implements an error handling when the host fails to set 1.8V for vccq, by falling back to 3.3V. Unfortunate, this seems to be insufficient for some mmc hosts. To enable these to use eMMC DDR mode let's invent a new mmc cap, MMC_CAP_3_3V_DDR, which tells whether they support the eMMC 3.3V DDR mode. In case MMC_CAP_3_3V_DDR is set, but not MMC_CAP_1_8V_DDR, let's change to remain on the 3.3V, as it's the default voltage level for vccq, set by the earlier power up sequence. As this change introduces MMC_CAP_3_3V_DDR, let's take the opportunity to do some re-formatting of the related defines in the header file. Signed-off-by: NUlf Hansson <ulf.hansson@linaro.org> Reviewed-by: NShawn Lin <shawn.lin@rock-chips.com> Tested-by: NJan Glauber <jglauber@cavium.com> Tested-by: NStefan Wahren <stefan.wahren@i2se.com>
-
由 Ulf Hansson 提交于
Earlier the mmc_set_signal_voltage() existed, but since it has been renamed to mmc_set_uhs_voltage(), we can now use that name instead. Signed-off-by: NUlf Hansson <ulf.hansson@linaro.org> Reviewed-by: NShawn Lin <shawn.lin@rock-chips.com> Tested-by: NJan Glauber <jglauber@cavium.com> Tested-by: NStefan Wahren <stefan.wahren@i2se.com>
-
由 Ulf Hansson 提交于
The mmc_set_signal_voltage() function is used for SD/SDIO when switching to 1.8V for UHS mode. To clarify this let's do the following changes. - We are always providing MMC_SIGNAL_VOLTAGE_180 as the signal_voltage parameter to the function. Then, let's just remove the parameter as it serves no purpose. - Rename the function to mmc_set_uhs_voltage(). Signed-off-by: NUlf Hansson <ulf.hansson@linaro.org> Reviewed-by: NShawn Lin <shawn.lin@rock-chips.com> Tested-by: NJan Glauber <jglauber@cavium.com> Tested-by: NStefan Wahren <stefan.wahren@i2se.com>
-
由 Ulf Hansson 提交于
The mmc_set_signal_voltage() function is used for SD/SDIO when switching to 1.8V for UHS mode. Therefore let's remove the redundant code dealing with MMC_SIGNAL_VOLTAGE_330. Signed-off-by: NUlf Hansson <ulf.hansson@linaro.org> Reviewed-by: NShawn Lin <shawn.lin@rock-chips.com> Tested-by: NJan Glauber <jglauber@cavium.com> Tested-by: NStefan Wahren <stefan.wahren@i2se.com>
-
由 Chris Brandt 提交于
In the case of a single clock source, you don't need names. However, if the controller has 2 clock sources, you need to name them correctly so the driver can find the 2nd one. The 2nd clock is for the internal card detect logic. Signed-off-by: NChris Brandt <chris.brandt@renesas.com> Reviewed-by: NGeert Uytterhoeven <geert+renesas@glider.be> Signed-off-by: NUlf Hansson <ulf.hansson@linaro.org> Reviewed-by: NWolfram Sang <wsa+renesas@sang-engineering.com> Acked-by: NRob Herring <robh@kernel.org>
-
由 Chris Brandt 提交于
Some controllers have 2 clock sources instead of 1. The 2nd clock is for the internal card detect logic and must be enabled/disabled along with the main core clock for proper operation. Signed-off-by: NChris Brandt <chris.brandt@renesas.com> Signed-off-by: NUlf Hansson <ulf.hansson@linaro.org> Reviewed-by: NWolfram Sang <wsa+renesas@sang-engineering.com>
-
由 Kevin Hilman 提交于
Cleanup some debug prints that cause needless noise during normal usage. Signed-off-by: NKevin Hilman <khilman@baylibre.com> Signed-off-by: NUlf Hansson <ulf.hansson@linaro.org>
-
由 Linus Walleij 提交于
The mmc_blk_issue_rq() function is called in exactly one place in queue.c and there the return value is ignored. So the functions called from that function that also meticulously return 0/1 do so for no good reason. Error reporting on the asynchronous requests are done upward to the block layer when the requests are eventually completed or fail, which may happen during the flow of the mmc_blk_issue_* functions directly (for "special commands") or later, when an asynchronous read/write request is completed. The issuing functions do not give rise to errors on their own, and there is nothing to return back to the caller in queue.c. Drop all return values and make the function return void. Signed-off-by: NLinus Walleij <linus.walleij@linaro.org> Signed-off-by: NUlf Hansson <ulf.hansson@linaro.org>
-
由 Linus Walleij 提交于
Recycling the same variable in an x=x+1 fashion may seem clever here but it makes the code terse and hard to follow for humans. Introduce a new_areq and old_areq variable so we see what is going on. Signed-off-by: NLinus Walleij <linus.walleij@linaro.org> Signed-off-by: NUlf Hansson <ulf.hansson@linaro.org>
-
由 Linus Walleij 提交于
Setting rqc to NULL followed by a goto to cmd_abort is just a way to do unconditional abort without starting any new command. Inline the calls to mmc_blk_rw_cmd_abort() and return immediately in those cases. Add some comments to the code flow so it is clear that this is where the asynchronous requests come back in and the result of them gets handled. Signed-off-by: NLinus Walleij <linus.walleij@linaro.org> Signed-off-by: NUlf Hansson <ulf.hansson@linaro.org>
-
由 Linus Walleij 提交于
The code in mmc_blk_issue_rq_rq() aborts a command if the request is not properly aligned on large sectors. As part of the path jumping out, it assigns the local variable mq_rq reflecting a MMC queue request to the current MMC queue request, which is confusing since the variable is not used after this jump. Signed-off-by: NLinus Walleij <linus.walleij@linaro.org> Signed-off-by: NUlf Hansson <ulf.hansson@linaro.org>
-
由 Linus Walleij 提交于
As a step toward breaking apart the very complex function mmc_blk_issue_rw_rq() we break out the code to start a new request. Signed-off-by: NLinus Walleij <linus.walleij@linaro.org> Signed-off-by: NUlf Hansson <ulf.hansson@linaro.org>
-
由 Linus Walleij 提交于
As a first step toward breaking apart the very complex function mmc_blk_issue_rw_rq() we break out the command abort code. This code assumes "ret" is != 0 and then repeatedly hammers blk_end_request() until the request to the block layer to end the request succeeds. Signed-off-by: NLinus Walleij <linus.walleij@linaro.org> Signed-off-by: NUlf Hansson <ulf.hansson@linaro.org>
-
由 Jaehoon Chung 提交于
Use the bitops API instead of shifting directly. Signed-off-by: NJaehoon Chung <jh80.chung@samsung.com> Signed-off-by: NUlf Hansson <ulf.hansson@linaro.org>
-
由 Jaehoon Chung 提交于
Remove the sdhci-s3c-regs.h file. Instead, it located those defined values into sdhci-s3c.c. Signed-off-by: NJaehoon Chung <jh80.chung@samsung.com> Signed-off-by: NUlf Hansson <ulf.hansson@linaro.org>
-
由 Wolfram Sang 提交于
Before enabling SDIO irqs, clear the status bit, so we discard old and stale interrupts. Needed to get two wireless cards working. Use the newly introduced macro in all places. Signed-off-by: NWolfram Sang <wsa+renesas@sang-engineering.com> Signed-off-by: NUlf Hansson <ulf.hansson@linaro.org>
-
由 Wolfram Sang 提交于
QUIRK sounds like there is something wrong, but actually there are just some bits which need to be 1. Rename it to be more clear. Signed-off-by: NWolfram Sang <wsa+renesas@sang-engineering.com> Signed-off-by: NUlf Hansson <ulf.hansson@linaro.org>
-
由 Wolfram Sang 提交于
tmio_mmc_sdio_irq() is not used as a seperate irq handler anymore, so we can make it similar to the other irq helper functions, namely: * only give the host as argument function which is what it really needs * prefix function name with __ Signed-off-by: NWolfram Sang <wsa+renesas@sang-engineering.com> Acked-by: NSimon Horman <horms+renesas@verge.net.au> Signed-off-by: NUlf Hansson <ulf.hansson@linaro.org>
-
由 Matt Ranostay 提交于
Allow power sequencing for the Marvell SD8787 Wifi/BT chip. This can be abstracted to other chipsets if needed in the future. Cc: Tony Lindgren <tony@atomide.com> Cc: Ulf Hansson <ulf.hansson@linaro.org> Signed-off-by: NMatt Ranostay <matt@ranostay.consulting> Signed-off-by: NUlf Hansson <ulf.hansson@linaro.org>
-
由 Matt Ranostay 提交于
Cc: Rob Herring <robh@kernel.org> Cc: devicetree@vger.kernel.org Signed-off-by: NMatt Ranostay <matt@ranostay.consulting> Signed-off-by: NUlf Hansson <ulf.hansson@linaro.org> Acked-by: NRob Herring <robh@kernel.org>
-
由 Wolfram Sang 提交于
Create a helper function to disable clocks and use it in remove(), too. Now, clk_summary in debugfs reports the clocks as disabled and unprepared after unbinding. Signed-off-by: NWolfram Sang <wsa+renesas@sang-engineering.com> Reviewed-by: NGeert Uytterhoeven <geert+renesas@glider.be> Signed-off-by: NUlf Hansson <ulf.hansson@linaro.org>
-
由 Ritesh Harjani 提交于
This provides enhanced_strobe mode feature support in sdhci-msm driver. Signed-off-by: NRitesh Harjani <riteshh@codeaurora.org> Tested-by: NJeremy McNicoll <jeremymc@redhat.com> Acked-by: NAdrian Hunter <adrian.hunter@intel.com> Signed-off-by: NUlf Hansson <ulf.hansson@linaro.org>
-
由 Ritesh Harjani 提交于
During tuning execution for HS400 mode, HW sequence recommends to select MCLK_SEL/2(0x3) in VENDOR_SPEC & sdhc msm clock at GCC to be 400MHZ (nearest supported clk). Add this change in tuning sequence during HS400 tuning. Signed-off-by: NRitesh Harjani <riteshh@codeaurora.org> Tested-by: NJeremy McNicoll <jeremymc@redhat.com> Acked-by: NAdrian Hunter <adrian.hunter@intel.com> Signed-off-by: NUlf Hansson <ulf.hansson@linaro.org>
-
由 Ritesh Harjani 提交于
Clear SDHCI_HS400_TUNING flag after platform_execute_tuning so that platform_execute_tuning may use it if needed. Signed-off-by: NRitesh Harjani <riteshh@codeaurora.org> Tested-by: NJeremy McNicoll <jeremymc@redhat.com> Acked-by: NAdrian Hunter <adrian.hunter@intel.com> Signed-off-by: NUlf Hansson <ulf.hansson@linaro.org>
-
由 Subhash Jadavani 提交于
Program CORE_CSR_CDC_DELAY_CFG for hardware recommended 1.25ns delay. We may see data CRC errors if it's programmed for any other delay value. Signed-off-by: NSubhash Jadavani <subhashj@codeaurora.org> Signed-off-by: NRitesh Harjani <riteshh@codeaurora.org> Tested-by: NJeremy McNicoll <jeremymc@redhat.com> Acked-by: NAdrian Hunter <adrian.hunter@intel.com> Signed-off-by: NUlf Hansson <ulf.hansson@linaro.org>
-
由 Venkat Gopalakrishnan 提交于
The vendor specific func register doesn't get reset when using the software reset register. The various bootloader's could leave this in an unknown state, hence reset this register to it's power on reset value during probe. Signed-off-by: NVenkat Gopalakrishnan <venkatg@codeaurora.org> Signed-off-by: NRitesh Harjani <riteshh@codeaurora.org> Tested-by: NJeremy McNicoll <jeremymc@redhat.com> Acked-by: NAdrian Hunter <adrian.hunter@intel.com> Signed-off-by: NUlf Hansson <ulf.hansson@linaro.org>
-
由 Ritesh Harjani 提交于
Factor out sdhci_msm_hs400 used for DLL calibration in HS400 modes. This function will be needed for enhanced_strobe as well. Signed-off-by: NRitesh Harjani <riteshh@codeaurora.org> Tested-by: NJeremy McNicoll <jeremymc@redhat.com> Acked-by: NAdrian Hunter <adrian.hunter@intel.com> Signed-off-by: NUlf Hansson <ulf.hansson@linaro.org>
-
由 Ritesh Harjani 提交于
Factor out msm_set/get_clock_rate_for_bus_mode for it's later use in changing the tuning sequence for selecting HS400 bus speed mode. Signed-off-by: NRitesh Harjani <riteshh@codeaurora.org> Tested-by: NJeremy McNicoll <jeremymc@redhat.com> Acked-by: NAdrian Hunter <adrian.hunter@intel.com> Signed-off-by: NUlf Hansson <ulf.hansson@linaro.org>
-
由 Ritesh Harjani 提交于
This factors out sdhci_msm_hc_select_mode to later use it during enhanced_strobe mode select. It also further breaks sdhci_msm_hc_select_mode into separate functions for configuring HS400 mode or other modes. Signed-off-by: NRitesh Harjani <riteshh@codeaurora.org> Tested-by: NJeremy McNicoll <jeremymc@redhat.com> Acked-by: NAdrian Hunter <adrian.hunter@intel.com> Signed-off-by: NUlf Hansson <ulf.hansson@linaro.org>
-
由 Stefan Wahren 提交于
This patch implements support for multiblock transfers bounded by SET_BLOCK_COUNT (CMD23) on the MXS MMC host driver. Signed-off-by: NStefan Wahren <stefan.wahren@i2se.com> Signed-off-by: NUlf Hansson <ulf.hansson@linaro.org>
-
由 Alexey Khoroshilov 提交于
host->dma_addr can store a value that is not returned by the DMA API, so it is safer to check if is a valid DMA address indirectly. Signed-off-by: NAlexey Khoroshilov <khoroshilov@ispras.ru> Signed-off-by: NUlf Hansson <ulf.hansson@linaro.org>
-
由 Zhang Rui 提交于
With commit 67bf5156 ("gpio / ACPI: fix returned error from acpi_dev_gpio_irq_get()"), mmc_gpiod_request_cd() returns -EPROBE_DEFER if GPIO is not ready when sdhci-acpi driver is probed, and sdhci-acpi driver should be probed again later in this case. This fixes an order issue when both GPIO and sdhci-acpi drivers are built as modules. CC: stable@vger.kernel.org # v4.9 Bugzilla: https://bugzilla.kernel.org/show_bug.cgi?id=177101Tested-by: NJonas Aaberg <cja@gmx.net> Signed-off-by: NZhang Rui <rui.zhang@intel.com> Acked-by: NAdrian Hunter <adrian.hunter@intel.com> Signed-off-by: NUlf Hansson <ulf.hansson@linaro.org>
-