提交 ded518c6 编写于 作者: V Vladimir Zapolskiy 提交者: Sascha Hauer

imx3: Add rtc platform device support

This patch adds support for build-in RTC device found on
Freescale imx31 and imx35 SoCs.
Signed-off-by: NVladimir Zapolskiy <vzapolskiy@gmail.com>
Cc: Sascha Hauer <s.hauer@pengutronix.de>
Signed-off-by: NSascha Hauer <s.hauer@pengutronix.de>
上级 2ba3abd8
......@@ -588,6 +588,25 @@ struct platform_device imx_wdt_device0 = {
.resource = imx_wdt_resources,
};
static struct resource imx_rtc_resources[] = {
{
.start = MX31_RTC_BASE_ADDR,
.end = MX31_RTC_BASE_ADDR + 0x3fff,
.flags = IORESOURCE_MEM,
},
{
.start = MX31_INT_RTC,
.flags = IORESOURCE_IRQ,
},
};
struct platform_device imx_rtc_device0 = {
.name = "mxc_rtc",
.id = -1,
.num_resources = ARRAY_SIZE(imx_rtc_resources),
.resource = imx_rtc_resources,
};
static int __init mx3_devices_init(void)
{
if (cpu_is_mx31()) {
......
......@@ -27,3 +27,4 @@ extern struct platform_device imx_ssi_device0;
extern struct platform_device imx_ssi_device1;
extern struct platform_device imx_ssi_device1;
extern struct platform_device imx_wdt_device0;
extern struct platform_device imx_rtc_device0;
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册