summaryrefslogtreecommitdiff
path: root/drivers
diff options
context:
space:
mode:
authorRyan Coe <bluemrp9@gmail.com>2015-01-31 18:25:49 -0700
committerpopcornmix <popcornmix@gmail.com>2015-05-18 14:11:36 +0100
commit5d570e3f18378eba9c6748e2068094ec5d232e30 (patch)
tree7f18e8f55a3c1a718dc8a6450f086a06639a7a30 /drivers
parent0d9b3a0bcf132a48ea092776eda597811e3665d9 (diff)
downloadlinux-5d570e3f18378eba9c6748e2068094ec5d232e30.tar.gz
Update ds1307 driver for device-tree support
Signed-off-by: Ryan Coe <bluemrp9@gmail.com>
Diffstat (limited to 'drivers')
-rw-r--r--drivers/rtc/rtc-ds1307.c8
1 files changed, 8 insertions, 0 deletions
diff --git a/drivers/rtc/rtc-ds1307.c b/drivers/rtc/rtc-ds1307.c
index 4ffabb322a9a..c6789a737d60 100644
--- a/drivers/rtc/rtc-ds1307.c
+++ b/drivers/rtc/rtc-ds1307.c
@@ -1242,6 +1242,14 @@ static int ds1307_remove(struct i2c_client *client)
return 0;
}
+#ifdef CONFIG_OF
+static const struct of_device_id ds1307_of_match[] = {
+ { .compatible = "maxim,ds1307" },
+ { }
+};
+MODULE_DEVICE_TABLE(of, ds1307_of_match);
+#endif
+
static struct i2c_driver ds1307_driver = {
.driver = {
.name = "rtc-ds1307",