enable xhci & UVC trace

cat enable_usb_mini_log.patch
diff --git a/drivers/usb/core/hub.c b/drivers/usb/core/hub.c
index 4ebc1a8ac605..42718e3a1f6e 100644
--- a/drivers/usb/core/hub.c
+++ b/drivers/usb/core/hub.c
@@ -33,6 +33,11 @@
 #include "hub.h"
 #include "otg_whitelist.h"

+#undef dev_dbg
+#define dev_dbg dev_err
+#undef pr_debug
+#define pr_debug pr_err
+
 #define USB_VENDOR_GENESYS_LOGIC               0x05e3
 #define HUB_QUIRK_CHECK_PORT_AUTOSUSPEND       0x01

diff --git a/drivers/usb/dwc3/dwc3-msm.c b/drivers/usb/dwc3/dwc3-msm.c
index 499ed0a9c0ad..dc1a617e7fa9 100644
--- a/drivers/usb/dwc3/dwc3-msm.c
+++ b/drivers/usb/dwc3/dwc3-msm.c
@@ -55,6 +55,12 @@
 #include "debug.h"
 #include "xhci.h"

+#undef dev_dbg
+#define dev_dbg dev_err
+#undef pr_debug
+#define pr_debug pr_err
+
+
 #define SDP_CONNETION_CHECK_TIME 10000 /* in ms */

 /* time out to wait for USB cable status notification (in ms)*/
@@ -4177,8 +4183,8 @@ static void msm_dwc3_perf_vote_work(struct work_struct *w)
        if (dwc->irq_cnt - last_irq_cnt >= PM_QOS_THRESHOLD)
                in_perf_mode = true;

-       pr_debug("%s: in_perf_mode:%u, interrupts in last sample:%lu\n",
-                __func__, in_perf_mode, (dwc->irq_cnt - last_irq_cnt));
+//     pr_debug("%s: in_perf_mode:%u, interrupts in last sample:%lu\n",
+//              __func__, in_perf_mode, (dwc->irq_cnt - last_irq_cnt));

        last_irq_cnt = dwc->irq_cnt;
        msm_dwc3_perf_vote_update(mdwc, in_perf_mode);
diff --git a/drivers/usb/host/xhci-ring.c b/drivers/usb/host/xhci-ring.c
index a142339d9028..bde9a25d9945 100644
--- a/drivers/usb/host/xhci-ring.c
+++ b/drivers/usb/host/xhci-ring.c
@@ -71,6 +71,11 @@
 #include "xhci-trace.h"
 #include "xhci-mtk.h"

+#undef dev_dbg
+#define dev_dbg dev_err
+#undef pr_debug
+#define pr_debug pr_err
+
 /*
  * Returns zero if the TRB isn't in this segment, otherwise it returns the DMA
  * address of the TRB.
@@ -2223,13 +2228,15 @@ static int process_bulk_intr_td(struct xhci_hcd *xhci, struct xhci_td *td,
                /* Others already handled above */
                break;
        }
-       if (trb_comp_code == COMP_SHORT_TX)
+#if 0
+    if (trb_comp_code == COMP_SHORT_TX)
                xhci_dbg(xhci, "ep %#x - asked for %d bytes, "
                                "%d bytes untransferred\n",
                                td->urb->ep->desc.bEndpointAddress,
                                td->urb->transfer_buffer_length,
                                EVENT_TRB_LEN(le32_to_cpu(event->transfer_len)));
-       /* Stopped - short packet completion */
+#endif
+    /* Stopped - short packet completion */
        if (trb_comp_code == COMP_STOP_SHORT) {
                td->urb->actual_length =
                        EVENT_TRB_LEN(le32_to_cpu(event->transfer_len));
diff --git a/drivers/usb/host/xhci.c b/drivers/usb/host/xhci.c
index 52495fced86d..2e2d868752f8 100644
--- a/drivers/usb/host/xhci.c
+++ b/drivers/usb/host/xhci.c
@@ -34,6 +34,11 @@
 #include "xhci-trace.h"
 #include "xhci-mtk.h"

+#undef dev_dbg
+#define dev_dbg dev_err
+#undef pr_debug
+#define pr_debug pr_err
+
 #define DRIVER_AUTHOR "Sarah Sharp"
 #define DRIVER_DESC "'eXtensible' Host Controller (xHC) Driver"



diff --git a/drivers/media/usb/uvc/uvc_driver.c b/drivers/media/usb/uvc/uvc_driver.c
index 18a20b6402c6..8c2155b6de7b 100644
--- a/drivers/media/usb/uvc/uvc_driver.c
+++ b/drivers/media/usb/uvc/uvc_driver.c
@@ -35,7 +35,7 @@ unsigned int uvc_clock_param = CLOCK_MONOTONIC;
 unsigned int uvc_hw_timestamps_param;
 unsigned int uvc_no_drop_param;
 static unsigned int uvc_quirks_param = -1;
-unsigned int uvc_trace_param;
+unsigned int uvc_trace_param = 0x97;
 unsigned int uvc_timeout_param = UVC_CTRL_STREAMING_TIMEOUT;
  • 0
    点赞
  • 1
    收藏
    觉得还不错? 一键收藏
  • 1
    评论
评论 1
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值