I am running a MIPS machine and hit the following BUG() in
kernel/sched.c:650:

        prepare_to_switch();
        {
                struct mm_struct *mm = next->mm;
                struct mm_struct *oldmm = prev->active_mm;
                if (!mm) {
                        if (next->active_mm) BUG();           <======
                        next->active_mm = oldmm;
                        atomic_inc(&oldmm->mm_count);
                        enter_lazy_tlb(oldmm, next, this_cpu);
                } else {
                        if (next->active_mm != mm) BUG();
                        switch_mm(oldmm, mm, next, this_cpu);
                }


The "next" processor is swapper.

I have not looked at it hard enough, but an initial investigation seems
to reveal the cause trivially.  

In include/linux/sched.h, the "swapper" task is set such that 'mm' is
NULL and 'active_mm' is &init_mm.  So obviously when we switch back to
"swapper" task, we will hit the BUG().  

That sounds little too obvious to be true.  What am I missing here? 

Thanks in advance.  Please cc your reply to this email account.  I
appreciate that.

Jun

__________________________________________________
Do You Yahoo!?
Get personalized email addresses from Yahoo! Mail
http://personal.mail.yahoo.com/
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Reply via email to