[PATCH 04/27] usb: chipidea: convert events to tracepoints

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

 



As part of the legacy from the original driver design, we retain home-grown
tracing infrastructure, complete with own ring buffer and timestamps. While
it is useful for debugging certain cases, it's a lot of extra code, which
these days is rather redundant.

This patch replaces local tracing functionality with kernel tracepoints,
thus getting rid of the ring buffer and all the maintenance code, while
making use of standard kernel infrastructure.

Signed-off-by: Alexander Shishkin <alexander.shishkin@xxxxxxxxxxxxxxx>
---
 drivers/usb/chipidea/ci.h       |   13 +++
 drivers/usb/chipidea/core.c     |    2 +
 drivers/usb/chipidea/debug.c    |  202 +--------------------------------------
 drivers/usb/chipidea/debug.h    |   20 ----
 drivers/usb/chipidea/udc.c      |   46 ++++-----
 drivers/usb/chipidea/udc.h      |    2 -
 include/trace/events/chipidea.h |  135 ++++++++++++++++++++++++++
 7 files changed, 169 insertions(+), 251 deletions(-)
 create mode 100644 include/trace/events/chipidea.h

diff --git a/drivers/usb/chipidea/ci.h b/drivers/usb/chipidea/ci.h
index e25d126..f67d101 100644
--- a/drivers/usb/chipidea/ci.h
+++ b/drivers/usb/chipidea/ci.h
@@ -23,6 +23,8 @@
  *****************************************************************************/
 #define CI13XXX_PAGE_SIZE  4096ul /* page size for TD's */
 #define ENDPT_MAX          32
