aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJon Hunter <jon-hunter@ti.com>2012-09-28 12:34:49 -0400
committerJon Hunter <jon-hunter@ti.com>2012-11-16 11:35:08 -0500
commit40fc3bb56ed125aa22c0a85c816ae0f923519146 (patch)
treefae27dec800c0bd681a625d723dfa14ad9ee6647
parent755ae860f71cb37fbd3cc8da007e0d8de33419f0 (diff)
ARM: OMAP: Add platform data header for DMTIMERs
Move definition of dmtimer platform data structure in to its own header under <linux/platform_data>. Signed-off-by: Jon Hunter <jon-hunter@ti.com>
-rw-r--r--arch/arm/mach-omap1/timer.c1
-rw-r--r--arch/arm/mach-omap2/timer.c2
-rw-r--r--arch/arm/plat-omap/dmtimer.c2
-rw-r--r--arch/arm/plat-omap/include/plat/dmtimer.h8
-rw-r--r--include/linux/platform_data/dmtimer-omap.h31
5 files changed, 36 insertions, 8 deletions
diff --git a/arch/arm/mach-omap1/timer.c b/arch/arm/mach-omap1/timer.c
index cdeb9d3ef640..bde7a35e5000 100644
--- a/arch/arm/mach-omap1/timer.c
+++ b/arch/arm/mach-omap1/timer.c
@@ -25,6 +25,7 @@
25#include <linux/err.h> 25#include <linux/err.h>
26#include <linux/slab.h> 26#include <linux/slab.h>
27#include <linux/platform_device.h> 27#include <linux/platform_device.h>
28#include <linux/platform_data/dmtimer-omap.h>
28 29
29#include <mach/irqs.h> 30#include <mach/irqs.h>
30 31
diff --git a/arch/arm/mach-omap2/timer.c b/arch/arm/mach-omap2/timer.c
index 1a662dfdda11..4daa8b41c522 100644
--- a/arch/arm/mach-omap2/timer.c
+++ b/arch/arm/mach-omap2/timer.c
@@ -39,6 +39,8 @@
39#include <linux/of.h> 39#include <linux/of.h>
40#include <linux/of_address.h> 40#include <linux/of_address.h>
41#include <linux/of_irq.h> 41#include <linux/of_irq.h>
42#include <linux/platform_device.h>
43#include <linux/platform_data/dmtimer-omap.h>
42 44
43#include <asm/mach/time.h> 45#include <asm/mach/time.h>
44#include <asm/smp_twd.h> 46#include <asm/smp_twd.h>
diff --git a/arch/arm/plat-omap/dmtimer.c b/arch/arm/plat-omap/dmtimer.c
index efe47744b491..89585c293554 100644
--- a/arch/arm/plat-omap/dmtimer.c
+++ b/arch/arm/plat-omap/dmtimer.c
@@ -43,6 +43,8 @@
43#include <linux/pm_runtime.h> 43#include <linux/pm_runtime.h>
44#include <linux/of.h> 44#include <linux/of.h>
45#include <linux/of_device.h> 45#include <linux/of_device.h>
46#include <linux/platform_device.h>
47#include <linux/platform_data/dmtimer-omap.h>
46 48
47#include <plat/dmtimer.h> 49#include <plat/dmtimer.h>
48 50
diff --git a/arch/arm/plat-omap/include/plat/dmtimer.h b/arch/arm/plat-omap/include/plat/dmtimer.h
index b3cd91b60a2e..a3fbc48c332e 100644
--- a/arch/arm/plat-omap/include/plat/dmtimer.h
+++ b/arch/arm/plat-omap/include/plat/dmtimer.h
@@ -124,14 +124,6 @@ struct omap_dm_timer {
124 struct list_head node; 124 struct list_head node;
125}; 125};
126 126
127struct dmtimer_platform_data {
128 /* set_timer_src - Only used for OMAP1 devices */
129 int (*set_timer_src)(struct platform_device *pdev, int source);
130 u32 timer_errata;
131 u32 timer_capability;
132 int (*get_context_loss_count)(struct device *);
133};
134
135int omap_dm_timer_reserve_systimer(int id); 127int omap_dm_timer_reserve_systimer(int id);
136struct omap_dm_timer *omap_dm_timer_request(void); 128struct omap_dm_timer *omap_dm_timer_request(void);
137struct omap_dm_timer *omap_dm_timer_request_specific(int timer_id); 129struct omap_dm_timer *omap_dm_timer_request_specific(int timer_id);
diff --git a/include/linux/platform_data/dmtimer-omap.h b/include/linux/platform_data/dmtimer-omap.h
new file mode 100644
index 000000000000..a19b78d826e9
--- /dev/null
+++ b/include/linux/platform_data/dmtimer-omap.h
@@ -0,0 +1,31 @@
1/*
2 * DMTIMER platform data for TI OMAP platforms
3 *
4 * Copyright (C) 2012 Texas Instruments
5 * Author: Jon Hunter <jon-hunter@ti.com>
6 *
7 * This program is free software; you can redistribute it and/or modify it
8 * under the terms of the GNU General Public License version 2 as published by
9 * the Free Software Foundation.
10 *
11 * This program is distributed in the hope that it will be useful, but WITHOUT
12 * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
13 * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for
14 * more details.
15 *
16 * You should have received a copy of the GNU General Public License along with
17 * this program. If not, see <http://www.gnu.org/licenses/>.
18 */
19
20#ifndef __PLATFORM_DATA_DMTIMER_OMAP_H__
21#define __PLATFORM_DATA_DMTIMER_OMAP_H__
22
23struct dmtimer_platform_data {
24 /* set_timer_src - Only used for OMAP1 devices */
25 int (*set_timer_src)(struct platform_device *pdev, int source);
26 u32 timer_capability;
27 u32 timer_errata;
28 int (*get_context_loss_count)(struct device *);
29};
30
31#endif /* __PLATFORM_DATA_DMTIMER_OMAP_H__ */