[RFC PATCH 3.7.0-rc4 4/4] mm:shmobile: use of_simple_module_id_table macro.

Srinivas KANDAGATLA srinivas.kandagatla at st.com
Sat Nov 17 00:22:03 EST 2012


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

This patch uses of_simple_module_id_table macro to replace code like:

#ifdef CONFIG_OF
	static struct of_device_id xxx_of_match[] = {
		{ .compatible = "yyy,zzz" },
		{ },
	};
	MODULE_DEVICE_TABLE(of, xxx_of_match);
#endif

with
	of_simple_module_id_table(xxx_of_match, "yyy,zzz");

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

diff --git a/drivers/mmc/host/sh_mobile_sdhi.c b/drivers/mmc/host/sh_mobile_sdhi.c
index 0bdc146..7535ee4 100644
--- a/drivers/mmc/host/sh_mobile_sdhi.c
+++ b/drivers/mmc/host/sh_mobile_sdhi.c
@@ -316,11 +316,7 @@ static const struct dev_pm_ops tmio_mmc_dev_pm_ops = {
 	.runtime_resume = tmio_mmc_host_runtime_resume,
 };
 
-static const struct of_device_id sh_mobile_sdhi_of_match[] = {
-	{ .compatible = "renesas,shmobile-sdhi" },
-	{ }
-};
-MODULE_DEVICE_TABLE(of, sh_mobile_sdhi_of_match);
+of_simple_module_id_table(sh_mobile_sdhi_of_match, "renesas,shmobile-sdhi");
 
 static struct platform_driver sh_mobile_sdhi_driver = {
 	.driver		= {
-- 
1.7.0.4



More information about the devicetree-discuss mailing list