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.30-2+deb9u2+rpi1~4^2~894 X-Git-Url: https://dgit.raspbian.org/?a=commitdiff_plain;h=60efca1bf22e9d24434d485feb4901d3266a3d45;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",