Messages in this thread Patch in this message | | | From | Stoyan Gaydarov <> | Subject | [PATCH 16/25] [m32r] BUG to BUG_ON changes | Date | Tue, 10 Mar 2009 00:10:41 -0500 |
| |
Signed-off-by: Stoyan Gaydarov <stoyboyker@gmail.com> --- arch/m32r/kernel/setup.c | 3 +-- arch/m32r/kernel/smp.c | 9 +++------ 2 files changed, 4 insertions(+), 8 deletions(-)
diff --git a/arch/m32r/kernel/setup.c b/arch/m32r/kernel/setup.c index 0392112..6e119ee 100644 --- a/arch/m32r/kernel/setup.c +++ b/arch/m32r/kernel/setup.c @@ -402,8 +402,7 @@ void __init cpu_init (void) /* Set up and load the per-CPU TSS and LDT */ atomic_inc(&init_mm.mm_count); current->active_mm = &init_mm; - if (current->mm) - BUG(); + BUG_ON(current->mm); /* Force FPU initialization */ current_thread_info()->status = 0; diff --git a/arch/m32r/kernel/smp.c b/arch/m32r/kernel/smp.c index 929e5c9..17c96bb 100644 --- a/arch/m32r/kernel/smp.c +++ b/arch/m32r/kernel/smp.c @@ -338,8 +338,7 @@ void smp_flush_tlb_page(struct vm_area_struct *vma, unsigned long va) cpu_clear(cpu_id, cpu_mask); #ifdef DEBUG_SMP - if (!mm) - BUG(); + BUG_ON(!mm); #endif if (*mmc != NO_CONTEXT) { @@ -385,8 +384,7 @@ static void flush_tlb_others(cpumask_t cpumask, struct mm_struct *mm, #ifdef DEBUG_SMP unsigned long flags; __save_flags(flags); - if (!(flags & 0x0040)) /* Interrupt Disable NONONO */ - BUG(); + BUG_ON(!(flags & 0x0040)); /* Interrupt Disable NONONO */ #endif /* DEBUG_SMP */ /* @@ -805,8 +803,7 @@ unsigned long send_IPI_mask_phys(cpumask_t physid_mask, int ipi_num, if (mask & ~physids_coerce(phys_cpu_present_map)) BUG(); - if (ipi_num >= NR_IPIS) - BUG(); + BUG_ON(ipi_num >= NR_IPIS); mask <<= IPI_SHIFT; ipilock = &ipi_lock[ipi_num]; -- 1.6.1.3
| |