Skip to content

Commit 3a8e9ca

Browse files
mszyprowstorulf
authored andcommitted
mmc: sdhci-s3c: Fix driver data for Exynos4 SoCs
Support for non-dt based initialization for Exynos SoCs has been removed, so there is no need to keep driver IDs for this case. While touching this, replace odd conditional code for instantiating driver data for Exynos4 SoCs with a simple reference and move that driver data under CONFIG_OF. Signed-off-by: Marek Szyprowski <[email protected]> Acked-by: Krzysztof Kozlowski <[email protected]> Reviewed-by: Sylwester Nawrocki <[email protected]> Signed-off-by: Ulf Hansson <[email protected]>
1 parent 62467bb commit 3a8e9ca

File tree

1 file changed

+5
-13
lines changed

1 file changed

+5
-13
lines changed

drivers/mmc/host/sdhci-s3c.c

Lines changed: 5 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -761,32 +761,24 @@ static const struct dev_pm_ops sdhci_s3c_pmops = {
761761
NULL)
762762
};
763763

764-
#if defined(CONFIG_CPU_EXYNOS4210) || defined(CONFIG_SOC_EXYNOS4212)
765-
static struct sdhci_s3c_drv_data exynos4_sdhci_drv_data = {
766-
.no_divider = true,
767-
};
768-
#define EXYNOS4_SDHCI_DRV_DATA ((kernel_ulong_t)&exynos4_sdhci_drv_data)
769-
#else
770-
#define EXYNOS4_SDHCI_DRV_DATA ((kernel_ulong_t)NULL)
771-
#endif
772-
773764
static const struct platform_device_id sdhci_s3c_driver_ids[] = {
774765
{
775766
.name = "s3c-sdhci",
776767
.driver_data = (kernel_ulong_t)NULL,
777-
}, {
778-
.name = "exynos4-sdhci",
779-
.driver_data = EXYNOS4_SDHCI_DRV_DATA,
780768
},
781769
{ }
782770
};
783771
MODULE_DEVICE_TABLE(platform, sdhci_s3c_driver_ids);
784772

785773
#ifdef CONFIG_OF
774+
static struct sdhci_s3c_drv_data exynos4_sdhci_drv_data = {
775+
.no_divider = true,
776+
};
777+
786778
static const struct of_device_id sdhci_s3c_dt_match[] = {
787779
{ .compatible = "samsung,s3c6410-sdhci", },
788780
{ .compatible = "samsung,exynos4210-sdhci",
789-
.data = (void *)EXYNOS4_SDHCI_DRV_DATA },
781+
.data = &exynos4_sdhci_drv_data },
790782
{},
791783
};
792784
MODULE_DEVICE_TABLE(of, sdhci_s3c_dt_match);

0 commit comments

Comments
 (0)