[DTrace-devel] [PATCH 02/38] Move dt_spec_buf_data_t and dt_spec_buf_t into dt_consume.c

eugene.loh at oracle.com eugene.loh at oracle.com
Thu Jun 27 05:34:19 UTC 2024


From: Eugene Loh <eugene.loh at oracle.com>

Signed-off-by: Eugene Loh <eugene.loh at oracle.com>
---
 libdtrace/dt_consume.c | 18 ++++++++++++++++++
 libdtrace/dt_impl.h    | 18 ------------------
 2 files changed, 18 insertions(+), 18 deletions(-)

diff --git a/libdtrace/dt_consume.c b/libdtrace/dt_consume.c
index dec2314b..5fb636fe 100644
--- a/libdtrace/dt_consume.c
+++ b/libdtrace/dt_consume.c
@@ -27,6 +27,24 @@
 
 #define	DT_MASK_LO 0x00000000FFFFFFFFULL
 
+typedef struct dt_spec_buf_data {
+	dt_list_t dsbd_list;		/* linked-list forward/back pointers */
+	unsigned int dsbd_cpu;		/* cpu for data */
+	char *dsbd_data;		/* data for later processing */
+	uint32_t dsbd_size;		/* size of data */
+} dt_spec_buf_data_t;
+
+typedef struct dt_spec_buf {
+	dtrace_hdl_t *dtsb_dtp;		/* backpointer to the dtrace instance */
+	int32_t dtsb_id;		/* speculation ID */
+	size_t dtsb_size;		/* size of all buffers in this spec */
+	int dtsb_committing;		/* when draining, nonzero if commit */
+	dt_bpf_specs_t dtsb_spec;	/* bpf-side specs record for this spec
+					   (buffer read/write counts).  */
+	dt_list_t dtsb_dsbd_list;	/* list of dt_spec_bufs */
+	struct dt_hentry dtsb_he;	/* htab links */
+} dt_spec_buf_t;
+
 /*
  * We declare this here because (1) we need it and (2) we want to avoid a
  * dependency on libm in libdtrace.
diff --git a/libdtrace/dt_impl.h b/libdtrace/dt_impl.h
index 01313ff3..b5408c1c 100644
--- a/libdtrace/dt_impl.h
+++ b/libdtrace/dt_impl.h
@@ -269,24 +269,6 @@ typedef struct dt_lib_depend {
 	dt_list_t dtld_dependents;	/* linked-list of lib dependents */
 } dt_lib_depend_t;
 
-typedef struct dt_spec_buf_data {
-	dt_list_t dsbd_list;		/* linked-list forward/back pointers */
-	unsigned int dsbd_cpu;		/* cpu for data */
-	char *dsbd_data;		/* data for later processing */
-	uint32_t dsbd_size;		/* size of data */
-} dt_spec_buf_data_t;
-
-typedef struct dt_spec_buf {
-	dtrace_hdl_t *dtsb_dtp;		/* backpointer to the dtrace instance */
-	int32_t dtsb_id;		/* speculation ID */
-	size_t dtsb_size;		/* size of all buffers in this spec */
-	int dtsb_committing;		/* when draining, nonzero if commit */
-	dt_bpf_specs_t dtsb_spec;	/* bpf-side specs record for this spec
-					   (buffer read/write counts).  */
-	dt_list_t dtsb_dsbd_list;	/* list of dt_spec_bufs */
-	struct dt_hentry dtsb_he;	/* htab links */
-} dt_spec_buf_t;
-
 typedef struct dt_percpu_drops {
 	uint64_t	buf;		/* principal buffer drops */
 	uint64_t	agg;		/* aggregate buffer drops */
-- 
2.18.4




More information about the DTrace-devel mailing list