[RFC RESEND PATCH 3.7.0-rc4 2/4] mmc:exynos: use of_simple_module_id_table macro.

Srinivas KANDAGATLA srinivas.kandagatla at st.com
Sat Nov 17 00:27:50 EST 2012


From: Srinivas Kandagatla <srinivas.kandagatla at st.com>

This patch uses of_simple_module_id_table macro to replace code like:

    static struct of_device_id xxx_of_match[] = {
        { .compatible = "yyy,xxx" },
        { },
    };
    MODULE_DEVICE_TABLE(of, xxx_of_match);

with

	of_simple_module_id_table(xxx_of_match, "yyy,zzz");

Signed-off-by: Srinivas Kandagatla <srinivas.kandagatla at st.com>
---
 drivers/mmc/host/dw_mmc-exynos.c |    7 +------
 1 files changed, 1 insertions(+), 6 deletions(-)

diff --git a/drivers/mmc/host/dw_mmc-exynos.c b/drivers/mmc/host/dw_mmc-exynos.c
index 660bbc5..1e9596a 100644
--- a/drivers/mmc/host/dw_mmc-exynos.c
+++ b/drivers/mmc/host/dw_mmc-exynos.c
@@ -218,12 +218,7 @@ static struct dw_mci_drv_data exynos5250_drv_data = {
 	.setup_bus		= dw_mci_exynos_setup_bus,
 };
 
-static const struct of_device_id dw_mci_exynos_match[] = {
-	{ .compatible = "samsung,exynos5250-dw-mshc",
-			.data = (void *)&exynos5250_drv_data, },
-	{},
-};
-MODULE_DEVICE_TABLE(of, dw_mci_pltfm_match);
+of_simple_module_id_table(dw_mci_pltfm_match, "samsung,exynos5250-dw-mshc");
 
 int dw_mci_exynos_probe(struct platform_device *pdev)
 {
-- 
1.7.0.4



More information about the devicetree-discuss mailing list