[PATCH v3 2/5] drm: Add private data field to trace control block

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



This field can be used by the decode functions of a syscall. The main
usecase for now is to allow storing the driver name for drm devices
across the lifetime of a trace control block. This allows us to do the
driver identification once and reuse the information in all the decode
stages of the ioctl.

* defs.h: Add private data field in struct tcb

Signed-off-by: Patrik Jakobsson <patrik.jakobsson@xxxxxxxxxxxxxxx>
---
 defs.h | 7 +++++++
 1 file changed, 7 insertions(+)

diff --git a/defs.h b/defs.h
index c02f810..5b0670e 100644
--- a/defs.h
+++ b/defs.h
@@ -266,6 +266,13 @@ struct tcb {
 	int u_error;		/* Error code */
 	long scno;		/* System call number */
 	long u_arg[MAX_ARGS];	/* System call arguments */
+
+	/*
+	 * Private data for the decoding functions of the syscall. TCB core does
+	 * _not_ handle allocation / deallocation of this data.
+	 */
+	void *priv_data;
+
 #if defined(LINUX_MIPSN32) || defined(X32)
 	long long ext_arg[MAX_ARGS];
 	long long u_lrval;	/* long long return value */
-- 
2.1.4

_______________________________________________
Intel-gfx mailing list
Intel-gfx@xxxxxxxxxxxxxxxxxxxxx
http://lists.freedesktop.org/mailman/listinfo/intel-gfx




[Index of Archives]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]
  Powered by Linux