balance_irq()'s move() hang in machine_restart()
Ingo,
The method suggested at the following link does not work.
http://www.ussg.iu.edu/hypermail/linux/kernel/0304.1/0558.html
smp_call-function(stop_this_cpu, NULL, 1, 1) will never return from the for loop.
Source from http://lxr.linux.no/source/arch/i386/kernel/smp.c#L569
569 static void stop_this_cpu (void * dummy)
570 {
571 /*
572 * Remove this CPU:
573 */
574 clear_bit(smp_processor_id(), &cpu_online_map); 575 __cli(); 576 disable_local_APIC(); 577 if (cpu_data[smp_processor_id()].hlt_works_ok)
578 for(;;) __asm__("hlt");
579 for(;;)
580}
The following fix seemed to break this infinite loop. Is this proper?
---linux.saved/arch/i386/kernel/io_apic.c Thu Jun 26 05:37:25 2003
+++ linux/arch/i386/kernel/io_apic.c Thu Jun 26 05:39:15 2003
@@ -228,6 +228,10 @@
if (unlikely(cpu == curr_cpu))
search_idle = 0; inside:
+ if (unlikely(smp_num_cpus == 1)) {
+ return curr_cpu;
+ }
+
if (direction == 1) {
cpu++;
if (cpu >= smp_num_cpus)Thanks,
Prasanna.
__________________________________
Do you Yahoo!?
SBC Yahoo! DSL - Now only $29.95 per month!
http://sbc.yahoo.com