Deleted Added
full compact
fasttrap.c (277914) fasttrap.c (277915)
1/*
2 * CDDL HEADER START
3 *
4 * The contents of this file are subject to the terms of the
5 * Common Development and Distribution License (the "License").
6 * You may not use this file except in compliance with the License.
7 *
8 * You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE

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

15 * If applicable, add the following below this CDDL HEADER, with the
16 * fields enclosed by brackets "[]" replaced with your own identifying
17 * information: Portions Copyright [yyyy] [name of copyright owner]
18 *
19 * CDDL HEADER END
20 *
21 * Portions Copyright 2010 The FreeBSD Foundation
22 *
1/*
2 * CDDL HEADER START
3 *
4 * The contents of this file are subject to the terms of the
5 * Common Development and Distribution License (the "License").
6 * You may not use this file except in compliance with the License.
7 *
8 * You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE

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

15 * If applicable, add the following below this CDDL HEADER, with the
16 * fields enclosed by brackets "[]" replaced with your own identifying
17 * information: Portions Copyright [yyyy] [name of copyright owner]
18 *
19 * CDDL HEADER END
20 *
21 * Portions Copyright 2010 The FreeBSD Foundation
22 *
23 * $FreeBSD: head/sys/cddl/contrib/opensolaris/uts/common/dtrace/fasttrap.c 277914 2015-01-30 04:51:59Z markj $
23 * $FreeBSD: head/sys/cddl/contrib/opensolaris/uts/common/dtrace/fasttrap.c 277915 2015-01-30 05:03:23Z markj $
24 */
25
26/*
27 * Copyright 2008 Sun Microsystems, Inc. All rights reserved.
28 * Use is subject to license terms.
29 */
30
31/*

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

1291 /*
1292 * We won't be able to acquire a /proc-esque lock on the process
1293 * iff the process is dead and gone. In this case, we rely on the
1294 * provider lock as a point of mutual exclusion to prevent other
1295 * DTrace consumers from disabling this probe.
1296 */
1297 if ((p = pfind(probe->ftp_pid)) != NULL) {
1298#ifdef __FreeBSD__
24 */
25
26/*
27 * Copyright 2008 Sun Microsystems, Inc. All rights reserved.
28 * Use is subject to license terms.
29 */
30
31/*

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

1291 /*
1292 * We won't be able to acquire a /proc-esque lock on the process
1293 * iff the process is dead and gone. In this case, we rely on the
1294 * provider lock as a point of mutual exclusion to prevent other
1295 * DTrace consumers from disabling this probe.
1296 */
1297 if ((p = pfind(probe->ftp_pid)) != NULL) {
1298#ifdef __FreeBSD__
1299 _PHOLD(p);
1300 PROC_UNLOCK(p);
1299 if (p->p_flag & P_WEXIT) {
1300 PROC_UNLOCK(p);
1301 p = NULL;
1302 } else {
1303 _PHOLD(p);
1304 PROC_UNLOCK(p);
1305 }
1301#endif
1302 }
1303
1304 /*
1305 * Disable all the associated tracepoints (for fully enabled probes).
1306 */
1307 if (probe->ftp_enabled) {
1308 for (i = 0; i < probe->ftp_ntps; i++) {

--- 1420 unchanged lines hidden ---
1306#endif
1307 }
1308
1309 /*
1310 * Disable all the associated tracepoints (for fully enabled probes).
1311 */
1312 if (probe->ftp_enabled) {
1313 for (i = 0; i < probe->ftp_ntps; i++) {

--- 1420 unchanged lines hidden ---