+#define RX        0  /* similar to USB_DIR_OUT but can be used as an index */
+#define TX        1  /* similar to USB_DIR_IN  but can be used as an index */
 
 /******************************************************************************
  * STRUCTURES
@@ -59,6 +61,15 @@ struct ci13xxx_ep {
 	struct dma_pool				*td_pool;
 };
 
+/**
+ * ci_ep_addr: calculates endpoint address from direction & number
+ * @ep:  endpoint
+ */
+static inline u8 ci_ep_addr(struct ci13xxx_ep *ep)
+{
+	return ((ep->dir == TX) ? USB_ENDPOINT_DIR_MASK : 0) | ep->num;
+}
+
 enum ci_role {
 	CI_ROLE_HOST = 0,
 	CI_ROLE_GADGET,
@@ -313,4 +324,6 @@ int hw_port_test_set(struct ci13xxx *ci, u8 mode);
 
 u8 hw_port_test_get(struct ci13xxx *ci);
 
+#include <trace/events/chipidea.h>
+
 #endif	/* __DRIVERS_USB_CHIPIDEA_CI_H */
diff --git a/drivers/usb/chipidea/core.c b/drivers/usb/chipidea/core.c
index 77963b6..d0aa172 100644
--- a/drivers/usb/chipidea/core.c
+++ b/drivers/usb/chipidea/core.c
@@ -65,6 +65,8 @@
 #include <linux/usb/otg.h>
 #include <linux/usb/chipidea.h>
 
+#define CREATE_TRACE_POINTS
+
 #include "ci.h"
 #include "udc.h"
 #include "bits.h"
diff --git a/drivers/usb/chipidea/debug.c b/drivers/usb/chipidea/debug.c
index e6cc45e..9e9caa8 100644
--- a/drivers/usb/chipidea/debug.c
+++ b/drivers/usb/chipidea/debug.c
@@ -196,200 +196,6 @@ static ssize_t show_driver(struct device *dev, struct device_attribute *attr,
 }
 static DEVICE_ATTR(driver, S_IRUSR, show_driver, NULL);
 
-/* Maximum event message length */
-#define DBG_DATA_MSG   64UL
-
-/* Maximum event messages */
-#define DBG_DATA_MAX   128UL
-
-/* Event buffer descriptor */
-static struct {
-	char     (buf[DBG_DATA_MAX])[DBG_DATA_MSG];   /* buffer */
-	unsigned idx;   /* index */
-	unsigned tty;   /* print to console? */
-	rwlock_t lck;   /* lock */
-} dbg_data = {
-	.idx = 0,
-	.tty = 0,
-	.lck = __RW_LOCK_UNLOCKED(dbg_data.lck)
-};
-
-/**
- * dbg_dec: decrements debug event index
- * @idx: buffer index
- */
-static void dbg_dec(unsigned *idx)
-{
-	*idx = (*idx - 1) & (DBG_DATA_MAX-1);
-}
-
-/**
- * dbg_inc: increments debug event index
- * @idx: buffer index
- */
-static void dbg_inc(unsigned *idx)
-{
-	*idx = (*idx + 1) & (DBG_DATA_MAX-1);
-}
-
-/**
- * dbg_print:  prints the common part of the event
- * @addr:   endpoint address
- * @name:   event name
- * @status: status
- * @extra:  extra information
- */
-static void dbg_print(u8 addr, const char *name, int status, const char *extra)
-{
-	struct timeval tval;
-	unsigned int stamp;
-	unsigned long flags;
-
-	write_lock_irqsave(&dbg_data.lck, flags);
-
-	do_gettimeofday(&tval);
-	stamp = tval.tv_sec & 0xFFFF;	/* 2^32 = 4294967296. Limit to 4096s */
-	stamp = stamp * 1000000 + tval.tv_usec;
-
-	scnprintf(dbg_data.buf[dbg_data.idx], DBG_DATA_MSG,
-		  "%04X\t? %02X %-7.7s %4i ?\t%s\n",
-		  stamp, addr, name, status, extra);
-
-	dbg_inc(&dbg_data.idx);
-
-	write_unlock_irqrestore(&dbg_data.lck, flags);
-
-	if (dbg_data.tty != 0)
-		pr_notice("%04X\t? %02X %-7.7s %4i ?\t%s\n",
-			  stamp, addr, name, status, extra);
-}
-
-/**
- * dbg_done: prints a DONE event
- * @addr:   endpoint address
- * @td:     transfer descriptor
- * @status: status
- */
-void dbg_done(u8 addr, const u32 token, int status)
-{
-	char msg[DBG_DATA_MSG];
-
-	scnprintf(msg, sizeof(msg), "%d %02X",
-		  (int)(token & TD_TOTAL_BYTES) >> ffs_nr(TD_TOTAL_BYTES),
-		  (int)(token & TD_STATUS)      >> ffs_nr(TD_STATUS));
-	dbg_print(addr, "DONE", status, msg);
-}
-
-/**
- * dbg_event: prints a generic event
- * @addr:   endpoint address
- * @name:   event name
- * @status: status
- */
-void dbg_event(u8 addr, const char *name, int status)
-{
-	if (name != NULL)
-		dbg_print(addr, name, status, "");
-}
-
-/*
- * dbg_queue: prints a QUEUE event
- * @addr:   endpoint address
- * @req:    USB request
- * @status: status
- */
-void dbg_queue(u8 addr, const struct usb_request *req, int status)
-{
-	char msg[DBG_DATA_MSG];
-
-	if (req != NULL) {
-		scnprintf(msg, sizeof(msg),
-			  "%d %d", !req->no_interrupt, req->length);
-		dbg_print(addr, "QUEUE", status, msg);
-	}
-}
-
-/**
- * dbg_setup: prints a SETUP event
- * @addr: endpoint address
- * @req:  setup request
- */
-void dbg_setup(u8 addr, const struct usb_ctrlrequest *req)
-{
-	char msg[DBG_DATA_MSG];
-
-	if (req != NULL) {
-		scnprintf(msg, sizeof(msg),
-			  "%02X %02X %04X %04X %d", req->bRequestType,
-			  req->bRequest, le16_to_cpu(req->wValue),
-			  le16_to_cpu(req->wIndex), le16_to_cpu(req->wLength));
-		dbg_print(addr, "SETUP", 0, msg);
-	}
-}
-
-/**
- * show_events: displays the event buffer
- *
- * Check "device.h" for details
- */
-static ssize_t show_events(struct device *dev, struct device_attribute *attr,
-			   char *buf)
-{
-	unsigned long flags;
-	unsigned i, j, n = 0;
-
-	if (attr == NULL || buf == NULL) {
-		dev_err(dev->parent, "[%s] EINVAL\n", __func__);
-		return 0;
-	}
-
-	read_lock_irqsave(&dbg_data.lck, flags);
-
-	i = dbg_data.idx;
-	for (dbg_dec(&i); i != dbg_data.idx; dbg_dec(&i)) {
-		n += strlen(dbg_data.buf[i]);
-		if (n >= PAGE_SIZE) {
-			n -= strlen(dbg_data.buf[i]);
-			break;
-		}
-	}
-	for (j = 0, dbg_inc(&i); j < n; dbg_inc(&i))
-		j += scnprintf(buf + j, PAGE_SIZE - j,
-			       "%s", dbg_data.buf[i]);
-
-	read_unlock_irqrestore(&dbg_data.lck, flags);
-
-	return n;
-}
-
-/**
- * store_events: configure if events are going to be also printed to console
- *
- * Check "device.h" for details
- */
-static ssize_t store_events(struct device *dev, struct device_attribute *attr,
-			    const char *buf, size_t count)
-{
-	unsigned tty;
-
-	if (attr == NULL || buf == NULL) {
-		dev_err(dev, "[%s] EINVAL\n", __func__);
-		goto done;
-	}
-
-	if (sscanf(buf, "%u", &tty) != 1 || tty > 1) {
-		dev_err(dev, "<1|0>: enable|disable console log\n");
-		goto done;
-	}
-
-	dbg_data.tty = tty;
-	dev_info(dev, "tty = %u", dbg_data.tty);
-
- done:
-	return count;
-}
-static DEVICE_ATTR(events, S_IRUSR | S_IWUSR, show_events, store_events);
-
 /**
  * show_inters: interrupt status, enable status and historic
  *
@@ -730,12 +536,9 @@ int dbg_create_files(struct device *dev)
 	retval = device_create_file(dev, &dev_attr_driver);
 	if (retval)
 		goto rm_device;
-	retval = device_create_file(dev, &dev_attr_events);
-	if (retval)
-		goto rm_driver;
 	retval = device_create_file(dev, &dev_attr_inters);
 	if (retval)
-		goto rm_events;
+		goto rm_driver;
 	retval = device_create_file(dev, &dev_attr_port_test);
 	if (retval)
 		goto rm_inters;
@@ -758,8 +561,6 @@ int dbg_create_files(struct device *dev)
 	device_remove_file(dev, &dev_attr_port_test);
  rm_inters:
 	device_remove_file(dev, &dev_attr_inters);
- rm_events:
-	device_remove_file(dev, &dev_attr_events);
  rm_driver:
 	device_remove_file(dev, &dev_attr_driver);
  rm_device:
@@ -783,7 +584,6 @@ int dbg_remove_files(struct device *dev)
 	device_remove_file(dev, &dev_attr_qheads);
 	device_remove_file(dev, &dev_attr_port_test);
 	device_remove_file(dev, &dev_attr_inters);
-	device_remove_file(dev, &dev_attr_events);
 	device_remove_file(dev, &dev_attr_driver);
 	device_remove_file(dev, &dev_attr_device);
 	return 0;
diff --git a/drivers/usb/chipidea/debug.h b/drivers/usb/chipidea/debug.h
index 80d9686..3e9019f 100644
--- a/drivers/usb/chipidea/debug.h
+++ b/drivers/usb/chipidea/debug.h
@@ -15,10 +15,6 @@
 
 #ifdef CONFIG_USB_CHIPIDEA_DEBUG
 void dbg_interrupt(u32 intmask);
-void dbg_done(u8 addr, const u32 token, int status);
-void dbg_event(u8 addr, const char *name, int status);
-void dbg_queue(u8 addr, const struct usb_request *req, int status);
-void dbg_setup(u8 addr, const struct usb_ctrlrequest *req);
 int dbg_create_files(struct device *dev);
 int dbg_remove_files(struct device *dev);
 #else
@@ -26,22 +22,6 @@ static inline void dbg_interrupt(u32 intmask)
 {
 }
 
-static inline void dbg_done(u8 addr, const u32 token, int status)
-{
-}
-
-static inline void dbg_event(u8 addr, const char *name, int status)
-{
-}
-
-static inline void dbg_queue(u8 addr, const struct usb_request *req, int status)
-{
-}
-
-static inline void dbg_setup(u8 addr, const struct usb_ctrlrequest *req)
-{
-}
-
 static inline int dbg_create_files(struct device *dev)
 {
 	return 0;
diff --git a/drivers/usb/chipidea/udc.c b/drivers/usb/chipidea/udc.c
index 3dc5093..674f647 100644
--- a/drivers/usb/chipidea/udc.c
+++ b/drivers/usb/chipidea/udc.c
@@ -391,15 +391,6 @@ static void vbus_work(struct work_struct *work)
  * UTIL block
  *****************************************************************************/
 /**
- * _usb_addr: calculates endpoint address from direction & number
- * @ep:  endpoint
- */
-static inline u8 _usb_addr(struct ci13xxx_ep *ep)
-{
-	return ((ep->dir == TX) ? USB_ENDPOINT_DIR_MASK : 0) | ep->num;
-}
-
-/**
  * _hardware_queue: configures a request at hardware level
  * @gadget: gadget
  * @mEp:    endpoint
@@ -623,7 +614,7 @@ __acquires(ci->lock)
 {
 	int retval;
 
-	dbg_event(0xFF, "BUS RST", 0);
+	trace_ci_bus_reset(ci);
 
 	spin_unlock(&ci->lock);
 	retval = _gadget_stop_activity(&ci->gadget);
@@ -795,7 +786,7 @@ __acquires(mEp->lock)
 		if (retval < 0)
 			break;
 		list_del_init(&mReq->queue);
-		dbg_done(_usb_addr(mEp), mReq->ptr->token, retval);
+		trace_ci_ep_complete_req(mEp, mReq->ptr->token, retval);
 		if (mReq->req.complete != NULL) {
 			spin_unlock(mEp->lock);
 			if ((mEp->type == USB_ENDPOINT_XFER_CONTROL) &&
@@ -809,7 +800,7 @@ __acquires(mEp->lock)
 	if (retval == -EBUSY)
 		retval = 0;
 	if (retval < 0)
-		dbg_event(_usb_addr(mEp), "DONE", retval);
+		trace_ci_ep_complete_req(mEp, mReq->ptr->token, retval);
 
 	return retval;
 }
@@ -841,8 +832,7 @@ __acquires(ci->lock)
 				if (err > 0)   /* needs status phase */
 					err = isr_setup_status_phase(ci);
 				if (err < 0) {
-					dbg_event(_usb_addr(mEp),
-						  "ERROR", err);
+					trace_ci_ep_error(mEp, err);
 					spin_unlock(&ci->lock);
 					if (usb_ep_set_halt(&mEp->ep))
 						dev_err(ci->dev,
@@ -878,7 +868,7 @@ __acquires(ci->lock)
 
 		ci->ep0_dir = (type & USB_DIR_IN) ? TX : RX;
 
-		dbg_setup(_usb_addr(mEp), &req);
+		trace_ci_ep_setup(mEp, &req);
 
 		switch (req.bRequest) {
 		case USB_REQ_CLEAR_FEATURE:
@@ -991,7 +981,7 @@ delegate:
 		}
 
 		if (err < 0) {
-			dbg_event(_usb_addr(mEp), "ERROR", err);
+			trace_ci_ep_error(mEp, err);
 
 			spin_unlock(&ci->lock);
 			if (usb_ep_set_halt(&mEp->ep))
@@ -1034,7 +1024,7 @@ static int ep_enable(struct usb_ep *ep,
 
 	mEp->ep.maxpacket = usb_endpoint_maxp(desc);
 
-	dbg_event(_usb_addr(mEp), "ENABLE", 0);
+	trace_ci_ep_enable(mEp, 0);
 
 	mEp->qh.ptr->cap = 0;
 
@@ -1082,7 +1072,7 @@ static int ep_disable(struct usb_ep *ep)
 
 	direction = mEp->dir;
 	do {
-		dbg_event(_usb_addr(mEp), "DISABLE", 0);
+		trace_ci_ep_disable(mEp, 0);
 
 		retval |= _ep_nuke(mEp);
 		retval |= hw_ep_disable(mEp->ci, mEp->num, mEp->dir);
@@ -1123,7 +1113,7 @@ static struct usb_request *ep_alloc_request(struct usb_ep *ep, gfp_t gfp_flags)
 		}
 	}
 
-	dbg_event(_usb_addr(mEp), "ALLOC", mReq == NULL);
+	trace_ci_ep_alloc_req(mEp, mReq == NULL);
 
 	return (mReq == NULL) ? NULL : &mReq->req;
 }
@@ -1152,7 +1142,7 @@ static void ep_free_request(struct usb_ep *ep, struct usb_request *req)
 		dma_pool_free(mEp->td_pool, mReq->ptr, mReq->dma);
 	kfree(mReq);
 
-	dbg_event(_usb_addr(mEp), "FREE", 0);
+	trace_ci_ep_free_req(mEp, 0);
 
 	spin_unlock_irqrestore(mEp->lock, flags);
 }
@@ -1184,7 +1174,7 @@ static int ep_queue(struct usb_ep *ep, struct usb_request *req,
 			_ep_nuke(mEp);
 			retval = -EOVERFLOW;
 			dev_warn(mEp->ci->dev, "endpoint ctrl %X nuked\n",
-				 _usb_addr(mEp));
+				 ci_ep_addr(mEp));
 		}
 	}
 
