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

Commit 13a10de5 authored by qctecmdr's avatar qctecmdr Committed by Gerrit - the friendly Code Review server
Browse files

Merge "coresight: byte-cnter: Add ETR status check in bypass notifier"

parents d38ae1ea 922ca3d4
Loading
Loading
Loading
Loading
+7 −3
Original line number Diff line number Diff line
@@ -546,10 +546,9 @@ void usb_bypass_notifier(void *priv, unsigned int event,
	if (!drvdata)
		return;

	if (tmcdrvdata->out_mode != TMC_ETR_OUT_MODE_USB
				|| tmcdrvdata->mode == CS_MODE_DISABLED) {
	if (tmcdrvdata->out_mode != TMC_ETR_OUT_MODE_USB) {
		dev_err(&tmcdrvdata->csdev->dev,
		"%s: ETR is not USB mode, or ETR is disabled.\n", __func__);
		"%s: ETR is not USB mode\n", __func__);
		return;
	}

@@ -569,6 +568,11 @@ void usb_bypass_notifier(void *priv, unsigned int event,
		break;

	case USB_QDSS_DISCONNECT:
		if (tmcdrvdata->mode == CS_MODE_DISABLED) {
			dev_err(&tmcdrvdata->csdev->dev,
			 "%s: ETR is disabled.\n", __func__);
			return;
		}
		usb_bypass_stop(drvdata);
		break;