diff options
author | Sachin Kamat <sachin.kamat@linaro.org> | 2013-02-21 16:44:28 -0800 |
---|---|---|
committer | Linus Torvalds <torvalds@linux-foundation.org> | 2013-02-21 17:22:27 -0800 |
commit | c8a6046e1e0bb03406e4fc6c0a204ef58a1868e4 (patch) | |
tree | c041260ad34e5b5924c6bc5b09e9042e6df77574 /drivers/rtc/rtc-sa1100.c | |
parent | f32bc70d5f938cfef3e534c9db6d38a3759eac6d (diff) | |
download | linux-stable-c8a6046e1e0bb03406e4fc6c0a204ef58a1868e4.tar.gz linux-stable-c8a6046e1e0bb03406e4fc6c0a204ef58a1868e4.tar.bz2 linux-stable-c8a6046e1e0bb03406e4fc6c0a204ef58a1868e4.zip |
drivers/rtc: use of_match_ptr() macro
This eliminates having an #ifdef returning NULL for the case when OF is
disabled. Maintains consistency in cases where OF is always selected.
Signed-off-by: Sachin Kamat <sachin.kamat@linaro.org>
Cc: Alessandro Zummo <a.zummo@towertech.it>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'drivers/rtc/rtc-sa1100.c')
-rw-r--r-- | drivers/rtc/rtc-sa1100.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/drivers/rtc/rtc-sa1100.c b/drivers/rtc/rtc-sa1100.c index 50a5c4adee48..df9180e80e3a 100644 --- a/drivers/rtc/rtc-sa1100.c +++ b/drivers/rtc/rtc-sa1100.c @@ -349,12 +349,14 @@ static const struct dev_pm_ops sa1100_rtc_pm_ops = { }; #endif +#ifdef CONFIG_OF static struct of_device_id sa1100_rtc_dt_ids[] = { { .compatible = "mrvl,sa1100-rtc", }, { .compatible = "mrvl,mmp-rtc", }, {} }; MODULE_DEVICE_TABLE(of, sa1100_rtc_dt_ids); +#endif static struct platform_driver sa1100_rtc_driver = { .probe = sa1100_rtc_probe, @@ -364,7 +366,7 @@ static struct platform_driver sa1100_rtc_driver = { #ifdef CONFIG_PM .pm = &sa1100_rtc_pm_ops, #endif - .of_match_table = sa1100_rtc_dt_ids, + .of_match_table = of_match_ptr(sa1100_rtc_dt_ids), }, }; |