Namely, print endpoint names instead of addresses. This way, it should be readable by humans even without a hw debugger/kgdb. Signed-off-by: Alexander Shishkin <alexander.shishkin@xxxxxxxxxxxxxxx> --- drivers/usb/gadget/ci13xxx_udc.c | 35 +++++++++++++++++++---------------- 1 file changed, 19 insertions(+), 16 deletions(-) diff --git a/drivers/usb/gadget/ci13xxx_udc.c b/drivers/usb/gadget/ci13xxx_udc.c index 05fdd3c..f1b516a 100644 --- a/drivers/usb/gadget/ci13xxx_udc.c +++ b/drivers/usb/gadget/ci13xxx_udc.c @@ -1468,7 +1468,7 @@ static int _hardware_enqueue(struct ci13xxx_ep *mEp, struct ci13xxx_req *mReq) int ret = 0; unsigned length = mReq->req.length; - dev_dbg(udc->dev, "%p, %p", mEp, mReq); + dev_dbg(udc->dev, "%s, %p", mEp->name, mReq); /* don't queue twice */ if (mReq->req.status == -EALREADY) @@ -1570,7 +1570,7 @@ done: */ static int _hardware_dequeue(struct ci13xxx_ep *mEp, struct ci13xxx_req *mReq) { - dev_dbg(mEp->udc->dev, "%p, %p", mEp, mReq); + dev_dbg(mEp->udc->dev, "%s, %p", mEp->name, mReq); if (mReq->req.status != -EALREADY) return -EINVAL; @@ -1621,7 +1621,7 @@ static int _ep_nuke(struct ci13xxx_ep *mEp) __releases(mEp->lock) __acquires(mEp->lock) { - dev_dbg(mEp->udc->dev, "%p", mEp); + dev_dbg(mEp->udc->dev, "%s", mEp->name); if (mEp == NULL) return -EINVAL; @@ -1740,11 +1740,14 @@ __acquires(udc->lock) */ static void isr_get_status_complete(struct usb_ep *ep, struct usb_request *req) { - dev_dbg(NULL, "%p, %p", ep, req); + struct ci13xxx *udc; if (ep == NULL || req == NULL) return; + udc = req->context; + dev_dbg(udc->dev, "%s, %p", ep->name, req); + kfree(req->buf); usb_ep_free_request(ep, req); } @@ -1766,7 +1769,7 @@ __acquires(mEp->lock) gfp_t gfp_flags = GFP_ATOMIC; int dir, num, retval; - dev_dbg(udc->dev, "%p, %p", mEp, setup); + dev_dbg(udc->dev, "%s, %p", mEp->name, setup); if (mEp == NULL || setup == NULL) return -EINVAL; @@ -1829,7 +1832,7 @@ isr_setup_status_complete(struct usb_ep *ep, struct usb_request *req) struct ci13xxx *udc = req->context; unsigned long flags; - dev_dbg(udc->dev, "%p, %p", ep, req); + dev_dbg(udc->dev, "%s, %p", ep->name, req); spin_lock_irqsave(&udc->lock, flags); if (udc->test_mode) @@ -1878,7 +1881,7 @@ __acquires(mEp->lock) struct ci13xxx_ep *mEpTemp = mEp; int uninitialized_var(retval); - dev_dbg(mEp->udc->dev, "%p", mEp); + dev_dbg(mEp->udc->dev, "%s", mEp->name); if (list_empty(&mEp->qh.queue)) return -EINVAL; @@ -2114,7 +2117,7 @@ static int ep_enable(struct usb_ep *ep, int retval = 0; unsigned long flags; - dev_dbg(mEp->udc->dev, "%p, %p", ep, desc); + dev_dbg(mEp->udc->dev, "%s, %p", mEp->name, desc); if (ep == NULL || desc == NULL) return -EINVAL; @@ -2171,7 +2174,7 @@ static int ep_disable(struct usb_ep *ep) int direction, retval = 0; unsigned long flags; - dev_dbg(mEp->udc->dev, "%p", ep); + dev_dbg(mEp->udc->dev, "%s", mEp->name); if (ep == NULL) return -EINVAL; @@ -2210,7 +2213,7 @@ static struct usb_request *ep_alloc_request(struct usb_ep *ep, gfp_t gfp_flags) struct ci13xxx_ep *mEp = container_of(ep, struct ci13xxx_ep, ep); struct ci13xxx_req *mReq = NULL; - dev_dbg(mEp->udc->dev, "%p, %i", ep, gfp_flags); + dev_dbg(mEp->udc->dev, "%s, %i", mEp->name, gfp_flags); if (ep == NULL) return NULL; @@ -2244,7 +2247,7 @@ static void ep_free_request(struct usb_ep *ep, struct usb_request *req) struct ci13xxx_req *mReq = container_of(req, struct ci13xxx_req, req); unsigned long flags; - dev_dbg(mEp->udc->dev, "%p, %p", ep, req); + dev_dbg(mEp->udc->dev, "%s, %p", mEp->name, req); if (ep == NULL || req == NULL) { return; @@ -2278,7 +2281,7 @@ static int ep_queue(struct usb_ep *ep, struct usb_request *req, int retval = 0; unsigned long flags; - dev_dbg(mEp->udc->dev, "%p, %p, %X", ep, req, gfp_flags); + dev_dbg(mEp->udc->dev, "%s, %p, %X", mEp->name, req, gfp_flags); if (ep == NULL || req == NULL || mEp->ep.desc == NULL) return -EINVAL; @@ -2341,7 +2344,7 @@ static int ep_dequeue(struct usb_ep *ep, struct usb_request *req) struct ci13xxx_req *mReq = container_of(req, struct ci13xxx_req, req); unsigned long flags; - dev_dbg(mEp->udc->dev, "%p, %p", ep, req); + dev_dbg(mEp->udc->dev, "%s, %p", mEp->name, req); if (ep == NULL || req == NULL || mReq->req.status != -EALREADY || mEp->ep.desc == NULL || list_empty(&mReq->queue) || @@ -2385,7 +2388,7 @@ static int ep_set_halt(struct usb_ep *ep, int value) int direction, retval = 0; unsigned long flags; - dev_dbg(mEp->udc->dev, "%p, %i", ep, value); + dev_dbg(mEp->udc->dev, "%s, %i", mEp->name, value); if (ep == NULL || mEp->ep.desc == NULL) return -EINVAL; @@ -2428,7 +2431,7 @@ static int ep_set_wedge(struct usb_ep *ep) struct ci13xxx_ep *mEp = container_of(ep, struct ci13xxx_ep, ep); unsigned long flags; - dev_dbg(mEp->udc->dev, "%p", ep); + dev_dbg(mEp->udc->dev, "%s", mEp->name); if (ep == NULL || mEp->ep.desc == NULL) return -EINVAL; @@ -2453,7 +2456,7 @@ static void ep_fifo_flush(struct usb_ep *ep) struct ci13xxx_ep *mEp = container_of(ep, struct ci13xxx_ep, ep); unsigned long flags; - dev_dbg(mEp->udc->dev, "%p", ep); + dev_dbg(mEp->udc->dev, "%s", mEp->name); if (ep == NULL) { dev_err(mEp->udc->dev, "%02X: -EINVAL\n", _usb_addr(mEp)); -- 1.7.10 -- 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