diff options
-rw-r--r-- | arch/arm/mach-omap2/timer.c | 147 | ||||
-rw-r--r-- | arch/arm/plat-omap/dmtimer.c | 41 |
2 files changed, 146 insertions, 42 deletions
diff --git a/arch/arm/mach-omap2/timer.c b/arch/arm/mach-omap2/timer.c index def9a0ebe42d..92447cd7a41a 100644 --- a/arch/arm/mach-omap2/timer.c +++ b/arch/arm/mach-omap2/timer.c | |||
@@ -37,6 +37,8 @@ | |||
37 | #include <linux/clockchips.h> | 37 | #include <linux/clockchips.h> |
38 | #include <linux/slab.h> | 38 | #include <linux/slab.h> |
39 | #include <linux/of.h> | 39 | #include <linux/of.h> |
40 | #include <linux/of_address.h> | ||
41 | #include <linux/of_irq.h> | ||
40 | 42 | ||
41 | #include <asm/mach/time.h> | 43 | #include <asm/mach/time.h> |
42 | #include <asm/smp_twd.h> | 44 | #include <asm/smp_twd.h> |
@@ -66,11 +68,13 @@ | |||
66 | #define OMAP3_CLKEV_SOURCE OMAP3_32K_SOURCE | 68 | #define OMAP3_CLKEV_SOURCE OMAP3_32K_SOURCE |
67 | #define OMAP4_CLKEV_SOURCE OMAP4_32K_SOURCE | 69 | #define OMAP4_CLKEV_SOURCE OMAP4_32K_SOURCE |
68 | #define OMAP3_SECURE_TIMER 12 | 70 | #define OMAP3_SECURE_TIMER 12 |
71 | #define TIMER_PROP_SECURE "ti,timer-secure" | ||
69 | #else | 72 | #else |
70 | #define OMAP2_CLKEV_SOURCE OMAP2_MPU_SOURCE | 73 | #define OMAP2_CLKEV_SOURCE OMAP2_MPU_SOURCE |
71 | #define OMAP3_CLKEV_SOURCE OMAP3_MPU_SOURCE | 74 | #define OMAP3_CLKEV_SOURCE OMAP3_MPU_SOURCE |
72 | #define OMAP4_CLKEV_SOURCE OMAP4_MPU_SOURCE | 75 | #define OMAP4_CLKEV_SOURCE OMAP4_MPU_SOURCE |
73 | #define OMAP3_SECURE_TIMER 1 | 76 | #define OMAP3_SECURE_TIMER 1 |
77 | #define TIMER_PROP_SECURE "ti,timer-alwon" | ||
74 | #endif | 78 | #endif |
75 | 79 | ||
76 | #define REALTIME_COUNTER_BASE 0x48243200 | 80 | #define REALTIME_COUNTER_BASE 0x48243200 |
@@ -156,6 +160,40 @@ static struct of_device_id omap_timer_match[] __initdata = { | |||
156 | }; | 160 | }; |
157 | 161 | ||
158 | /** | 162 | /** |
163 | * omap_get_timer_dt - get a timer using device-tree | ||
164 | * @match - device-tree match structure for matching a device type | ||
165 | * @property - optional timer property to match | ||
166 | * | ||
167 | * Helper function to get a timer during early boot using device-tree for use | ||
168 | * as kernel system timer. Optionally, the property argument can be used to | ||
169 | * select a timer with a specific property. Once a timer is found then mark | ||
170 | * the timer node in device-tree as disabled, to prevent the kernel from | ||
171 | * registering this timer as a platform device and so no one else can use it. | ||
172 | */ | ||
173 | static struct device_node * __init omap_get_timer_dt(struct of_device_id *match, | ||
174 | const char *property) | ||
175 | { | ||
176 | struct device_node *np; | ||
177 | |||
178 | for_each_matching_node(np, match) { | ||
179 | if (!of_device_is_available(np)) { | ||
180 | of_node_put(np); | ||
181 | continue; | ||
182 | } | ||
183 | |||
184 | if (property && !of_get_property(np, property, NULL)) { | ||
185 | of_node_put(np); | ||
186 | continue; | ||
187 | } | ||
188 | |||
189 | prom_add_property(np, &device_disabled); | ||
190 | return np; | ||
191 | } | ||
192 | |||
193 | return NULL; | ||
194 | } | ||
195 | |||
196 | /** | ||
159 | * omap_dmtimer_init - initialisation function when device tree is used | 197 | * omap_dmtimer_init - initialisation function when device tree is used |
160 | * | 198 | * |
161 | * For secure OMAP3 devices, timers with device type "timer-secure" cannot | 199 | * For secure OMAP3 devices, timers with device type "timer-secure" cannot |
@@ -172,43 +210,74 @@ void __init omap_dmtimer_init(void) | |||
172 | 210 | ||
173 | /* If we are a secure device, remove any secure timer nodes */ | 211 | /* If we are a secure device, remove any secure timer nodes */ |
174 | if ((omap_type() != OMAP2_DEVICE_TYPE_GP)) { | 212 | if ((omap_type() != OMAP2_DEVICE_TYPE_GP)) { |
175 | for_each_matching_node(np, omap_timer_match) { | 213 | np = omap_get_timer_dt(omap_timer_match, "ti,timer-secure"); |
176 | if (of_get_property(np, "ti,timer-secure", NULL)) | 214 | if (np) |
177 | prom_add_property(np, &device_disabled); | 215 | of_node_put(np); |
178 | } | ||
179 | } | 216 | } |
180 | } | 217 | } |
181 | 218 | ||
182 | static int __init omap_dm_timer_init_one(struct omap_dm_timer *timer, | 219 | static int __init omap_dm_timer_init_one(struct omap_dm_timer *timer, |
183 | int gptimer_id, | 220 | int gptimer_id, |
184 | const char *fck_source) | 221 | const char *fck_source, |
222 | const char *property) | ||
185 | { | 223 | { |
186 | char name[10]; /* 10 = sizeof("gptXX_Xck0") */ | 224 | char name[10]; /* 10 = sizeof("gptXX_Xck0") */ |
225 | const char *oh_name; | ||
226 | struct device_node *np; | ||
187 | struct omap_hwmod *oh; | 227 | struct omap_hwmod *oh; |
188 | struct resource irq_rsrc, mem_rsrc; | 228 | struct resource irq_rsrc, mem_rsrc; |
189 | size_t size; | 229 | size_t size; |
190 | int res = 0; | 230 | int res = 0; |
191 | int r; | 231 | int r; |
192 | 232 | ||
193 | sprintf(name, "timer%d", gptimer_id); | 233 | if (of_have_populated_dt()) { |
194 | omap_hwmod_setup_one(name); | 234 | np = omap_get_timer_dt(omap_timer_match, NULL); |
195 | oh = omap_hwmod_lookup(name); | 235 | if (!np) |
236 | return -ENODEV; | ||
237 | |||
238 | of_property_read_string_index(np, "ti,hwmods", 0, &oh_name); | ||
239 | if (!oh_name) | ||
240 | return -ENODEV; | ||
241 | |||
242 | timer->irq = irq_of_parse_and_map(np, 0); | ||
243 | if (!timer->irq) | ||
244 | return -ENXIO; | ||
245 | |||
246 | timer->io_base = of_iomap(np, 0); | ||
247 | |||
248 | of_node_put(np); | ||
249 | } else { | ||
250 | if (omap_dm_timer_reserve_systimer(gptimer_id)) | ||
251 | return -ENODEV; | ||
252 | |||
253 | sprintf(name, "timer%d", gptimer_id); | ||
254 | oh_name = name; | ||
255 | } | ||
256 | |||
257 | omap_hwmod_setup_one(oh_name); | ||
258 | oh = omap_hwmod_lookup(oh_name); | ||
259 | |||
196 | if (!oh) | 260 | if (!oh) |
197 | return -ENODEV; | 261 | return -ENODEV; |
198 | 262 | ||
199 | r = omap_hwmod_get_resource_byname(oh, IORESOURCE_IRQ, NULL, &irq_rsrc); | 263 | if (!of_have_populated_dt()) { |
200 | if (r) | 264 | r = omap_hwmod_get_resource_byname(oh, IORESOURCE_IRQ, NULL, |
201 | return -ENXIO; | 265 | &irq_rsrc); |
202 | timer->irq = irq_rsrc.start; | 266 | if (r) |
203 | 267 | return -ENXIO; | |
204 | r = omap_hwmod_get_resource_byname(oh, IORESOURCE_MEM, NULL, &mem_rsrc); | 268 | timer->irq = irq_rsrc.start; |
205 | if (r) | 269 | |
206 | return -ENXIO; | 270 | r = omap_hwmod_get_resource_byname(oh, IORESOURCE_MEM, NULL, |
207 | timer->phys_base = mem_rsrc.start; | 271 | &mem_rsrc); |
208 | size = mem_rsrc.end - mem_rsrc.start; | 272 | if (r) |
273 | return -ENXIO; | ||
274 | timer->phys_base = mem_rsrc.start; | ||
275 | size = mem_rsrc.end - mem_rsrc.start; | ||
276 | |||
277 | /* Static mapping, never released */ | ||
278 | timer->io_base = ioremap(timer->phys_base, size); | ||
279 | } | ||
209 | 280 | ||
210 | /* Static mapping, never released */ | ||
211 | timer->io_base = ioremap(timer->phys_base, size); | ||
212 | if (!timer->io_base) | 281 | if (!timer->io_base) |
213 | return -ENXIO; | 282 | return -ENXIO; |
214 | 283 | ||
@@ -219,9 +288,7 @@ static int __init omap_dm_timer_init_one(struct omap_dm_timer *timer, | |||
219 | 288 | ||
220 | omap_hwmod_enable(oh); | 289 | omap_hwmod_enable(oh); |
221 | 290 | ||
222 | if (omap_dm_timer_reserve_systimer(gptimer_id)) | 291 | /* FIXME: Need to remove hard-coded test on timer ID */ |
223 | return -ENODEV; | ||
224 | |||
225 | if (gptimer_id != 12) { | 292 | if (gptimer_id != 12) { |
226 | struct clk *src; | 293 | struct clk *src; |
227 | 294 | ||
@@ -231,8 +298,8 @@ static int __init omap_dm_timer_init_one(struct omap_dm_timer *timer, | |||
231 | } else { | 298 | } else { |
232 | res = __omap_dm_timer_set_source(timer->fclk, src); | 299 | res = __omap_dm_timer_set_source(timer->fclk, src); |
233 | if (IS_ERR_VALUE(res)) | 300 | if (IS_ERR_VALUE(res)) |
234 | pr_warning("%s: timer%i cannot set source\n", | 301 | pr_warn("%s: %s cannot set source\n", |
235 | __func__, gptimer_id); | 302 | __func__, oh->name); |
236 | clk_put(src); | 303 | clk_put(src); |
237 | } | 304 | } |
238 | } | 305 | } |
@@ -248,11 +315,12 @@ static int __init omap_dm_timer_init_one(struct omap_dm_timer *timer, | |||
248 | } | 315 | } |
249 | 316 | ||
250 | static void __init omap2_gp_clockevent_init(int gptimer_id, | 317 | static void __init omap2_gp_clockevent_init(int gptimer_id, |
251 | const char *fck_source) | 318 | const char *fck_source, |
319 | const char *property) | ||
252 | { | 320 | { |
253 | int res; | 321 | int res; |
254 | 322 | ||
255 | res = omap_dm_timer_init_one(&clkev, gptimer_id, fck_source); | 323 | res = omap_dm_timer_init_one(&clkev, gptimer_id, fck_source, property); |
256 | BUG_ON(res); | 324 | BUG_ON(res); |
257 | 325 | ||
258 | omap2_gp_timer_irq.dev_id = &clkev; | 326 | omap2_gp_timer_irq.dev_id = &clkev; |
@@ -356,7 +424,7 @@ static void __init omap2_gptimer_clocksource_init(int gptimer_id, | |||
356 | { | 424 | { |
357 | int res; | 425 | int res; |
358 | 426 | ||
359 | res = omap_dm_timer_init_one(&clksrc, gptimer_id, fck_source); | 427 | res = omap_dm_timer_init_one(&clksrc, gptimer_id, fck_source, NULL); |
360 | BUG_ON(res); | 428 | BUG_ON(res); |
361 | 429 | ||
362 | __omap_dm_timer_load_start(&clksrc, | 430 | __omap_dm_timer_load_start(&clksrc, |
@@ -468,12 +536,12 @@ static inline void __init realtime_counter_init(void) | |||
468 | {} | 536 | {} |
469 | #endif | 537 | #endif |
470 | 538 | ||
471 | #define OMAP_SYS_TIMER_INIT(name, clkev_nr, clkev_src, \ | 539 | #define OMAP_SYS_TIMER_INIT(name, clkev_nr, clkev_src, clkev_prop, \ |
472 | clksrc_nr, clksrc_src) \ | 540 | clksrc_nr, clksrc_src) \ |
473 | static void __init omap##name##_timer_init(void) \ | 541 | static void __init omap##name##_timer_init(void) \ |
474 | { \ | 542 | { \ |
475 | omap_dmtimer_init(); \ | 543 | omap_dmtimer_init(); \ |
476 | omap2_gp_clockevent_init((clkev_nr), clkev_src); \ | 544 | omap2_gp_clockevent_init((clkev_nr), clkev_src, clkev_prop); \ |
477 | omap2_clocksource_init((clksrc_nr), clksrc_src); \ | 545 | omap2_clocksource_init((clksrc_nr), clksrc_src); \ |
478 | } | 546 | } |
479 | 547 | ||
@@ -483,20 +551,23 @@ struct sys_timer omap##name##_timer = { \ | |||
483 | }; | 551 | }; |
484 | 552 | ||
485 | #ifdef CONFIG_ARCH_OMAP2 | 553 | #ifdef CONFIG_ARCH_OMAP2 |
486 | OMAP_SYS_TIMER_INIT(2, 1, OMAP2_CLKEV_SOURCE, 2, OMAP2_MPU_SOURCE) | 554 | OMAP_SYS_TIMER_INIT(2, 1, OMAP2_CLKEV_SOURCE, "ti,timer-alwon", |
555 | 2, OMAP2_MPU_SOURCE) | ||
487 | OMAP_SYS_TIMER(2) | 556 | OMAP_SYS_TIMER(2) |
488 | #endif | 557 | #endif |
489 | 558 | ||
490 | #ifdef CONFIG_ARCH_OMAP3 | 559 | #ifdef CONFIG_ARCH_OMAP3 |
491 | OMAP_SYS_TIMER_INIT(3, 1, OMAP3_CLKEV_SOURCE, 2, OMAP3_MPU_SOURCE) | 560 | OMAP_SYS_TIMER_INIT(3, 1, OMAP3_CLKEV_SOURCE, "ti,timer-alwon", |
561 | 2, OMAP3_MPU_SOURCE) | ||
492 | OMAP_SYS_TIMER(3) | 562 | OMAP_SYS_TIMER(3) |
493 | OMAP_SYS_TIMER_INIT(3_secure, OMAP3_SECURE_TIMER, OMAP3_CLKEV_SOURCE, | 563 | OMAP_SYS_TIMER_INIT(3_secure, OMAP3_SECURE_TIMER, OMAP3_CLKEV_SOURCE, |
494 | 2, OMAP3_MPU_SOURCE) | 564 | TIMER_PROP_SECURE, 2, OMAP3_MPU_SOURCE) |
495 | OMAP_SYS_TIMER(3_secure) | 565 | OMAP_SYS_TIMER(3_secure) |
496 | #endif | 566 | #endif |
497 | 567 | ||
498 | #ifdef CONFIG_SOC_AM33XX | 568 | #ifdef CONFIG_SOC_AM33XX |
499 | OMAP_SYS_TIMER_INIT(3_am33xx, 1, OMAP4_MPU_SOURCE, 2, OMAP4_MPU_SOURCE) | 569 | OMAP_SYS_TIMER_INIT(3_am33xx, 1, OMAP4_MPU_SOURCE, "ti,timer-alwon", |
570 | 2, OMAP4_MPU_SOURCE) | ||
500 | OMAP_SYS_TIMER(3_am33xx) | 571 | OMAP_SYS_TIMER(3_am33xx) |
501 | #endif | 572 | #endif |
502 | 573 | ||
@@ -508,7 +579,7 @@ static DEFINE_TWD_LOCAL_TIMER(twd_local_timer, | |||
508 | 579 | ||
509 | static void __init omap4_timer_init(void) | 580 | static void __init omap4_timer_init(void) |
510 | { | 581 | { |
511 | omap2_gp_clockevent_init(1, OMAP4_CLKEV_SOURCE); | 582 | omap2_gp_clockevent_init(1, OMAP4_CLKEV_SOURCE, "ti,timer-alwon"); |
512 | omap2_clocksource_init(2, OMAP4_MPU_SOURCE); | 583 | omap2_clocksource_init(2, OMAP4_MPU_SOURCE); |
513 | #ifdef CONFIG_LOCAL_TIMERS | 584 | #ifdef CONFIG_LOCAL_TIMERS |
514 | /* Local timers are not supprted on OMAP4430 ES1.0 */ | 585 | /* Local timers are not supprted on OMAP4430 ES1.0 */ |
@@ -534,7 +605,7 @@ static void __init omap5_timer_init(void) | |||
534 | { | 605 | { |
535 | int err; | 606 | int err; |
536 | 607 | ||
537 | omap2_gp_clockevent_init(1, OMAP4_CLKEV_SOURCE); | 608 | omap2_gp_clockevent_init(1, OMAP4_CLKEV_SOURCE, "ti,timer-alwon"); |
538 | omap2_clocksource_init(2, OMAP4_MPU_SOURCE); | 609 | omap2_clocksource_init(2, OMAP4_MPU_SOURCE); |
539 | realtime_counter_init(); | 610 | realtime_counter_init(); |
540 | 611 | ||
@@ -619,6 +690,10 @@ static int __init omap2_dm_timer_init(void) | |||
619 | { | 690 | { |
620 | int ret; | 691 | int ret; |
621 | 692 | ||
693 | /* If dtb is there, the devices will be created dynamically */ | ||
694 | if (of_have_populated_dt()) | ||
695 | return -ENODEV; | ||
696 | |||
622 | ret = omap_hwmod_for_each_by_class("timer", omap_timer_init, NULL); | 697 | ret = omap_hwmod_for_each_by_class("timer", omap_timer_init, NULL); |
623 | if (unlikely(ret)) { | 698 | if (unlikely(ret)) { |
624 | pr_err("%s: device registration failed.\n", __func__); | 699 | pr_err("%s: device registration failed.\n", __func__); |
diff --git a/arch/arm/plat-omap/dmtimer.c b/arch/arm/plat-omap/dmtimer.c index 2574b86ad2dc..b09e55632f4b 100644 --- a/arch/arm/plat-omap/dmtimer.c +++ b/arch/arm/plat-omap/dmtimer.c | |||
@@ -40,6 +40,8 @@ | |||
40 | #include <linux/device.h> | 40 | #include <linux/device.h> |
41 | #include <linux/err.h> | 41 | #include <linux/err.h> |
42 | #include <linux/pm_runtime.h> | 42 | #include <linux/pm_runtime.h> |
43 | #include <linux/of.h> | ||
44 | #include <linux/of_device.h> | ||
43 | 45 | ||
44 | #include <plat/dmtimer.h> | 46 | #include <plat/dmtimer.h> |
45 | #include <plat/omap-pm.h> | 47 | #include <plat/omap-pm.h> |
@@ -212,6 +214,13 @@ struct omap_dm_timer *omap_dm_timer_request_specific(int id) | |||
212 | unsigned long flags; | 214 | unsigned long flags; |
213 | int ret = 0; | 215 | int ret = 0; |
214 | 216 | ||
217 | /* Requesting timer by ID is not supported when device tree is used */ | ||
218 | if (of_have_populated_dt()) { | ||
219 | pr_warn("%s: Please use omap_dm_timer_request_by_cap()\n", | ||
220 | __func__); | ||
221 | return NULL; | ||
222 | } | ||
223 | |||
215 | spin_lock_irqsave(&dm_timer_lock, flags); | 224 | spin_lock_irqsave(&dm_timer_lock, flags); |
216 | list_for_each_entry(t, &omap_timer_list, node) { | 225 | list_for_each_entry(t, &omap_timer_list, node) { |
217 | if (t->pdev->id == id && !t->reserved) { | 226 | if (t->pdev->id == id && !t->reserved) { |
@@ -466,7 +475,7 @@ int omap_dm_timer_set_source(struct omap_dm_timer *timer, int source) | |||
466 | * use the clock framework to set the parent clock. To be removed | 475 | * use the clock framework to set the parent clock. To be removed |
467 | * once OMAP1 migrated to using clock framework for dmtimers | 476 | * once OMAP1 migrated to using clock framework for dmtimers |
468 | */ | 477 | */ |
469 | if (pdata->set_timer_src) | 478 | if (pdata && pdata->set_timer_src) |
470 | return pdata->set_timer_src(timer->pdev, source); | 479 | return pdata->set_timer_src(timer->pdev, source); |
471 | 480 | ||
472 | fclk = clk_get(&timer->pdev->dev, "fck"); | 481 | fclk = clk_get(&timer->pdev->dev, "fck"); |
@@ -747,7 +756,7 @@ static int __devinit omap_dm_timer_probe(struct platform_device *pdev) | |||
747 | struct device *dev = &pdev->dev; | 756 | struct device *dev = &pdev->dev; |
748 | struct dmtimer_platform_data *pdata = pdev->dev.platform_data; | 757 | struct dmtimer_platform_data *pdata = pdev->dev.platform_data; |
749 | 758 | ||
750 | if (!pdata) { | 759 | if (!pdata && !dev->of_node) { |
751 | dev_err(dev, "%s: no platform data.\n", __func__); | 760 | dev_err(dev, "%s: no platform data.\n", __func__); |
752 | return -ENODEV; | 761 | return -ENODEV; |
753 | } | 762 | } |
@@ -776,11 +785,23 @@ static int __devinit omap_dm_timer_probe(struct platform_device *pdev) | |||
776 | return -ENOMEM; | 785 | return -ENOMEM; |
777 | } | 786 | } |
778 | 787 | ||
779 | timer->id = pdev->id; | 788 | if (dev->of_node) { |
789 | if (of_find_property(dev->of_node, "ti,timer-alwon", NULL)) | ||
790 | timer->capability |= OMAP_TIMER_ALWON; | ||
791 | if (of_find_property(dev->of_node, "ti,timer-dsp", NULL)) | ||
792 | timer->capability |= OMAP_TIMER_HAS_DSP_IRQ; | ||
793 | if (of_find_property(dev->of_node, "ti,timer-pwm", NULL)) | ||
794 | timer->capability |= OMAP_TIMER_HAS_PWM; | ||
795 | if (of_find_property(dev->of_node, "ti,timer-secure", NULL)) | ||
796 | timer->capability |= OMAP_TIMER_SECURE; | ||
797 | } else { | ||
798 | timer->id = pdev->id; | ||
799 | timer->capability = pdata->timer_capability; | ||
800 | timer->reserved = omap_dm_timer_reserved_systimer(timer->id); | ||
801 | } | ||
802 | |||
780 | timer->irq = irq->start; | 803 | timer->irq = irq->start; |
781 | timer->reserved = omap_dm_timer_reserved_systimer(timer->id); | ||
782 | timer->pdev = pdev; | 804 | timer->pdev = pdev; |
783 | timer->capability = pdata->timer_capability; | ||
784 | 805 | ||
785 | /* Skip pm_runtime_enable for OMAP1 */ | 806 | /* Skip pm_runtime_enable for OMAP1 */ |
786 | if (!(timer->capability & OMAP_TIMER_NEEDS_RESET)) { | 807 | if (!(timer->capability & OMAP_TIMER_NEEDS_RESET)) { |
@@ -820,7 +841,8 @@ static int __devexit omap_dm_timer_remove(struct platform_device *pdev) | |||
820 | 841 | ||
821 | spin_lock_irqsave(&dm_timer_lock, flags); | 842 | spin_lock_irqsave(&dm_timer_lock, flags); |
822 | list_for_each_entry(timer, &omap_timer_list, node) | 843 | list_for_each_entry(timer, &omap_timer_list, node) |
823 | if (timer->pdev->id == pdev->id) { | 844 | if (!strcmp(dev_name(&timer->pdev->dev), |
845 | dev_name(&pdev->dev))) { | ||
824 | list_del(&timer->node); | 846 | list_del(&timer->node); |
825 | ret = 0; | 847 | ret = 0; |
826 | break; | 848 | break; |
@@ -830,11 +852,18 @@ static int __devexit omap_dm_timer_remove(struct platform_device *pdev) | |||
830 | return ret; | 852 | return ret; |
831 | } | 853 | } |
832 | 854 | ||
855 | static const struct of_device_id omap_timer_match[] = { | ||
856 | { .compatible = "ti,omap2-timer", }, | ||
857 | {}, | ||
858 | }; | ||
859 | MODULE_DEVICE_TABLE(of, omap_timer_match); | ||
860 | |||
833 | static struct platform_driver omap_dm_timer_driver = { | 861 | static struct platform_driver omap_dm_timer_driver = { |
834 | .probe = omap_dm_timer_probe, | 862 | .probe = omap_dm_timer_probe, |
835 | .remove = __devexit_p(omap_dm_timer_remove), | 863 | .remove = __devexit_p(omap_dm_timer_remove), |
836 | .driver = { | 864 | .driver = { |
837 | .name = "omap_timer", | 865 | .name = "omap_timer", |
866 | .of_match_table = of_match_ptr(omap_timer_match), | ||
838 | }, | 867 | }, |
839 | }; | 868 | }; |
840 | 869 | ||