aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/mmc/host/sdhci-bcm-kona.c (follow)
AgeCommit message (Collapse)AuthorFilesLines
2019-02-25mmc: sdhci-bcm-kona: Drop unused includesLinus Walleij1-2/+0
The SDHCI BCM Kona driver uses slot GPIO helpers and does not make any use of <linux/gpio.h> or <linux/of_gpio.h> so drop these surplus includes. Cc: Jisheng Zhang <Jisheng.Zhang@synaptics.com> Acked-by: Adrian Hunter <adrian.hunter@intel.com> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org>
2018-05-29mmc: sdhci-*: Don't emit error msg if sdhci_add_host() failsJisheng Zhang1-3/+1
I noticed below error msg with sdhci-pxav3 on some berlin platforms: [.....] sdhci-pxav3 f7ab0000.sdhci failed to add host It is due to getting related vmmc or vqmmc regulator returns -EPROBE_DEFER. It doesn't matter at all but it's confusing. >From another side, if driver probing fails and the error number isn't -EPROBE_DEFER, the core will tell us something as below: [.....] sdhci-pxav3: probe of f7ab0000.sdhci failed with error -EXX So it's not necessary to emit error msg if sdhci_add_host() fails. And some other sdhci host drivers also have this issue, let's fix them together. Signed-off-by: Jisheng Zhang <Jisheng.Zhang@synaptics.com> Acked-by: Adrian Hunter <adrian.hunter@intel.com> Acked-by: Viresh Kumar <viresh.kumar@linaro.org> Acked-by: Patrice Chotard <patrice.chotard@st.com> Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org>
2017-08-30mmc: sdhci-bcm-kona: constify sdhci_pltfm_data and sdhci_ops structuresJulia Lawall1-2/+2
The sdhci_pltfm_data structure is only passed as the second argument of sdhci_pltfm_init, which is const, while the sdhci_ops structure is only stored in the ops field of a sdhci_pltfm_data structure, which is also const. Thus both kinds of structures can be const as well. Done with the help of Coccinelle. Signed-off-by: Julia Lawall <Julia.Lawall@lip6.fr> Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org>
2016-09-26mmc: sdhci-bcm-kona: fix error return code in sdhci_bcm_kona_probe()Wei Yongjun1-2/+4
In clk_set_rate() or clk_prepare_enable() error handling case, the error return code ret is not set, so sdhci_bcm_kona_probe() return 0 in those error cases. Signed-off-by: Wei Yongjun <weiyj.lk@gmail.com> Acked-by: Ray Jui <ray.jui@broadcom.com> Acked-by: Adrian Hunter <adrian.hunter@intel.com> Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org>
2016-07-29mmc: sdhci-pltfm: Drop define for SDHCI_PLTFM_PMOPSUlf Hansson1-1/+1
Due to previous changes this define has no longer a purpose. Instead move the sdhci-pltfm drivers over to use the exported struct sdhci_pltfm_pmops. Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org>
2016-07-25mmc: host: use the defined function to check whether card is removableJaehoon Chung1-3/+3
In linux/mmc/host.h, mmc_card_is_removable() is already defined. It should be maintainted more easier than now. Signed-off-by: Jaehoon Chung <jh80.chung@samsung.com> Reviewed-by: Shawn Lin <shawn.lin@rock-chips.com> Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org>
2015-10-26mmc: sdhci-bcm-kona: fix logic to check for 8-bit data widthJavier Martinez Canillas1-1/+1
The driver prints if the data width is 8-bit but it's using a binary OR instead of a binary AND so it will always report as "is_8bit=Y" regardless of the flags in host->mmc->caps. Signed-off-by: Javier Martinez Canillas <javier@osg.samsung.com> Reviewed-by: Ray Jui <rjui@broadcom.com> Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org>
2015-03-23mmc: sdhci: set the .remove to sdhci_pltfm_unregister()Kevin Hao1-6/+1
In these drivers, the driver specific .remove function just a simple wrapper of function sdhci_pltfm_unregister(). So remove these wrappers and just set .remove to sdhci_pltfm_unregister(). Signed-off-by: Kevin Hao <haokexin@gmail.com> Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org>
2015-03-23mmc: sdhci: disable the clock in sdhci_pltfm_unregister()Kevin Hao1-11/+1
So we can avoid to sprinkle the clk_disable_unprepare() in many drivers. Signed-off-by: Kevin Hao <haokexin@gmail.com> Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org>
2015-03-23mmc: sdhci-bcm-kona: kill the "external_clk" member in driver private structKevin Hao1-33/+13
Actually we can use the "clk" in the struct sdhci_pltfm_host. Also change the "external clock" to "core clock" and kill two redundant private functions in this driver as suggested by Ray Jui. Signed-off-by: Kevin Hao <haokexin@gmail.com> Reviewed-by: Ray Jui <rjui@broadcom.com> Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org>
2015-01-19mmc: sdhci-bcm-kona: Handle error from mmc_of_parse()Ulf Hansson1-1/+3
Since mmc_of_parse() may fail, let's deal with it and thus do proper error handling. Cc: Christian Daudt <bcm@fixthebug.org> Cc: Matt Porter <mporter@linaro.org> Cc: Florian Fainelli <f.fainelli@gmail.com> Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org> Acked-by: Florian Fainelli <f.fainelli@gmail.com>
2014-10-03mmc, sdhci, bcm-kona, LLVMLinux: Remove use of __initconstBehan Webster1-1/+1
The __initconst is in the wrong place, and when moved to the correct place it uncovers an error where the variable is used by non-init data structures. Instead merely make them const and put the const in the right spot. Signed-off-by: Behan Webster <behanw@converseincode.com> Reviewed-by: Mark Charlebois <charlebm@gmail.com> Acked-by: Arnd Bergmann <arnd@arndb.de> Acked-by: Matt Porter <mporter@linaro.org> Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org>
2014-09-09mmc: remove .owner field for drivers using module_platform_driverPeter Griffin1-1/+0
This patch removes the superflous .owner field for drivers which use the module_platform_driver API, as this is overriden in platform_driver_register anyway. Signed-off-by: Peter Griffin <peter.griffin@linaro.org> Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org>
2014-05-22mmc: sdhci: convert sdhci_set_uhs_signaling() into a library functionRussell King1-0/+1
Add sdhci_set_uhs_signaling() and always call the set_uhs_signaling method. This avoids quirks being added into sdhci_set_uhs_signaling(). Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk> Tested-by: Markus Pargmann <mpa@pengutronix.de> Tested-by: Stephen Warren <swarren@nvidia.com> [Ulf Hansson] Resolved conflict Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org> Signed-off-by: Chris Ball <chris@printf.net>
2014-05-22mmc: sdhci: convert sdhci_set_clock() into a library functionRussell King1-0/+1
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk> Tested-by: Markus Pargmann <mpa@pengutronix.de> Tested-by: Stephen Warren <swarren@nvidia.com> Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org> Signed-off-by: Chris Ball <chris@printf.net>
2014-05-22mmc: sdhci: convert reset into a library functionRussell King1-0/+1
Rather than having platform_reset_enter/platform_reset_exit methods, turn the core of the reset handling into a library function which platforms can call at the appropriate moment in their (new) reset method. Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk> Tested-by: Markus Pargmann <mpa@pengutronix.de> Tested-by: Stephen Warren <swarren@nvidia.com> Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org> Signed-off-by: Chris Ball <chris@printf.net>
2014-05-22mmc: sdhci: convert generic bus width setup to library functionRussell King1-0/+1
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk> Tested-by: Markus Pargmann <mpa@pengutronix.de> Tested-by: Stephen Warren <swarren@nvidia.com> Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org> Signed-off-by: Chris Ball <chris@printf.net>
2014-03-04mmc: sdhci-bcm-kona: fix build errors when built-inRussell King1-1/+1
`sdhci_bcm_kona_remove' referenced in section `.data' of drivers/built-in.o: defined in discarded section `.exit.text' of drivers/built-in.o Fixes: 058feb53666f ("mmc: sdhci-bcm-kona: make linker-section warning go away") Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk> Tested-by: Markus Mayer <markus.mayer@linaro.org> Acked-by: Matt Porter <mporter@linaro.org> Cc: <stable@vger.kernel.org> Signed-off-by: Chris Ball <chris@printf.net>
2014-02-24mmc: sdhci-bcm-kona: Add basic use of clocksTim Kryger1-2/+35
Enable the external clock needed by the host controller during the probe and disable it during the remove. Signed-off-by: Tim Kryger <tim.kryger@linaro.org> Reviewed-by: Markus Mayer <markus.mayer@linaro.org> Reviewed-by: Matt Porter <matt.porter@linaro.org> Signed-off-by: Chris Ball <chris@printf.net>
2013-09-25mmc: sdhci-bcm-kona: Use sdhci_pltfm_unregister instead of open codedAxel Lin1-13/+1
This avoid duplicated implementation and also fixes missing iounmap() and release_mem_region() calls in sdhci_bcm_kona_remove(). sdhci_pltfm_init() calls request_mem_region() and ioremap(), thus we need to call the corresponding iounmap() and release_mem_region() calls in sdhci_bcm_kona_remove(). Signed-off-by: Axel Lin <axel.lin@ingics.com> Signed-off-by: Chris Ball <cjb@laptop.org>
2013-08-29Merge tag 'bcm-for-3.12-late-soc' of git://github.com/broadcom/bcm11351 into next/boardsOlof Johansson1-2/+1
From Christian Daudt, late changes for 3.12 broadcom mmc driver. Small trivial changes so I'll take them through arm-soc. * tag 'bcm-for-3.12-late-soc' of git://github.com/broadcom/bcm11351: mmc: sdhci-bcm-kona: Staticize sdhci_bcm_kona_card_event mmc: sdhci-bcm-kona: Remove unneeded version.h inclusion
2013-08-27mmc: sdhci-bcm-kona: Staticize sdhci_bcm_kona_card_eventSachin Kamat1-1/+1
sdhci_bcm_kona_card_event is referenced only in this file. Make it static. Signed-off-by: Sachin Kamat <sachin.kamat@linaro.org> Acked-by: Christian Daudt <csd@broadcom.com>
2013-08-27mmc: sdhci-bcm-kona: Remove unneeded version.h inclusionSachin Kamat1-1/+0
version.h header inclusion is not necessary as detected by versioncheck. Signed-off-by: Sachin Kamat <sachin.kamat@linaro.org> Acked-by: Christian Daudt <csd@broadcom.com>
2013-08-20ARM: DT: binding fixup to align with vendor-prefixes.txt (drivers)Christian Daudt1-1/+2
[ this is a follow-up to this discussion: http://archive.arm.linux.org.uk/lurker/message/20130730.230827.a1ceb12a.en.html ] This patchset renames all uses of "bcm," name bindings to "brcm," as they were done prior to knowing that brcm had already been standardized as Broadcom vendor prefix (in Documentation/devicetree/bindings/vendor-prefixes.txt). This will not cause any churn on devices because none of these bindings have made it into production yet. Signed-off-by: Christian Daudt <csd@broadcom.com> Acked-by: Stephen Warren <swarren@nvidia.com>
2013-08-19ARM: mmc: fix NONREMOVABLE test in sdhci-bcm-konaChristian Daudt1-2/+2
sdhci-bcm-kona driver is incorrectly doing "|" to bit-test NONREMOVABLE. Switch to "&" Signed-off-by: Christian Daudt <csd@broadcom.com> Reviewed-by: Markus Mayer <markus.mayer@linaro.org> Reviewed-by: Matt Porter <matt.porter@linaro.org>
2013-08-19mmc: sdhci-bcm-kona: make linker-section warning go awayMarkus Mayer1-4/+4
This change makes the following build warning go away: [...] LINK vmlinux LD vmlinux.o MODPOST vmlinux.o WARNING: modpost: Found 2 section mismatch(es). To see full details build your kernel with: 'make CONFIG_DEBUG_SECTION_MISMATCH=y' Signed-off-by: Markus Mayer <markus.mayer@linaro.org> Reviewed-by: Christian Daudt <csd@broadcom.com> Reviewed-by: Matt Porter <matt.porter@linaro.org>
2013-07-05mmc: bcm281xx SDHCI driverChristian Daudt1-0/+348
Add SDHCI driver for the Broadcom 281xx SoCs. Still missing: - power managemement Signed-off-by: Christian Daudt <csd@broadcom.com> Acked-by: Arnd Bergmann <arnd@arndb.de> Signed-off-by: Chris Ball <cjb@laptop.org>