aboutsummaryrefslogtreecommitdiffstats
path: root/xen/common/timer.c
diff options
context:
space:
mode:
authorkfraser@dhcp93.uk.xensource.com <kfraser@dhcp93.uk.xensource.com>2006-06-30 13:25:43 +0100
committerkfraser@dhcp93.uk.xensource.com <kfraser@dhcp93.uk.xensource.com>2006-06-30 13:25:43 +0100
commitae9bfcdced916158809e832ffca289761ab8d9cf (patch)
treea62d2319e6a77db62d9d1ebb431dabcf998b655e /xen/common/timer.c
parent0968f0be1f81bd75a465be5c9e7dc4469ce90d95 (diff)
downloadxen-ae9bfcdced916158809e832ffca289761ab8d9cf.tar.gz
xen-ae9bfcdced916158809e832ffca289761ab8d9cf.tar.bz2
xen-ae9bfcdced916158809e832ffca289761ab8d9cf.zip
[XEN] Various softirq cleanups. Main one is to always
call smp_processor_id() after any softirq, as rescheduling may cause us to move to another processor on ia64 (spotted by Isaku Yamahata). Also get rid of many direct callers of do_softirq() by creating new function process_pending_timers(). Signed-off-by: Keir Fraser <keir@xensource.com>
Diffstat (limited to 'xen/common/timer.c')
-rw-r--r--xen/common/timer.c9
1 files changed, 9 insertions, 0 deletions
diff --git a/xen/common/timer.c b/xen/common/timer.c
index 10985fdd8b..eb5636b51f 100644
--- a/xen/common/timer.c
+++ b/xen/common/timer.c
@@ -327,6 +327,15 @@ static void timer_softirq_action(void)
}
+void process_pending_timers(void)
+{
+ unsigned int cpu = smp_processor_id();
+ ASSERT(!in_irq() && local_irq_is_enabled());
+ if ( test_and_clear_bit(TIMER_SOFTIRQ, &softirq_pending(cpu)) )
+ timer_softirq_action();
+}
+
+
static void dump_timerq(unsigned char key)
{
struct timer *t;