From: Ryan Coe Date: Sun, 1 Feb 2015 01:25:49 +0000 (-0700) Subject: Update ds1307 driver for device-tree support X-Git-Tag: archive/raspbian/4.9.51-1+rpi1~5^2~459 X-Git-Url: https://dgit.raspbian.org/?a=commitdiff_plain;h=a074f56ec90fbbbd9f22df81e3b9dfd5ce13cd6f;p=linux-4.9.git Update ds1307 driver for device-tree support Signed-off-by: Ryan Coe --- diff --git a/drivers/rtc/rtc-ds1307.c b/drivers/rtc/rtc-ds1307.c index 4e31036ee259..b92044cf03e7 100644 --- a/drivers/rtc/rtc-ds1307.c +++ b/drivers/rtc/rtc-ds1307.c @@ -1675,6 +1675,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",