public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
* BUG() triggered on SMP shutdown, cpu!=0
@ 2002-09-18 10:20 J.A. Magallon
  2002-09-18 10:41 ` Alan Cox
  0 siblings, 1 reply; 4+ messages in thread
From: J.A. Magallon @ 2002-09-18 10:20 UTC (permalink / raw)
  To: Lista Linux-Kernel

Hi all...

I am getting oopses on shutdown, 'cause this bug is popping:

static void apm_power_off(void)
{
    unsigned char   po_bios_call[] = {
        0xb8, 0x00, 0x10,   /* movw  $0x1000,ax  */
        0x8e, 0xd0,     /* movw  ax,ss       */
        0xbc, 0x00, 0xf0,   /* movw  $0xf000,sp  */
        0xb8, 0x07, 0x53,   /* movw  $0x5307,ax  */
        0xbb, 0x01, 0x00,   /* movw  $0x0001,bx  */
        0xb9, 0x03, 0x00,   /* movw  $0x0003,cx  */
        0xcd, 0x15      /* int   $0x15       */
    };

    /*
     * This may be called on an SMP machine.
     */
#ifdef CONFIG_SMP
    /* Some bioses don't like being called from CPU != 0 */
    if (cpu_number_map(smp_processor_id()) != 0) {
        current->cpus_allowed = 1;
        schedule();
        if (unlikely(cpu_number_map(smp_processor_id()) != 0))
            BUG();
    }
#endif
    if (apm_info.realmode_power_off)
        machine_real_restart(po_bios_call, sizeof(po_bios_call));
    else
        (void) set_system_power_state(APM_STATE_OFF);
}

Does this mean that after the schedule() kernel is still in CPU1 ???
Will add a couple ptintks....
This is 2.4.19-pre7+aa patches.

TIA

-- 
J.A. Magallon <jamagallon@able.es>      \                 Software is like sex:
werewolf.able.es                         \           It's better when it's free
Mandrake Linux release 9.0 (Cooker) for i586
Linux 2.4.20-pre7-jam0 (gcc 3.2 (Mandrake Linux 9.0 3.2-1mdk))

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: BUG() triggered on SMP shutdown, cpu!=0
  2002-09-18 10:41 ` Alan Cox
@ 2002-09-18 10:39   ` J.A. Magallon
  2002-09-18 11:20   ` J.A. Magallon
  1 sibling, 0 replies; 4+ messages in thread
From: J.A. Magallon @ 2002-09-18 10:39 UTC (permalink / raw)
  To: Alan Cox; +Cc: Lista Linux-Kernel


On 2002.09.18 Alan Cox wrote:
>On Wed, 2002-09-18 at 11:20, J.A. Magallon wrote:
>> Hi all...
>> 
>> I am getting oopses on shutdown, 'cause this bug is popping:
>
>That doesnt suprise me. The code assumes the old scheduler and -aa has
>the O(1) scheduler. Grab the fix to that small piece of code from -ac,
>or I'm pretty sure from a newer Andrea tree
>

Thanks, I was suspecting something like that...

-- 
J.A. Magallon <jamagallon@able.es>      \                 Software is like sex:
werewolf.able.es                         \           It's better when it's free
Mandrake Linux release 9.0 (Cooker) for i586
Linux 2.4.20-pre7-jam0 (gcc 3.2 (Mandrake Linux 9.0 3.2-1mdk))

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: BUG() triggered on SMP shutdown, cpu!=0
  2002-09-18 10:20 BUG() triggered on SMP shutdown, cpu!=0 J.A. Magallon
@ 2002-09-18 10:41 ` Alan Cox
  2002-09-18 10:39   ` J.A. Magallon
  2002-09-18 11:20   ` J.A. Magallon
  0 siblings, 2 replies; 4+ messages in thread
From: Alan Cox @ 2002-09-18 10:41 UTC (permalink / raw)
  To: J.A. Magallon; +Cc: Lista Linux-Kernel

On Wed, 2002-09-18 at 11:20, J.A. Magallon wrote:
> Hi all...
> 
> I am getting oopses on shutdown, 'cause this bug is popping:

That doesnt suprise me. The code assumes the old scheduler and -aa has
the O(1) scheduler. Grab the fix to that small piece of code from -ac,
or I'm pretty sure from a newer Andrea tree


^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: BUG() triggered on SMP shutdown, cpu!=0
  2002-09-18 10:41 ` Alan Cox
  2002-09-18 10:39   ` J.A. Magallon
@ 2002-09-18 11:20   ` J.A. Magallon
  1 sibling, 0 replies; 4+ messages in thread
From: J.A. Magallon @ 2002-09-18 11:20 UTC (permalink / raw)
  To: Alan Cox; +Cc: Lista Linux-Kernel


On 2002.09.18 Alan Cox wrote:
>On Wed, 2002-09-18 at 11:20, J.A. Magallon wrote:
>> Hi all...
>> 
>> I am getting oopses on shutdown, 'cause this bug is popping:
>
>That doesnt suprise me. The code assumes the old scheduler and -aa has
>the O(1) scheduler. Grab the fix to that small piece of code from -ac,
>or I'm pretty sure from a newer Andrea tree
>

I took the chages to apm.c from -ac and it works ok now.
Latest -aa is 2.4.20-pre5-aa2 and does not include this.
I will send it to Andrea.

Thanks.

-- 
J.A. Magallon <jamagallon@able.es>      \                 Software is like sex:
werewolf.able.es                         \           It's better when it's free
Mandrake Linux release 9.0 (Cooker) for i586
Linux 2.4.20-pre7-jam0 (gcc 3.2 (Mandrake Linux 9.0 3.2-1mdk))

^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2002-09-18 11:16 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2002-09-18 10:20 BUG() triggered on SMP shutdown, cpu!=0 J.A. Magallon
2002-09-18 10:41 ` Alan Cox
2002-09-18 10:39   ` J.A. Magallon
2002-09-18 11:20   ` J.A. Magallon

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox