/*
* CDDL HEADER START
*
* The contents of this file are subject to the terms of the
* Common Development and Distribution License (the "License").
* You may not use this file except in compliance with the License.
*
* You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
* See the License for the specific language governing permissions
* and limitations under the License.
*
* When distributing Covered Code, include this CDDL HEADER in each
* file and include the License file at usr/src/OPENSOLARIS.LICENSE.
* If applicable, add the following below this CDDL HEADER, with the
* fields enclosed by brackets "[]" replaced with your own identifying
* information: Portions Copyright [yyyy] [name of copyright owner]
*
* CDDL HEADER END
*/
/*
* Copyright 2009 Sun Microsystems, Inc. All rights reserved.
* Use is subject to license terms.
*/
#ifndef _SYS_STRFT_H
#define _SYS_STRFT_H
#ifdef __cplusplus
extern "C" {
#endif
/*
* The flow trace subsystem is used to trace the flow of STREAMS messages
* through a stream.
*
* WARNING: this is a private subsystem and subject to change at any time!
*/
/*
* Some evnt defines, values 0..N are reserved for internal use,
* flag bits reserved for internal use.
*/
/*
* Stack information for each flow trace event; recorded when str_ftstack
* is non-zero.
*/
typedef struct ftstk {
} ftstk_t;
/*
* as to its use yet: RSF). There is one per event. Every time str_ftevent()
* is called, one of the indices is filled in with this data.
*/
typedef struct ftevnt {
} ftevnt_t;
/*
* A linked list of ftevnt arrays.
*/
typedef struct ftblk {
} ftblk_t;
/*
* The flow trace header (start of event list). It consists of the
* current writable block (tail)
* a hash value (for recovering trace information)
* The last thread to process an event
* The last cpu to process an event
* The start of the list
* This structure is attached to a dblk, and traces a message through
* a flow.
*/
typedef struct fthdr {
void *thread;
int cpu_seqid;
} fthdr_t;
#ifdef _KERNEL
struct datab;
extern void str_ftfree(struct datab *);
extern int str_ftnever, str_ftstack;
/*
* Allocate flow-trace information and record an allocation event.
*/
if (str_ftnever == 0) { \
\
} \
} \
}
/*
* Add a flow-trace event to the passed-in mblk_t and any other mblk_t's
* chained off of b_cont.
*/
if (str_ftnever == 0) { \
\
str_ftevent(_hp, (p), (e), (d)); \
} \
} \
}
/*
* Add a flow-trace event to *just* the passed-in mblk_t.
*/
if (str_ftnever == 0) { \
\
str_ftevent(_hp, (p), (e), (d)); \
} \
}
#endif /* _KERNEL */
#ifdef __cplusplus
}
#endif
#endif /* _SYS_STRFT_H */