diff -urpN --exclude-from=/home/davej/.exclude bk-linus/arch/i386/kernel/apm.c linux-2.5/arch/i386/kernel/apm.c
--- bk-linus/arch/i386/kernel/apm.c	2002-11-21 02:09:29.000000000 +0000
+++ linux-2.5/arch/i386/kernel/apm.c	2002-11-21 17:55:00.000000000 +0000
@@ -1239,16 +1239,18 @@ static void get_time_diff(void)
 #endif
 }
 
-static inline void reinit_timer(void)
+static void reinit_timer(void)
 {
 #ifdef INIT_TIMER_AFTER_SUSPEND
+	unsigned long	flags;
+	extern spinlock_t i8253_lock;
+
+	spin_lock_irqsave(&i8253_lock, flags);
 	/* set the clock to 100 Hz */
 	outb_p(0x34,0x43);		/* binary, mode 2, LSB/MSB, ch 0 */
-	udelay(10);
 	outb_p(LATCH & 0xff , 0x40);	/* LSB */
-	udelay(10);
-	outb(LATCH >> 8 , 0x40);	/* MSB */
-	udelay(10);
+	outb_p(LATCH >> 8, 0x40);	/* MSB */
+	spin_unlock_irqrestore(&i8253_lock, flags);
 #endif
 }
 
diff -urpN --exclude-from=/home/davej/.exclude bk-linus/arch/i386/kernel/i8259.c linux-2.5/arch/i386/kernel/i8259.c
--- bk-linus/arch/i386/kernel/i8259.c	2002-11-21 02:09:29.000000000 +0000
+++ linux-2.5/arch/i386/kernel/i8259.c	2002-11-21 17:55:01.000000000 +0000
@@ -370,6 +370,8 @@ void __init init_ISA_irqs (void)
 void __init init_IRQ(void)
 {
 	int i;
+	extern spinlock_t i8253_lock;
+	unsigned long flags;
 
 	/* all the set up before the call gates are initialised */
 	pre_intr_init_hook();
@@ -393,9 +395,11 @@ void __init init_IRQ(void)
 	 * Set the clock to HZ Hz, we already have a valid
 	 * vector now:
 	 */
+	spin_lock_irqsave(&i8253_lock, flags);
 	outb_p(0x34,0x43);		/* binary, mode 2, LSB/MSB, ch 0 */
 	outb_p(LATCH & 0xff , 0x40);	/* LSB */
 	outb(LATCH >> 8 , 0x40);	/* MSB */
+	spin_unlock_irqrestore(&i8253_lock, flags);
 
 	/*
 	 * External FPU? Set up irq13 if so, for