svn commit: r200135 - stable/8/sys/sys

Bjoern A. Zeeb bz at FreeBSD.org
Sat Dec 5 18:54:22 UTC 2009


Author: bz
Date: Sat Dec  5 18:54:21 2009
New Revision: 200135
URL: http://svn.freebsd.org/changeset/base/200135

Log:
  MFC r199883:
    Add SDT_PROBE[1-5] in the same way we have SDT_PROBE_DEFINE[1-5] to
    avoid having to add all the unused trailing arguments as zeros.

Modified:
  stable/8/sys/sys/sdt.h
Directory Properties:
  stable/8/sys/   (props changed)
  stable/8/sys/amd64/include/xen/   (props changed)
  stable/8/sys/cddl/contrib/opensolaris/   (props changed)
  stable/8/sys/contrib/dev/acpica/   (props changed)
  stable/8/sys/contrib/pf/   (props changed)
  stable/8/sys/dev/xen/xenpci/   (props changed)

Modified: stable/8/sys/sys/sdt.h
==============================================================================
--- stable/8/sys/sys/sdt.h	Sat Dec  5 18:53:04 2009	(r200134)
+++ stable/8/sys/sys/sdt.h	Sat Dec  5 18:54:21 2009	(r200135)
@@ -59,6 +59,12 @@
 #define	SDT_PROBE_DEFINE4(prov, mod, func, name, arg0, arg1, arg2, arg3)
 #define	SDT_PROBE_DEFINE5(prov, mod, func, name, arg0, arg1, arg2, arg3, arg4)
 
+#define	SDT_PROBE1(prov, mod, func, name, arg0)
+#define	SDT_PROBE2(prov, mod, func, name, arg0, arg1)
+#define	SDT_PROBE3(prov, mod, func, name, arg0, arg1, arg2)
+#define	SDT_PROBE4(prov, mod, func, name, arg0, arg1, arg2, arg3)
+#define	SDT_PROBE5(prov, mod, func, name, arg0, arg1, arg2, arg3, arg4)
+
 #else
 
 /*
@@ -192,6 +198,17 @@ struct sdt_provider {
 	SDT_PROBE_ARGTYPE(prov, mod, func, name, 3, arg3);		\
 	SDT_PROBE_ARGTYPE(prov, mod, func, name, 4, arg4)
 
+#define	SDT_PROBE1(prov, mod, func, name, arg0)				\
+	SDT_PROBE(prov, mod, func, name, arg0, 0, 0, 0, 0)
+#define	SDT_PROBE2(prov, mod, func, name, arg0, arg1)			\
+	SDT_PROBE(prov, mod, func, name, arg0, arg1, 0, 0, 0)
+#define	SDT_PROBE3(prov, mod, func, name, arg0, arg1, arg2)		\
+	SDT_PROBE(prov, mod, func, name, arg0, arg1, arg2,  0, 0)
+#define	SDT_PROBE4(prov, mod, func, name, arg0, arg1, arg2, arg3)	\
+	SDT_PROBE(prov, mod, func, name, arg0, arg1, arg2, arg3, 0)
+#define	SDT_PROBE5(prov, mod, func, name, arg0, arg1, arg2, arg3, arg4) \
+	SDT_PROBE(prov, mod, func, name, arg0, arg1, arg2, arg3, arg4)
+
 typedef int (*sdt_argtype_listall_func_t)(struct sdt_argtype *, void *);
 typedef int (*sdt_probe_listall_func_t)(struct sdt_probe *, void *);
 typedef int (*sdt_provider_listall_func_t)(struct sdt_provider *, void *);


More information about the svn-src-stable mailing list