Skip to content

Commit 1d70f9f

Browse files
maquefelalexandrebelloni
authored andcommitted
rtc: ep93xx: add DT support for Cirrus EP93xx
Add OF ID match table. Reviewed-by: Andy Shevchenko <andy.shevchenko@gmail.com> Signed-off-by: Nikita Shubin <nikita.shubin@maquefel.me> Link: https://lore.kernel.org/r/20230915-ep93xx-v4-14-a1d779dcec10@maquefel.me Signed-off-by: Alexandre Belloni <alexandre.belloni@bootlin.com>
1 parent 207bddd commit 1d70f9f

File tree

1 file changed

+8
-0
lines changed

1 file changed

+8
-0
lines changed

drivers/rtc/rtc-ep93xx.c

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,7 @@
77
*/
88

99
#include <linux/module.h>
10+
#include <linux/mod_devicetable.h>
1011
#include <linux/rtc.h>
1112
#include <linux/platform_device.h>
1213
#include <linux/io.h>
@@ -148,9 +149,16 @@ static int ep93xx_rtc_probe(struct platform_device *pdev)
148149
return devm_rtc_register_device(ep93xx_rtc->rtc);
149150
}
150151

152+
static const struct of_device_id ep93xx_rtc_of_ids[] = {
153+
{ .compatible = "cirrus,ep9301-rtc" },
154+
{ /* sentinel */ }
155+
};
156+
MODULE_DEVICE_TABLE(of, ep93xx_rtc_of_ids);
157+
151158
static struct platform_driver ep93xx_rtc_driver = {
152159
.driver = {
153160
.name = "ep93xx-rtc",
161+
.of_match_table = ep93xx_rtc_of_ids,
154162
},
155163
.probe = ep93xx_rtc_probe,
156164
};

0 commit comments

Comments
 (0)