@@ -1201,7 +1191,7 @@ static int ep_queue(struct usb_ep *ep, struct usb_request *req,
 		dev_warn(mEp->ci->dev, "request length truncated\n");
 	}
 
-	dbg_queue(_usb_addr(mEp), req, retval);
+	trace_ci_ep_queue_req(mEp, retval);
 
 	/* push request */
 	mReq->req.status = -EINPROGRESS;
@@ -1210,7 +1200,7 @@ static int ep_queue(struct usb_ep *ep, struct usb_request *req,
 	retval = _hardware_enqueue(mEp, mReq);
 
 	if (retval == -EALREADY) {
-		dbg_event(_usb_addr(mEp), "QUEUE", retval);
+		trace_ci_ep_queue_req(mEp, retval);
 		retval = 0;
 	}
 	if (!retval)
@@ -1239,7 +1229,7 @@ static int ep_dequeue(struct usb_ep *ep, struct usb_request *req)
 
 	spin_lock_irqsave(mEp->lock, flags);
 
-	dbg_event(_usb_addr(mEp), "DEQUEUE", 0);
+	trace_ci_ep_dequeue_req(mEp, 0);
 
 	hw_ep_flush(mEp->ci, mEp->num, mEp->dir);
 
@@ -1287,7 +1277,7 @@ static int ep_set_halt(struct usb_ep *ep, int value)
 
 	direction = mEp->dir;
 	do {
-		dbg_event(_usb_addr(mEp), "HALT", value);
+		trace_ci_ep_halt(mEp, value);
 		retval |= hw_ep_set_halt(mEp->ci, mEp->num, mEp->dir, value);
 
 		if (!value)
@@ -1317,7 +1307,7 @@ static int ep_set_wedge(struct usb_ep *ep)
 
 	spin_lock_irqsave(mEp->lock, flags);
 
-	dbg_event(_usb_addr(mEp), "WEDGE", 0);
+	trace_ci_ep_wedge(mEp, 0);
 	mEp->wedge = 1;
 
 	spin_unlock_irqrestore(mEp->lock, flags);
@@ -1336,13 +1326,13 @@ static void ep_fifo_flush(struct usb_ep *ep)
 	unsigned long flags;
 
 	if (ep == NULL) {
-		dev_err(mEp->ci->dev, "%02X: -EINVAL\n", _usb_addr(mEp));
+		dev_err(mEp->ci->dev, "%02X: -EINVAL\n", ci_ep_addr(mEp));
 		return;
 	}
 
 	spin_lock_irqsave(mEp->lock, flags);
 
-	dbg_event(_usb_addr(mEp), "FFLUSH", 0);
+	trace_ci_ep_flush(mEp, 0);
 	hw_ep_flush(mEp->ci, mEp->num, mEp->dir);
 
 	spin_unlock_irqrestore(mEp->lock, flags);
diff --git a/drivers/usb/chipidea/udc.h b/drivers/usb/chipidea/udc.h
index 4ff2384d..d644574 100644
--- a/drivers/usb/chipidea/udc.h
+++ b/drivers/usb/chipidea/udc.h
@@ -16,8 +16,6 @@
 #include <linux/list.h>
 
 #define CTRL_PAYLOAD_MAX   64
-#define RX        0  /* similar to USB_DIR_OUT but can be used as an index */
-#define TX        1  /* similar to USB_DIR_IN  but can be used as an index */
 
 /* DMA layout of transfer descriptors */
 struct ci13xxx_td {
diff --git a/include/trace/events/chipidea.h b/include/trace/events/chipidea.h
new file mode 100644
index 0000000..5e5c2ed
--- /dev/null
+++ b/include/trace/events/chipidea.h
@@ -0,0 +1,135 @@
+#undef TRACE_SYSTEM
+#define TRACE_SYSTEM chipidea
+
+#if !defined(_TRACE_CHIPIDEA_H) || defined(TRACE_HEADER_MULTI_READ)
+#define _TRACE_CHIPIDEA_H
+
+#include <linux/tracepoint.h>
+#include <linux/usb/gadget.h>
+#include <linux/usb/ch9.h>
+
+TRACE_EVENT(ci_bus_reset,
+	TP_PROTO(struct ci13xxx *ci),
+
+	TP_ARGS(ci),
+
+	TP_STRUCT__entry(
+		__field(	int,		id	)
+	),
+
+	TP_fast_assign(
+		__entry->id = to_platform_device(ci->dev)->id;
+	),
+
+	TP_printk("ci_hdrc.%d", __entry->id)
+);
+
+TRACE_EVENT(ci_ep_setup,
+	TP_PROTO(struct ci13xxx_ep *cep, struct usb_ctrlrequest *creq),
+
+	TP_ARGS(cep, creq),
+
+	TP_STRUCT__entry(
+		__field(	int,				id	)
+		__field(	u8,				addr	)
+		__field(	u8,				type	)
+		__field(	u8,				req	)
+		__field(	u16,				value	)
+		__field(	u16,				index	)
+		__field(	u16,				length	)
+	),
+
+	TP_fast_assign(
+		__entry->id = to_platform_device(cep->ci->dev)->id;
+		__entry->addr = ci_ep_addr(cep);
+		__entry->type = creq->bRequestType;
+		__entry->req = creq->bRequest;
+		__entry->value = le16_to_cpu(creq->wValue);
+		__entry->index = le16_to_cpu(creq->wIndex);
+		__entry->length = le16_to_cpu(creq->wLength);
+	),
+
+	TP_printk("ci_hdrc.%d: [%02x] %02x %02x %04x %04x %d",
+		  __entry->id, __entry->addr, __entry->type, __entry->req,
+		  __entry->value, __entry->index, __entry->length)
+);
+
+TRACE_EVENT(ci_ep_complete_req,
+	TP_PROTO(struct ci13xxx_ep *cep, u32 token, int status),
+
+	TP_ARGS(cep, token, status),
+
+	TP_STRUCT__entry(
+		__field(	int,				id	)
+		__field(	u8,				addr	)
+		__field(	u32,				token	)
+		__field(	int,				status	)
+	),
+
+	TP_fast_assign(
+		__entry->id = to_platform_device(cep->ci->dev)->id;
+		__entry->addr = ci_ep_addr(cep);
+		__entry->token = token;
+		__entry->status = status;
+	),
+
+	TP_printk("ci_hdrc.%d: [%02x] %08x status=%d",
+		  __entry->id, __entry->addr, __entry->token, __entry->status)
+);
+
+DECLARE_EVENT_CLASS(ci_ep_event,
+	TP_PROTO(struct ci13xxx_ep *cep, int status),
+
+	TP_ARGS(cep, status),
+
+	TP_STRUCT__entry(
+		__field(	int,		id	)
+		__field(	u8,		addr	)
+		__field(	int,		status	)
+	),
+
+	TP_fast_assign(
+		__entry->id = to_platform_device(cep->ci->dev)->id;
+		__entry->addr = ci_ep_addr(cep);
+		__entry->status = status;
+	),
+
+	TP_printk("ci_hdrc.%d: [%02x] status=%d", __entry->id,
+		  __entry->addr, __entry->status)
+);
+
+DEFINE_EVENT(ci_ep_event, ci_ep_error,
+	TP_PROTO(struct ci13xxx_ep *cep, int status),
+	TP_ARGS(cep, status));
+DEFINE_EVENT(ci_ep_event, ci_ep_queue_req,
+	TP_PROTO(struct ci13xxx_ep *cep, int status),
+	TP_ARGS(cep, status));
+DEFINE_EVENT(ci_ep_event, ci_ep_dequeue_req,
+	TP_PROTO(struct ci13xxx_ep *cep, int status),
+	TP_ARGS(cep, status));
+DEFINE_EVENT(ci_ep_event, ci_ep_enable,
+	TP_PROTO(struct ci13xxx_ep *cep, int status),
+	TP_ARGS(cep, status));
+DEFINE_EVENT(ci_ep_event, ci_ep_disable,
+	TP_PROTO(struct ci13xxx_ep *cep, int status),
+	TP_ARGS(cep, status));
+DEFINE_EVENT(ci_ep_event, ci_ep_alloc_req,
+	TP_PROTO(struct ci13xxx_ep *cep, int status),
+	TP_ARGS(cep, status));
+DEFINE_EVENT(ci_ep_event, ci_ep_free_req,
+	TP_PROTO(struct ci13xxx_ep *cep, int status),
+	TP_ARGS(cep, status));
+DEFINE_EVENT(ci_ep_event, ci_ep_halt,
+	TP_PROTO(struct ci13xxx_ep *cep, int status),
+	TP_ARGS(cep, status));
+DEFINE_EVENT(ci_ep_event, ci_ep_wedge,
+	TP_PROTO(struct ci13xxx_ep *cep, int status),
+	TP_ARGS(cep, status));
+DEFINE_EVENT(ci_ep_event, ci_ep_flush,
+	TP_PROTO(struct ci13xxx_ep *cep, int status),
+	TP_ARGS(cep, status));
+
+#endif /* _TRACE_CHIPIDEA_H */
+
+/* This part must be outside protection */
+#include <trace/define_trace.h>
-- 
1.7.10.4

--
To unsubscribe from this list: send the line "unsubscribe linux-usb" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html




[Index of Archives]     [Linux Media]     [Linux Input]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]     [Old Linux USB Devel Archive]

  Powered by Linux