patch-2.1.79 linux/arch/sparc/kernel/smp.c

Next file: linux/arch/sparc/kernel/sparc-stub.c
Previous file: linux/arch/sparc/kernel/signal.c
Back to the patch index
Back to the overall index

diff -u --recursive --new-file v2.1.78/linux/arch/sparc/kernel/smp.c linux/arch/sparc/kernel/smp.c
@@ -558,7 +558,7 @@
 /* Reschedule call back. */
 void smp_reschedule_irq(void)
 {
-	resched_force();
+	need_resched = 1;
 }
 
 /* Running cross calls. */
@@ -583,6 +583,8 @@
 /* Protects counters touched during level14 ticker */
 spinlock_t ticker_lock = SPIN_LOCK_UNLOCKED;
 
+#ifdef CONFIG_PROFILE
+
 /* 32-bit Sparc specific profiling function. */
 static inline void sparc_do_profile(unsigned long pc)
 {
@@ -601,6 +603,8 @@
 	}
 }
 
+#endif
+
 volatile unsigned long smp_local_timer_ticks[1+NR_CPUS]={0,};
 
 unsigned int prof_multiplier[NR_CPUS];
@@ -614,8 +618,10 @@
 	int cpu = smp_processor_id();
 
 	clear_profile_irq(mid_xlate[cpu]);
+#ifdef CONFIG_PROFILE
 	if(!user_mode(regs))
 		sparc_do_profile(regs->pc);
+#endif
 	if(!--prof_counter[cpu]) {
 		int user = user_mode(regs);
 		if(current->pid) {
@@ -623,7 +629,7 @@
 
 			if(--current->counter < 0) {
 				current->counter = 0;
-				resched_force();
+				need_resched = 1;
 			}
 
 			spin_lock(&ticker_lock);

FUNET's LINUX-ADM group, linux-adm@nic.funet.fi
TCL-scripts by Sam Shen, slshen@lbl.gov