Re: [bugfix] SMP, shm-2.3.52-A0

From: Manfred Spraul (manfreds@colorfullife.com)
Date: Fri Mar 17 2000 - 19:14:56 EST


From: "Ingo Molnar" <mingo@chiara.csoma.elte.hu>
>
> > + KASSERT(spin_is_locked(&kernel_flag));
>
> this is more readable i believe:
>
> if (!spin_is_locked(&kernel_flag))
> BUG();
>
> we have been adding such asserts since early 2.3. Btw., the dentry-assert
> should be done in namei.c and dentry.c, not open.c, this is how i caught
> the bug.

Will BUG() remain enabled in 2.4?
I always assumed that BUG() is the replacement for "*(int*)0=0", and that it
remains enabled in 2.4.

KASSERT() could be disabled in 2.4, and thus we could add such tests even to
time critical functions [I hope WAITQUEUE_DEBUG, SPINLOCK_DEBUG, the BUG()
in unlock_kernel() get disabled/removed before 2.4]

--
    Manfred

- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.rutgers.edu Please read the FAQ at http://www.tux.org/lkml/



This archive was generated by hypermail 2b29 : Thu Mar 23 2000 - 21:00:23 EST