summaryrefslogtreecommitdiffstats
path: root/arch/arm/mach-s3c64xx/dev-rtc.c
diff options
context:
space:
mode:
authorBen Dooks2010-01-26 03:19:18 +0100
committerBen Dooks2010-02-20 23:32:01 +0100
commit88fc68a280709f3fb9488986ab39eac330d17b6d (patch)
treeb9f9a91f3bd6e735cf611f3cec7438f86fd3e4f7 /arch/arm/mach-s3c64xx/dev-rtc.c
parentARM: S3C64XX: Move IRQ support into mach-s3c64xx (diff)
downloadkernel-qcow2-linux-88fc68a280709f3fb9488986ab39eac330d17b6d.tar.gz
kernel-qcow2-linux-88fc68a280709f3fb9488986ab39eac330d17b6d.tar.xz
kernel-qcow2-linux-88fc68a280709f3fb9488986ab39eac330d17b6d.zip
ARM: S3C64XX: Move device and device setup into mach-s3c64xx
Move the S3C64XX specific device and setup files into mach-s3c64xx as they are unlikely to be used outside of this code. Signed-off-by: Ben Dooks <ben-linux@fluff.org>
Diffstat (limited to 'arch/arm/mach-s3c64xx/dev-rtc.c')
-rw-r--r--arch/arm/mach-s3c64xx/dev-rtc.c43
1 files changed, 43 insertions, 0 deletions
diff --git a/arch/arm/mach-s3c64xx/dev-rtc.c b/arch/arm/mach-s3c64xx/dev-rtc.c
new file mode 100644
index 000000000000..b9e7a05f0129
--- /dev/null
+++ b/arch/arm/mach-s3c64xx/dev-rtc.c
@@ -0,0 +1,43 @@
+/* linux/arch/arm/plat-s3c64xx/dev-rtc.c
+ *
+ * Copyright 2009 by Maurus Cuelenaere <mcuelenaere@gmail.com>
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License version 2 as
+ * published by the Free Software Foundation.
+ */
+
+#include <linux/kernel.h>
+#include <linux/string.h>
+#include <linux/platform_device.h>
+
+#include <mach/irqs.h>
+#include <mach/map.h>
+
+#include <plat/devs.h>
+
+static struct resource s3c_rtc_resource[] = {
+ [0] = {
+ .start = S3C64XX_PA_RTC,
+ .end = S3C64XX_PA_RTC + 0xff,
+ .flags = IORESOURCE_MEM,
+ },
+ [1] = {
+ .start = IRQ_RTC_ALARM,
+ .end = IRQ_RTC_ALARM,
+ .flags = IORESOURCE_IRQ,
+ },
+ [2] = {
+ .start = IRQ_RTC_TIC,
+ .end = IRQ_RTC_TIC,
+ .flags = IORESOURCE_IRQ
+ }
+};
+
+struct platform_device s3c_device_rtc = {
+ .name = "s3c64xx-rtc",
+ .id = -1,
+ .num_resources = ARRAY_SIZE(s3c_rtc_resource),
+ .resource = s3c_rtc_resource,
+};
+EXPORT_SYMBOL(s3c_device_rtc);