Deleted Added
full compact
kern_synch.c (104295) kern_synch.c (104387)
1/*-
2 * Copyright (c) 1982, 1986, 1990, 1991, 1993
3 * The Regents of the University of California. All rights reserved.
4 * (c) UNIX System Laboratories, Inc.
5 * All or some portions of this file are derived from material licensed
6 * to the University of California by American Telephone and Telegraph
7 * Co. or Unix System Laboratories, Inc. and are reproduced herein with
8 * the permission of UNIX System Laboratories, Inc.

--- 22 unchanged lines hidden (view full) ---

31 * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
32 * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
33 * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
34 * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
35 * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
36 * SUCH DAMAGE.
37 *
38 * @(#)kern_synch.c 8.9 (Berkeley) 5/19/95
1/*-
2 * Copyright (c) 1982, 1986, 1990, 1991, 1993
3 * The Regents of the University of California. All rights reserved.
4 * (c) UNIX System Laboratories, Inc.
5 * All or some portions of this file are derived from material licensed
6 * to the University of California by American Telephone and Telegraph
7 * Co. or Unix System Laboratories, Inc. and are reproduced herein with
8 * the permission of UNIX System Laboratories, Inc.

--- 22 unchanged lines hidden (view full) ---

31 * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
32 * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
33 * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
34 * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
35 * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
36 * SUCH DAMAGE.
37 *
38 * @(#)kern_synch.c 8.9 (Berkeley) 5/19/95
39 * $FreeBSD: head/sys/kern/kern_synch.c 104295 2002-10-01 14:10:08Z jhb $
39 * $FreeBSD: head/sys/kern/kern_synch.c 104387 2002-10-02 20:31:47Z jhb $
40 */
41
42#include "opt_ddb.h"
43#include "opt_ktrace.h"
44
45#include <sys/param.h>
46#include <sys/systm.h>
47#include <sys/condvar.h>

--- 706 unchanged lines hidden (view full) ---

754 struct proc *p = td->td_proc; /* XXX */
755 struct kse *ke = td->td_kse;
756 u_int sched_nest;
757
758 mtx_assert(&sched_lock, MA_OWNED | MA_NOTRECURSED);
759 KASSERT((ke->ke_state == KES_THREAD), ("mi_switch: kse state?"));
760 KASSERT(!TD_ON_RUNQ(td), ("mi_switch: called by old code"));
761#ifdef INVARIANTS
40 */
41
42#include "opt_ddb.h"
43#include "opt_ktrace.h"
44
45#include <sys/param.h>
46#include <sys/systm.h>
47#include <sys/condvar.h>

--- 706 unchanged lines hidden (view full) ---

754 struct proc *p = td->td_proc; /* XXX */
755 struct kse *ke = td->td_kse;
756 u_int sched_nest;
757
758 mtx_assert(&sched_lock, MA_OWNED | MA_NOTRECURSED);
759 KASSERT((ke->ke_state == KES_THREAD), ("mi_switch: kse state?"));
760 KASSERT(!TD_ON_RUNQ(td), ("mi_switch: called by old code"));
761#ifdef INVARIANTS
762 if (!TD_ON_MUTEX(td) &&
762 if (!TD_ON_LOCK(td) &&
763 !TD_ON_RUNQ(td) &&
764 !TD_IS_RUNNING(td))
765 mtx_assert(&Giant, MA_NOTOWNED);
766#endif
767 KASSERT(td->td_critnest == 1,
768 ("mi_switch: switch in a critical section"));
769
770 /*

--- 279 unchanged lines hidden ---
763 !TD_ON_RUNQ(td) &&
764 !TD_IS_RUNNING(td))
765 mtx_assert(&Giant, MA_NOTOWNED);
766#endif
767 KASSERT(td->td_critnest == 1,
768 ("mi_switch: switch in a critical section"));
769
770 /*

--- 279 unchanged lines hidden ---