Print this page
*** NO COMMENTS ***
*** 17,27 ****
* information: Portions Copyright [yyyy] [name of copyright owner]
*
* CDDL HEADER END
*/
/*
! * Copyright 2007 Sun Microsystems, Inc. All rights reserved.
* Use is subject to license terms.
*/
#pragma ident "%Z%%M% %I% %E% SMI"
--- 17,27 ----
* information: Portions Copyright [yyyy] [name of copyright owner]
*
* CDDL HEADER END
*/
/*
! * Copyright 2008 Sun Microsystems, Inc. All rights reserved.
* Use is subject to license terms.
*/
#pragma ident "%Z%%M% %I% %E% SMI"
*** 181,190 ****
--- 181,197 ----
* additional arg6 from the ip:::send and ip:::recieve probes, and translate
* them to an ifinfo_t.
*/
typedef ill_t __dtrace_ipsr_ill_t;
+ /*
+ * __dtrace_tcpf_ipinfo_t is used by the translators to construct an
+ * ipinfo_t during tcp fusion, from a tcp_t plus an additional arg4 for
+ * the payload bytes.
+ */
+ typedef tcp_t __dtrace_tcpf_ipinfo_t;
+
#pragma D binding "1.0" translator
translator pktinfo_t < mblk_t *M > {
pkt_addr = NULL;
};
*** 224,233 ****
--- 231,252 ----
ip_daddr = I != NULL ? (*(uint8_t *)I >> 4 == 4 ?
inet_ntoa(&((ipha_t *)I)->ipha_dst) : *(uint8_t *)I >> 4 == 6 ?
inet_ntoa6(&((ip6_t *)I)->ip6_dst) : "<unknown>") : "<unknown>";
};
+ #pragma D binding "1.0" translator
+ translator ipinfo_t < __dtrace_tcpf_ipinfo_t *T > {
+ ip_ver = T->tcp_ipversion;
+ ip_plength = arg4; /* probe dependent */
+ ip_saddr = inet_ntoa6(probename == "send" ?
+ &T->tcp_connp->connua_v6addr.connua_laddr :
+ &T->tcp_connp->connua_v6addr.connua_faddr);
+ ip_daddr = inet_ntoa6(probename == "send" ?
+ &T->tcp_connp->connua_v6addr.connua_faddr :
+ &T->tcp_connp->connua_v6addr.connua_laddr);
+ };
+
#pragma D binding "1.0" translator
translator ifinfo_t < __dtrace_ipsr_ill_t *I > {
if_name = I != NULL ? stringof(I->ill_name) : "<null>";
if_ipstack = I != NULL ? I->ill_ipst->ips_netstack->netstack_stackid
: 0;