diff options
author | Russell King <rmk+kernel@arm.linux.org.uk> | 2010-02-15 16:20:33 -0500 |
---|---|---|
committer | Russell King <rmk+kernel@arm.linux.org.uk> | 2010-02-15 16:20:33 -0500 |
commit | 2f68ffd11aa76b251921976c982b814df9ebe890 (patch) | |
tree | f117190925b6e9eca9025ded221f1da7cb298861 /arch/arm/mach-pxa | |
parent | 56012808f4d5606e401539f663d92009d964425b (diff) | |
parent | a602f0f2f04f150fa1f7312b9e601e8e1a5afe10 (diff) |
Merge branch 'arm/clock-event' of git://git.pengutronix.de/git/ukl/linux-2.6 into devel-stable
Diffstat (limited to 'arch/arm/mach-pxa')
-rw-r--r-- | arch/arm/mach-pxa/time.c | 10 |
1 files changed, 1 insertions, 9 deletions
diff --git a/arch/arm/mach-pxa/time.c b/arch/arm/mach-pxa/time.c index 750c448db672..293e40aeaf29 100644 --- a/arch/arm/mach-pxa/time.c +++ b/arch/arm/mach-pxa/time.c | |||
@@ -76,14 +76,12 @@ pxa_ost0_interrupt(int irq, void *dev_id) | |||
76 | static int | 76 | static int |
77 | pxa_osmr0_set_next_event(unsigned long delta, struct clock_event_device *dev) | 77 | pxa_osmr0_set_next_event(unsigned long delta, struct clock_event_device *dev) |
78 | { | 78 | { |
79 | unsigned long flags, next, oscr; | 79 | unsigned long next, oscr; |
80 | 80 | ||
81 | raw_local_irq_save(flags); | ||
82 | OIER |= OIER_E0; | 81 | OIER |= OIER_E0; |
83 | next = OSCR + delta; | 82 | next = OSCR + delta; |
84 | OSMR0 = next; | 83 | OSMR0 = next; |
85 | oscr = OSCR; | 84 | oscr = OSCR; |
86 | raw_local_irq_restore(flags); | ||
87 | 85 | ||
88 | return (signed)(next - oscr) <= MIN_OSCR_DELTA ? -ETIME : 0; | 86 | return (signed)(next - oscr) <= MIN_OSCR_DELTA ? -ETIME : 0; |
89 | } | 87 | } |
@@ -91,23 +89,17 @@ pxa_osmr0_set_next_event(unsigned long delta, struct clock_event_device *dev) | |||
91 | static void | 89 | static void |
92 | pxa_osmr0_set_mode(enum clock_event_mode mode, struct clock_event_device *dev) | 90 | pxa_osmr0_set_mode(enum clock_event_mode mode, struct clock_event_device *dev) |
93 | { | 91 | { |
94 | unsigned long irqflags; | ||
95 | |||
96 | switch (mode) { | 92 | switch (mode) { |
97 | case CLOCK_EVT_MODE_ONESHOT: | 93 | case CLOCK_EVT_MODE_ONESHOT: |
98 | raw_local_irq_save(irqflags); | ||
99 | OIER &= ~OIER_E0; | 94 | OIER &= ~OIER_E0; |
100 | OSSR = OSSR_M0; | 95 | OSSR = OSSR_M0; |
101 | raw_local_irq_restore(irqflags); | ||
102 | break; | 96 | break; |
103 | 97 | ||
104 | case CLOCK_EVT_MODE_UNUSED: | 98 | case CLOCK_EVT_MODE_UNUSED: |
105 | case CLOCK_EVT_MODE_SHUTDOWN: | 99 | case CLOCK_EVT_MODE_SHUTDOWN: |
106 | /* initializing, released, or preparing for suspend */ | 100 | /* initializing, released, or preparing for suspend */ |
107 | raw_local_irq_save(irqflags); | ||
108 | OIER &= ~OIER_E0; | 101 | OIER &= ~OIER_E0; |
109 | OSSR = OSSR_M0; | 102 | OSSR = OSSR_M0; |
110 | raw_local_irq_restore(irqflags); | ||
111 | break; | 103 | break; |
112 | 104 | ||
113 | case CLOCK_EVT_MODE_RESUME: | 105 | case CLOCK_EVT_MODE_RESUME: |