diff options
Diffstat (limited to 'arch/arm/mach-omap1')
-rw-r--r-- | arch/arm/mach-omap1/Makefile | 2 | ||||
-rw-r--r-- | arch/arm/mach-omap1/board-ams-delta.c | 4 | ||||
-rw-r--r-- | arch/arm/mach-omap1/board-fsample.c | 2 | ||||
-rw-r--r-- | arch/arm/mach-omap1/board-generic.c | 2 | ||||
-rw-r--r-- | arch/arm/mach-omap1/board-h2.c | 2 | ||||
-rw-r--r-- | arch/arm/mach-omap1/board-h3.c | 2 | ||||
-rw-r--r-- | arch/arm/mach-omap1/board-htcherald.c | 2 | ||||
-rw-r--r-- | arch/arm/mach-omap1/board-innovator.c | 2 | ||||
-rw-r--r-- | arch/arm/mach-omap1/board-nokia770.c | 2 | ||||
-rw-r--r-- | arch/arm/mach-omap1/board-osk.c | 2 | ||||
-rw-r--r-- | arch/arm/mach-omap1/board-palmte.c | 2 | ||||
-rw-r--r-- | arch/arm/mach-omap1/board-palmtt.c | 2 | ||||
-rw-r--r-- | arch/arm/mach-omap1/board-palmz71.c | 2 | ||||
-rw-r--r-- | arch/arm/mach-omap1/board-perseus2.c | 2 | ||||
-rw-r--r-- | arch/arm/mach-omap1/board-sx1.c | 2 | ||||
-rw-r--r-- | arch/arm/mach-omap1/board-voiceblue.c | 2 | ||||
-rw-r--r-- | arch/arm/mach-omap1/common.h | 2 | ||||
-rw-r--r-- | arch/arm/mach-omap1/fb.c | 80 | ||||
-rw-r--r-- | arch/arm/mach-omap1/mailbox.c | 6 | ||||
-rw-r--r-- | arch/arm/mach-omap1/time.c | 17 | ||||
-rw-r--r-- | arch/arm/mach-omap1/timer32k.c | 12 | ||||
-rw-r--r-- | arch/arm/mach-omap1/usb.c | 8 |
22 files changed, 113 insertions, 46 deletions
diff --git a/arch/arm/mach-omap1/Makefile b/arch/arm/mach-omap1/Makefile index f0e69cbc5baa..222d58c0ae76 100644 --- a/arch/arm/mach-omap1/Makefile +++ b/arch/arm/mach-omap1/Makefile | |||
@@ -4,7 +4,7 @@ | |||
4 | 4 | ||
5 | # Common support | 5 | # Common support |
6 | obj-y := io.o id.o sram-init.o sram.o time.o irq.o mux.o flash.o \ | 6 | obj-y := io.o id.o sram-init.o sram.o time.o irq.o mux.o flash.o \ |
7 | serial.o devices.o dma.o | 7 | serial.o devices.o dma.o fb.o |
8 | obj-y += clock.o clock_data.o opp_data.o reset.o pm_bus.o timer.o | 8 | obj-y += clock.o clock_data.o opp_data.o reset.o pm_bus.o timer.o |
9 | 9 | ||
10 | ifneq ($(CONFIG_SND_OMAP_SOC_MCBSP),) | 10 | ifneq ($(CONFIG_SND_OMAP_SOC_MCBSP),) |
diff --git a/arch/arm/mach-omap1/board-ams-delta.c b/arch/arm/mach-omap1/board-ams-delta.c index a8fce3ccc707..2aab761ee68d 100644 --- a/arch/arm/mach-omap1/board-ams-delta.c +++ b/arch/arm/mach-omap1/board-ams-delta.c | |||
@@ -160,7 +160,7 @@ static struct omap_lcd_config ams_delta_lcd_config __initdata = { | |||
160 | .ctrl_name = "internal", | 160 | .ctrl_name = "internal", |
161 | }; | 161 | }; |
162 | 162 | ||
163 | static struct omap_usb_config ams_delta_usb_config = { | 163 | static struct omap_usb_config ams_delta_usb_config __initdata = { |
164 | .register_host = 1, | 164 | .register_host = 1, |
165 | .hmc_mode = 16, | 165 | .hmc_mode = 16, |
166 | .pins[0] = 2, | 166 | .pins[0] = 2, |
@@ -628,6 +628,6 @@ MACHINE_START(AMS_DELTA, "Amstrad E3 (Delta)") | |||
628 | .init_irq = omap1_init_irq, | 628 | .init_irq = omap1_init_irq, |
629 | .init_machine = ams_delta_init, | 629 | .init_machine = ams_delta_init, |
630 | .init_late = ams_delta_init_late, | 630 | .init_late = ams_delta_init_late, |
631 | .timer = &omap1_timer, | 631 | .init_time = omap1_timer_init, |
632 | .restart = omap1_restart, | 632 | .restart = omap1_restart, |
633 | MACHINE_END | 633 | MACHINE_END |
diff --git a/arch/arm/mach-omap1/board-fsample.c b/arch/arm/mach-omap1/board-fsample.c index 560a7dcf0a56..702d58039cc1 100644 --- a/arch/arm/mach-omap1/board-fsample.c +++ b/arch/arm/mach-omap1/board-fsample.c | |||
@@ -364,6 +364,6 @@ MACHINE_START(OMAP_FSAMPLE, "OMAP730 F-Sample") | |||
364 | .init_irq = omap1_init_irq, | 364 | .init_irq = omap1_init_irq, |
365 | .init_machine = omap_fsample_init, | 365 | .init_machine = omap_fsample_init, |
366 | .init_late = omap1_init_late, | 366 | .init_late = omap1_init_late, |
367 | .timer = &omap1_timer, | 367 | .init_time = omap1_timer_init, |
368 | .restart = omap1_restart, | 368 | .restart = omap1_restart, |
369 | MACHINE_END | 369 | MACHINE_END |
diff --git a/arch/arm/mach-omap1/board-generic.c b/arch/arm/mach-omap1/board-generic.c index 608e7d2a2778..e1d9171774bc 100644 --- a/arch/arm/mach-omap1/board-generic.c +++ b/arch/arm/mach-omap1/board-generic.c | |||
@@ -84,6 +84,6 @@ MACHINE_START(OMAP_GENERIC, "Generic OMAP1510/1610/1710") | |||
84 | .init_irq = omap1_init_irq, | 84 | .init_irq = omap1_init_irq, |
85 | .init_machine = omap_generic_init, | 85 | .init_machine = omap_generic_init, |
86 | .init_late = omap1_init_late, | 86 | .init_late = omap1_init_late, |
87 | .timer = &omap1_timer, | 87 | .init_time = omap1_timer_init, |
88 | .restart = omap1_restart, | 88 | .restart = omap1_restart, |
89 | MACHINE_END | 89 | MACHINE_END |
diff --git a/arch/arm/mach-omap1/board-h2.c b/arch/arm/mach-omap1/board-h2.c index 2274bd677efc..0dac3d239e32 100644 --- a/arch/arm/mach-omap1/board-h2.c +++ b/arch/arm/mach-omap1/board-h2.c | |||
@@ -461,6 +461,6 @@ MACHINE_START(OMAP_H2, "TI-H2") | |||
461 | .init_irq = omap1_init_irq, | 461 | .init_irq = omap1_init_irq, |
462 | .init_machine = h2_init, | 462 | .init_machine = h2_init, |
463 | .init_late = omap1_init_late, | 463 | .init_late = omap1_init_late, |
464 | .timer = &omap1_timer, | 464 | .init_time = omap1_timer_init, |
465 | .restart = omap1_restart, | 465 | .restart = omap1_restart, |
466 | MACHINE_END | 466 | MACHINE_END |
diff --git a/arch/arm/mach-omap1/board-h3.c b/arch/arm/mach-omap1/board-h3.c index 1051935f0aac..816ecd13f81e 100644 --- a/arch/arm/mach-omap1/board-h3.c +++ b/arch/arm/mach-omap1/board-h3.c | |||
@@ -454,6 +454,6 @@ MACHINE_START(OMAP_H3, "TI OMAP1710 H3 board") | |||
454 | .init_irq = omap1_init_irq, | 454 | .init_irq = omap1_init_irq, |
455 | .init_machine = h3_init, | 455 | .init_machine = h3_init, |
456 | .init_late = omap1_init_late, | 456 | .init_late = omap1_init_late, |
457 | .timer = &omap1_timer, | 457 | .init_time = omap1_timer_init, |
458 | .restart = omap1_restart, | 458 | .restart = omap1_restart, |
459 | MACHINE_END | 459 | MACHINE_END |
diff --git a/arch/arm/mach-omap1/board-htcherald.c b/arch/arm/mach-omap1/board-htcherald.c index 356f816c84a6..35a2379b986f 100644 --- a/arch/arm/mach-omap1/board-htcherald.c +++ b/arch/arm/mach-omap1/board-htcherald.c | |||
@@ -603,6 +603,6 @@ MACHINE_START(HERALD, "HTC Herald") | |||
603 | .init_irq = omap1_init_irq, | 603 | .init_irq = omap1_init_irq, |
604 | .init_machine = htcherald_init, | 604 | .init_machine = htcherald_init, |
605 | .init_late = omap1_init_late, | 605 | .init_late = omap1_init_late, |
606 | .timer = &omap1_timer, | 606 | .init_time = omap1_timer_init, |
607 | .restart = omap1_restart, | 607 | .restart = omap1_restart, |
608 | MACHINE_END | 608 | MACHINE_END |
diff --git a/arch/arm/mach-omap1/board-innovator.c b/arch/arm/mach-omap1/board-innovator.c index f8033fab0f82..bd5f02e9c354 100644 --- a/arch/arm/mach-omap1/board-innovator.c +++ b/arch/arm/mach-omap1/board-innovator.c | |||
@@ -458,6 +458,6 @@ MACHINE_START(OMAP_INNOVATOR, "TI-Innovator") | |||
458 | .init_irq = omap1_init_irq, | 458 | .init_irq = omap1_init_irq, |
459 | .init_machine = innovator_init, | 459 | .init_machine = innovator_init, |
460 | .init_late = omap1_init_late, | 460 | .init_late = omap1_init_late, |
461 | .timer = &omap1_timer, | 461 | .init_time = omap1_timer_init, |
462 | .restart = omap1_restart, | 462 | .restart = omap1_restart, |
463 | MACHINE_END | 463 | MACHINE_END |
diff --git a/arch/arm/mach-omap1/board-nokia770.c b/arch/arm/mach-omap1/board-nokia770.c index 24d2f2df11a0..4695ca717706 100644 --- a/arch/arm/mach-omap1/board-nokia770.c +++ b/arch/arm/mach-omap1/board-nokia770.c | |||
@@ -242,6 +242,6 @@ MACHINE_START(NOKIA770, "Nokia 770") | |||
242 | .init_irq = omap1_init_irq, | 242 | .init_irq = omap1_init_irq, |
243 | .init_machine = omap_nokia770_init, | 243 | .init_machine = omap_nokia770_init, |
244 | .init_late = omap1_init_late, | 244 | .init_late = omap1_init_late, |
245 | .timer = &omap1_timer, | 245 | .init_time = omap1_timer_init, |
246 | .restart = omap1_restart, | 246 | .restart = omap1_restart, |
247 | MACHINE_END | 247 | MACHINE_END |
diff --git a/arch/arm/mach-omap1/board-osk.c b/arch/arm/mach-omap1/board-osk.c index 872ea47cd28a..a7ce69286688 100644 --- a/arch/arm/mach-omap1/board-osk.c +++ b/arch/arm/mach-omap1/board-osk.c | |||
@@ -609,6 +609,6 @@ MACHINE_START(OMAP_OSK, "TI-OSK") | |||
609 | .init_irq = omap1_init_irq, | 609 | .init_irq = omap1_init_irq, |
610 | .init_machine = osk_init, | 610 | .init_machine = osk_init, |
611 | .init_late = omap1_init_late, | 611 | .init_late = omap1_init_late, |
612 | .timer = &omap1_timer, | 612 | .init_time = omap1_timer_init, |
613 | .restart = omap1_restart, | 613 | .restart = omap1_restart, |
614 | MACHINE_END | 614 | MACHINE_END |
diff --git a/arch/arm/mach-omap1/board-palmte.c b/arch/arm/mach-omap1/board-palmte.c index c33dceb46607..845a1a7aef95 100644 --- a/arch/arm/mach-omap1/board-palmte.c +++ b/arch/arm/mach-omap1/board-palmte.c | |||
@@ -268,6 +268,6 @@ MACHINE_START(OMAP_PALMTE, "OMAP310 based Palm Tungsten E") | |||
268 | .init_irq = omap1_init_irq, | 268 | .init_irq = omap1_init_irq, |
269 | .init_machine = omap_palmte_init, | 269 | .init_machine = omap_palmte_init, |
270 | .init_late = omap1_init_late, | 270 | .init_late = omap1_init_late, |
271 | .timer = &omap1_timer, | 271 | .init_time = omap1_timer_init, |
272 | .restart = omap1_restart, | 272 | .restart = omap1_restart, |
273 | MACHINE_END | 273 | MACHINE_END |
diff --git a/arch/arm/mach-omap1/board-palmtt.c b/arch/arm/mach-omap1/board-palmtt.c index 2948b0ee4be8..65a4a3e357f2 100644 --- a/arch/arm/mach-omap1/board-palmtt.c +++ b/arch/arm/mach-omap1/board-palmtt.c | |||
@@ -314,6 +314,6 @@ MACHINE_START(OMAP_PALMTT, "OMAP1510 based Palm Tungsten|T") | |||
314 | .init_irq = omap1_init_irq, | 314 | .init_irq = omap1_init_irq, |
315 | .init_machine = omap_palmtt_init, | 315 | .init_machine = omap_palmtt_init, |
316 | .init_late = omap1_init_late, | 316 | .init_late = omap1_init_late, |
317 | .timer = &omap1_timer, | 317 | .init_time = omap1_timer_init, |
318 | .restart = omap1_restart, | 318 | .restart = omap1_restart, |
319 | MACHINE_END | 319 | MACHINE_END |
diff --git a/arch/arm/mach-omap1/board-palmz71.c b/arch/arm/mach-omap1/board-palmz71.c index 7a05895c0be3..01c970071fd8 100644 --- a/arch/arm/mach-omap1/board-palmz71.c +++ b/arch/arm/mach-omap1/board-palmz71.c | |||
@@ -330,6 +330,6 @@ MACHINE_START(OMAP_PALMZ71, "OMAP310 based Palm Zire71") | |||
330 | .init_irq = omap1_init_irq, | 330 | .init_irq = omap1_init_irq, |
331 | .init_machine = omap_palmz71_init, | 331 | .init_machine = omap_palmz71_init, |
332 | .init_late = omap1_init_late, | 332 | .init_late = omap1_init_late, |
333 | .timer = &omap1_timer, | 333 | .init_time = omap1_timer_init, |
334 | .restart = omap1_restart, | 334 | .restart = omap1_restart, |
335 | MACHINE_END | 335 | MACHINE_END |
diff --git a/arch/arm/mach-omap1/board-perseus2.c b/arch/arm/mach-omap1/board-perseus2.c index 27f8d12ec222..8b2f7127f716 100644 --- a/arch/arm/mach-omap1/board-perseus2.c +++ b/arch/arm/mach-omap1/board-perseus2.c | |||
@@ -326,6 +326,6 @@ MACHINE_START(OMAP_PERSEUS2, "OMAP730 Perseus2") | |||
326 | .init_irq = omap1_init_irq, | 326 | .init_irq = omap1_init_irq, |
327 | .init_machine = omap_perseus2_init, | 327 | .init_machine = omap_perseus2_init, |
328 | .init_late = omap1_init_late, | 328 | .init_late = omap1_init_late, |
329 | .timer = &omap1_timer, | 329 | .init_time = omap1_timer_init, |
330 | .restart = omap1_restart, | 330 | .restart = omap1_restart, |
331 | MACHINE_END | 331 | MACHINE_END |
diff --git a/arch/arm/mach-omap1/board-sx1.c b/arch/arm/mach-omap1/board-sx1.c index 20ed52ae1714..9732a98f3e06 100644 --- a/arch/arm/mach-omap1/board-sx1.c +++ b/arch/arm/mach-omap1/board-sx1.c | |||
@@ -407,6 +407,6 @@ MACHINE_START(SX1, "OMAP310 based Siemens SX1") | |||
407 | .init_irq = omap1_init_irq, | 407 | .init_irq = omap1_init_irq, |
408 | .init_machine = omap_sx1_init, | 408 | .init_machine = omap_sx1_init, |
409 | .init_late = omap1_init_late, | 409 | .init_late = omap1_init_late, |
410 | .timer = &omap1_timer, | 410 | .init_time = omap1_timer_init, |
411 | .restart = omap1_restart, | 411 | .restart = omap1_restart, |
412 | MACHINE_END | 412 | MACHINE_END |
diff --git a/arch/arm/mach-omap1/board-voiceblue.c b/arch/arm/mach-omap1/board-voiceblue.c index abf705f49b19..6c116e1a4b01 100644 --- a/arch/arm/mach-omap1/board-voiceblue.c +++ b/arch/arm/mach-omap1/board-voiceblue.c | |||
@@ -289,6 +289,6 @@ MACHINE_START(VOICEBLUE, "VoiceBlue OMAP5910") | |||
289 | .init_irq = omap1_init_irq, | 289 | .init_irq = omap1_init_irq, |
290 | .init_machine = voiceblue_init, | 290 | .init_machine = voiceblue_init, |
291 | .init_late = omap1_init_late, | 291 | .init_late = omap1_init_late, |
292 | .timer = &omap1_timer, | 292 | .init_time = omap1_timer_init, |
293 | .restart = voiceblue_restart, | 293 | .restart = voiceblue_restart, |
294 | MACHINE_END | 294 | MACHINE_END |
diff --git a/arch/arm/mach-omap1/common.h b/arch/arm/mach-omap1/common.h index b53e0854422f..fb18831e88aa 100644 --- a/arch/arm/mach-omap1/common.h +++ b/arch/arm/mach-omap1/common.h | |||
@@ -75,7 +75,7 @@ extern void __init omap_check_revision(void); | |||
75 | extern void omap1_nand_cmd_ctl(struct mtd_info *mtd, int cmd, | 75 | extern void omap1_nand_cmd_ctl(struct mtd_info *mtd, int cmd, |
76 | unsigned int ctrl); | 76 | unsigned int ctrl); |
77 | 77 | ||
78 | extern struct sys_timer omap1_timer; | 78 | extern void omap1_timer_init(void); |
79 | #ifdef CONFIG_OMAP_32K_TIMER | 79 | #ifdef CONFIG_OMAP_32K_TIMER |
80 | extern int omap_32k_timer_init(void); | 80 | extern int omap_32k_timer_init(void); |
81 | #else | 81 | #else |
diff --git a/arch/arm/mach-omap1/fb.c b/arch/arm/mach-omap1/fb.c new file mode 100644 index 000000000000..c770d45c7226 --- /dev/null +++ b/arch/arm/mach-omap1/fb.c | |||
@@ -0,0 +1,80 @@ | |||
1 | /* | ||
2 | * File: arch/arm/plat-omap/fb.c | ||
3 | * | ||
4 | * Framebuffer device registration for TI OMAP platforms | ||
5 | * | ||
6 | * Copyright (C) 2006 Nokia Corporation | ||
7 | * Author: Imre Deak <imre.deak@nokia.com> | ||
8 | * | ||
9 | * This program is free software; you can redistribute it and/or modify it | ||
10 | * under the terms of the GNU General Public License as published by the | ||
11 | * Free Software Foundation; either version 2 of the License, or (at your | ||
12 | * option) any later version. | ||
13 | * | ||
14 | * This program is distributed in the hope that it will be useful, but | ||
15 | * WITHOUT ANY WARRANTY; without even the implied warranty of | ||
16 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU | ||
17 | * General Public License for more details. | ||
18 | * | ||
19 | * You should have received a copy of the GNU General Public License along | ||
20 | * with this program; if not, write to the Free Software Foundation, Inc., | ||
21 | * 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. | ||
22 | */ | ||
23 | |||
24 | #include <linux/module.h> | ||
25 | #include <linux/kernel.h> | ||
26 | #include <linux/mm.h> | ||
27 | #include <linux/init.h> | ||
28 | #include <linux/platform_device.h> | ||
29 | #include <linux/memblock.h> | ||
30 | #include <linux/io.h> | ||
31 | #include <linux/omapfb.h> | ||
32 | #include <linux/dma-mapping.h> | ||
33 | |||
34 | #include <asm/mach/map.h> | ||
35 | |||
36 | #if defined(CONFIG_FB_OMAP) || defined(CONFIG_FB_OMAP_MODULE) | ||
37 | |||
38 | static bool omapfb_lcd_configured; | ||
39 | static struct omapfb_platform_data omapfb_config; | ||
40 | |||
41 | static u64 omap_fb_dma_mask = ~(u32)0; | ||
42 | |||
43 | static struct platform_device omap_fb_device = { | ||
44 | .name = "omapfb", | ||
45 | .id = -1, | ||
46 | .dev = { | ||
47 | .dma_mask = &omap_fb_dma_mask, | ||
48 | .coherent_dma_mask = DMA_BIT_MASK(32), | ||
49 | .platform_data = &omapfb_config, | ||
50 | }, | ||
51 | .num_resources = 0, | ||
52 | }; | ||
53 | |||
54 | void __init omapfb_set_lcd_config(const struct omap_lcd_config *config) | ||
55 | { | ||
56 | omapfb_config.lcd = *config; | ||
57 | omapfb_lcd_configured = true; | ||
58 | } | ||
59 | |||
60 | static int __init omap_init_fb(void) | ||
61 | { | ||
62 | /* | ||
63 | * If the board file has not set the lcd config with | ||
64 | * omapfb_set_lcd_config(), don't bother registering the omapfb device | ||
65 | */ | ||
66 | if (!omapfb_lcd_configured) | ||
67 | return 0; | ||
68 | |||
69 | return platform_device_register(&omap_fb_device); | ||
70 | } | ||
71 | |||
72 | arch_initcall(omap_init_fb); | ||
73 | |||
74 | #else | ||
75 | |||
76 | void __init omapfb_set_lcd_config(const struct omap_lcd_config *config) | ||
77 | { | ||
78 | } | ||
79 | |||
80 | #endif | ||
diff --git a/arch/arm/mach-omap1/mailbox.c b/arch/arm/mach-omap1/mailbox.c index e962926b67bc..efc8f207f6fc 100644 --- a/arch/arm/mach-omap1/mailbox.c +++ b/arch/arm/mach-omap1/mailbox.c | |||
@@ -142,7 +142,7 @@ static struct omap_mbox mbox_dsp_info = { | |||
142 | 142 | ||
143 | static struct omap_mbox *omap1_mboxes[] = { &mbox_dsp_info, NULL }; | 143 | static struct omap_mbox *omap1_mboxes[] = { &mbox_dsp_info, NULL }; |
144 | 144 | ||
145 | static int __devinit omap1_mbox_probe(struct platform_device *pdev) | 145 | static int omap1_mbox_probe(struct platform_device *pdev) |
146 | { | 146 | { |
147 | struct resource *mem; | 147 | struct resource *mem; |
148 | int ret; | 148 | int ret; |
@@ -165,7 +165,7 @@ static int __devinit omap1_mbox_probe(struct platform_device *pdev) | |||
165 | return 0; | 165 | return 0; |
166 | } | 166 | } |
167 | 167 | ||
168 | static int __devexit omap1_mbox_remove(struct platform_device *pdev) | 168 | static int omap1_mbox_remove(struct platform_device *pdev) |
169 | { | 169 | { |
170 | omap_mbox_unregister(); | 170 | omap_mbox_unregister(); |
171 | iounmap(mbox_base); | 171 | iounmap(mbox_base); |
@@ -174,7 +174,7 @@ static int __devexit omap1_mbox_remove(struct platform_device *pdev) | |||
174 | 174 | ||
175 | static struct platform_driver omap1_mbox_driver = { | 175 | static struct platform_driver omap1_mbox_driver = { |
176 | .probe = omap1_mbox_probe, | 176 | .probe = omap1_mbox_probe, |
177 | .remove = __devexit_p(omap1_mbox_remove), | 177 | .remove = omap1_mbox_remove, |
178 | .driver = { | 178 | .driver = { |
179 | .name = "omap-mailbox", | 179 | .name = "omap-mailbox", |
180 | }, | 180 | }, |
diff --git a/arch/arm/mach-omap1/time.c b/arch/arm/mach-omap1/time.c index 4d4816fd6fc9..726ec23d29c7 100644 --- a/arch/arm/mach-omap1/time.c +++ b/arch/arm/mach-omap1/time.c | |||
@@ -145,7 +145,6 @@ static void omap_mpu_set_mode(enum clock_event_mode mode, | |||
145 | static struct clock_event_device clockevent_mpu_timer1 = { | 145 | static struct clock_event_device clockevent_mpu_timer1 = { |
146 | .name = "mpu_timer1", | 146 | .name = "mpu_timer1", |
147 | .features = CLOCK_EVT_FEAT_PERIODIC | CLOCK_EVT_FEAT_ONESHOT, | 147 | .features = CLOCK_EVT_FEAT_PERIODIC | CLOCK_EVT_FEAT_ONESHOT, |
148 | .shift = 32, | ||
149 | .set_next_event = omap_mpu_set_next_event, | 148 | .set_next_event = omap_mpu_set_next_event, |
150 | .set_mode = omap_mpu_set_mode, | 149 | .set_mode = omap_mpu_set_mode, |
151 | }; | 150 | }; |
@@ -170,15 +169,9 @@ static __init void omap_init_mpu_timer(unsigned long rate) | |||
170 | setup_irq(INT_TIMER1, &omap_mpu_timer1_irq); | 169 | setup_irq(INT_TIMER1, &omap_mpu_timer1_irq); |
171 | omap_mpu_timer_start(0, (rate / HZ) - 1, 1); | 170 | omap_mpu_timer_start(0, (rate / HZ) - 1, 1); |
172 | 171 | ||
173 | clockevent_mpu_timer1.mult = div_sc(rate, NSEC_PER_SEC, | ||
174 | clockevent_mpu_timer1.shift); | ||
175 | clockevent_mpu_timer1.max_delta_ns = | ||
176 | clockevent_delta2ns(-1, &clockevent_mpu_timer1); | ||
177 | clockevent_mpu_timer1.min_delta_ns = | ||
178 | clockevent_delta2ns(1, &clockevent_mpu_timer1); | ||
179 | |||
180 | clockevent_mpu_timer1.cpumask = cpumask_of(0); | 172 | clockevent_mpu_timer1.cpumask = cpumask_of(0); |
181 | clockevents_register_device(&clockevent_mpu_timer1); | 173 | clockevents_config_and_register(&clockevent_mpu_timer1, rate, |
174 | 1, -1); | ||
182 | } | 175 | } |
183 | 176 | ||
184 | 177 | ||
@@ -236,12 +229,8 @@ static inline void omap_mpu_timer_init(void) | |||
236 | * Timer initialization | 229 | * Timer initialization |
237 | * --------------------------------------------------------------------------- | 230 | * --------------------------------------------------------------------------- |
238 | */ | 231 | */ |
239 | static void __init omap1_timer_init(void) | 232 | void __init omap1_timer_init(void) |
240 | { | 233 | { |
241 | if (omap_32k_timer_init() != 0) | 234 | if (omap_32k_timer_init() != 0) |
242 | omap_mpu_timer_init(); | 235 | omap_mpu_timer_init(); |
243 | } | 236 | } |
244 | |||
245 | struct sys_timer omap1_timer = { | ||
246 | .init = omap1_timer_init, | ||
247 | }; | ||
diff --git a/arch/arm/mach-omap1/timer32k.c b/arch/arm/mach-omap1/timer32k.c index 41152fadd4c0..0b74246ba62c 100644 --- a/arch/arm/mach-omap1/timer32k.c +++ b/arch/arm/mach-omap1/timer32k.c | |||
@@ -140,7 +140,6 @@ static void omap_32k_timer_set_mode(enum clock_event_mode mode, | |||
140 | static struct clock_event_device clockevent_32k_timer = { | 140 | static struct clock_event_device clockevent_32k_timer = { |
141 | .name = "32k-timer", | 141 | .name = "32k-timer", |
142 | .features = CLOCK_EVT_FEAT_PERIODIC | CLOCK_EVT_FEAT_ONESHOT, | 142 | .features = CLOCK_EVT_FEAT_PERIODIC | CLOCK_EVT_FEAT_ONESHOT, |
143 | .shift = 32, | ||
144 | .set_next_event = omap_32k_timer_set_next_event, | 143 | .set_next_event = omap_32k_timer_set_next_event, |
145 | .set_mode = omap_32k_timer_set_mode, | 144 | .set_mode = omap_32k_timer_set_mode, |
146 | }; | 145 | }; |
@@ -165,16 +164,9 @@ static __init void omap_init_32k_timer(void) | |||
165 | { | 164 | { |
166 | setup_irq(INT_OS_TIMER, &omap_32k_timer_irq); | 165 | setup_irq(INT_OS_TIMER, &omap_32k_timer_irq); |
167 | 166 | ||
168 | clockevent_32k_timer.mult = div_sc(OMAP_32K_TICKS_PER_SEC, | ||
169 | NSEC_PER_SEC, | ||
170 | clockevent_32k_timer.shift); | ||
171 | clockevent_32k_timer.max_delta_ns = | ||
172 | clockevent_delta2ns(0xfffffffe, &clockevent_32k_timer); | ||
173 | clockevent_32k_timer.min_delta_ns = | ||
174 | clockevent_delta2ns(1, &clockevent_32k_timer); | ||
175 | |||
176 | clockevent_32k_timer.cpumask = cpumask_of(0); | 167 | clockevent_32k_timer.cpumask = cpumask_of(0); |
177 | clockevents_register_device(&clockevent_32k_timer); | 168 | clockevents_config_and_register(&clockevent_32k_timer, |
169 | OMAP_32K_TICKS_PER_SEC, 1, 0xfffffffe); | ||
178 | } | 170 | } |
179 | 171 | ||
180 | /* | 172 | /* |
diff --git a/arch/arm/mach-omap1/usb.c b/arch/arm/mach-omap1/usb.c index 104fed366b8f..1a1db5971cd9 100644 --- a/arch/arm/mach-omap1/usb.c +++ b/arch/arm/mach-omap1/usb.c | |||
@@ -629,8 +629,14 @@ static void __init omap_1510_usb_init(struct omap_usb_config *config) | |||
629 | static inline void omap_1510_usb_init(struct omap_usb_config *config) {} | 629 | static inline void omap_1510_usb_init(struct omap_usb_config *config) {} |
630 | #endif | 630 | #endif |
631 | 631 | ||
632 | void __init omap1_usb_init(struct omap_usb_config *pdata) | 632 | void __init omap1_usb_init(struct omap_usb_config *_pdata) |
633 | { | 633 | { |
634 | struct omap_usb_config *pdata; | ||
635 | |||
636 | pdata = kmemdup(_pdata, sizeof(*pdata), GFP_KERNEL); | ||
637 | if (!pdata) | ||
638 | return; | ||
639 | |||
634 | pdata->usb0_init = omap1_usb0_init; | 640 | pdata->usb0_init = omap1_usb0_init; |
635 | pdata->usb1_init = omap1_usb1_init; | 641 | pdata->usb1_init = omap1_usb1_init; |
636 | pdata->usb2_init = omap1_usb2_init; | 642 | pdata->usb2_init = omap1_usb2_init; |