Skip to content

Commit

Permalink
drivers/rtc/rtc-s3c: use of_match_ptr() macro
Browse files Browse the repository at this point in the history
This eliminates having an #ifdef returning NULL for the case when OF is
disabled.

Signed-off-by: Sachin Kamat <sachin.kamat@linaro.org>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
  • Loading branch information
Sachin Kamat authored and Linus Torvalds committed Dec 18, 2012
1 parent 18c701a commit 04a373f
Showing 1 changed file with 1 addition and 3 deletions.
4 changes: 1 addition & 3 deletions drivers/rtc/rtc-s3c.c
Original file line number Diff line number Diff line change
Expand Up @@ -663,8 +663,6 @@ static const struct of_device_id s3c_rtc_dt_match[] = {
{},
};
MODULE_DEVICE_TABLE(of, s3c_rtc_dt_match);
#else
#define s3c_rtc_dt_match NULL
#endif

static struct platform_device_id s3c_rtc_driver_ids[] = {
Expand Down Expand Up @@ -695,7 +693,7 @@ static struct platform_driver s3c_rtc_driver = {
.driver = {
.name = "s3c-rtc",
.owner = THIS_MODULE,
.of_match_table = s3c_rtc_dt_match,
.of_match_table = of_match_ptr(s3c_rtc_dt_match),
},
};

Expand Down

0 comments on commit 04a373f

Please sign in to comment.