Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 157bd4c0 authored by Linux Build Service Account's avatar Linux Build Service Account Committed by Gerrit - the friendly Code Review server
Browse files

Merge "USB: dwc3: debugfs: Enable logging of control endpoint events by default"

parents 3a7f80c9 995a86a6
Loading
Loading
Loading
Loading
+2 −2
Original line number Diff line number Diff line
@@ -781,9 +781,9 @@ const struct file_operations dwc3_ep_trb_list_fops = {
	.release		= single_release,
};

static unsigned int ep_addr_rxdbg_mask;
static unsigned int ep_addr_rxdbg_mask = 1;
module_param(ep_addr_rxdbg_mask, uint, S_IRUGO | S_IWUSR);
static unsigned int ep_addr_txdbg_mask;
static unsigned int ep_addr_txdbg_mask = 1;
module_param(ep_addr_txdbg_mask, uint, S_IRUGO | S_IWUSR);

/* Maximum debug message length */
+7 −2
Original line number Diff line number Diff line
@@ -291,6 +291,7 @@ int dwc3_gadget_ep0_set_halt(struct usb_ep *ep, int value)
	struct dwc3_ep			*dep = to_dwc3_ep(ep);
	struct dwc3			*dwc = dep->dwc;

	dbg_event(dep->number, "EP0STAL", value);
	dwc3_ep0_stall_and_restart(dwc);

	return 0;
@@ -761,9 +762,11 @@ static void dwc3_ep0_inspect_setup(struct dwc3 *dwc,
		dwc->delayed_status = true;

out:
	if (ret < 0)
	if (ret < 0) {
		dbg_event(0x0, "ERRSTAL", ret);
		dwc3_ep0_stall_and_restart(dwc);
	}
}

bool zlp_required;
static void dwc3_ep0_complete_data(struct dwc3 *dwc,
@@ -828,7 +831,7 @@ static void dwc3_ep0_complete_data(struct dwc3 *dwc,

	if ((epnum & 1) && ur->actual < ur->length) {
		/* for some reason we did not get everything out */

		dbg_event(epnum, "INDATSTAL", 0);
		dwc3_ep0_stall_and_restart(dwc);
	} else {
		/*
@@ -864,6 +867,7 @@ static void dwc3_ep0_complete_status(struct dwc3 *dwc,
		if (ret < 0) {
			dev_dbg(dwc->dev, "Invalid Test #%d\n",
					dwc->test_mode_nr);
			dbg_event(0x00, "INVALTEST", ret);
			dwc3_ep0_stall_and_restart(dwc);
			return;
		}
@@ -1044,6 +1048,7 @@ static void dwc3_ep0_xfernotready(struct dwc3 *dwc,

			dev_vdbg(dwc->dev, "Wrong direction for Data phase\n");
			dwc3_ep0_end_control_data(dwc, dep);
			dbg_event(epnum, "WRONGDR", 0);
			dwc3_ep0_stall_and_restart(dwc);
			return;
		}
+3 −0
Original line number Diff line number Diff line
@@ -2281,6 +2281,7 @@ static void dwc3_endpoint_interrupt(struct dwc3 *dwc,
			return;
		}

		dbg_event(dep->number, "XFRCOMP", 0);
		dwc3_endpoint_transfer_complete(dwc, dep, event, 1);
		break;
	case DWC3_DEPEVT_XFERINPROGRESS:
@@ -2290,9 +2291,11 @@ static void dwc3_endpoint_interrupt(struct dwc3 *dwc,
			return;
		}

		dbg_event(dep->number, "XFRPROG", 0);
		dwc3_endpoint_transfer_complete(dwc, dep, event, 0);
		break;
	case DWC3_DEPEVT_XFERNOTREADY:
		dbg_event(dep->number, "XFRNRDY", 0);
		if (usb_endpoint_xfer_isoc(dep->endpoint.desc)) {
			dwc3_gadget_start_isoc(dwc, dep, event);
		} else {