From 168de6b1d959bb27f7aea6a0041f848a2391b1e5 Mon Sep 17 00:00:00 2001 From: Wesley Cheng Date: Mon, 18 Oct 2021 12:26:47 -0700 Subject: [PATCH] FROMGIT: usb: dwc3: gadget: Change to dev_dbg() when queuing to inactive gadget/ep Since function drivers will still be active until dwc3_disconnect_gadget() is called, some applications will continue to queue packets to DWC3 gadget. This can lead to a flood of messages regarding failed ep queue, as the endpoint is in the process of being disabled. Change the log level to debug, so that it can be enabled when debugging issues. Signed-off-by: Wesley Cheng Link: https://lore.kernel.org/r/20211018192647.32121-1-wcheng@codeaurora.org Signed-off-by: Greg Kroah-Hartman (cherry picked from commit b851f7c7b8fd5365e447bb60e1e18eb6de628507 https://git.kernel.org/pub/scm/linux/kernel/git/gregkh/usb.git usb-next) Bug: 203763122 Change-Id: I5120890fa12f707ae54da551db9aab02dded0063 Signed-off-by: Wesley Cheng --- drivers/usb/dwc3/gadget.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/usb/dwc3/gadget.c b/drivers/usb/dwc3/gadget.c index 0c38791da695..b863f03af705 100644 --- a/drivers/usb/dwc3/gadget.c +++ b/drivers/usb/dwc3/gadget.c @@ -1811,7 +1811,7 @@ static int __dwc3_gadget_ep_queue(struct dwc3_ep *dep, struct dwc3_request *req) struct dwc3 *dwc = dep->dwc; if (!dep->endpoint.desc || !dwc->pullups_connected || !dwc->connected) { - dev_err(dwc->dev, "%s: can't queue to disabled endpoint\n", + dev_dbg(dwc->dev, "%s: can't queue to disabled endpoint\n", dep->name); return -ESHUTDOWN; }