From a45c68396ba6a7ac327317aad537bbfb4410cb78 Mon Sep 17 00:00:00 2001 From: lyz Date: Thu, 7 Aug 2014 16:18:00 +0800 Subject: [PATCH] Revert "usb: fix RK3036 bvalid irq Num" This reverts commit 5c81c74ca685ed7ef3c85247232a87bf1b16b57f. --- drivers/usb/dwc_otg_310/usbdev_rk3036.c | 30 ++++--------------------- 1 file changed, 4 insertions(+), 26 deletions(-) diff --git a/drivers/usb/dwc_otg_310/usbdev_rk3036.c b/drivers/usb/dwc_otg_310/usbdev_rk3036.c index c7911c3fd720..b8fe46c40ce6 100755 --- a/drivers/usb/dwc_otg_310/usbdev_rk3036.c +++ b/drivers/usb/dwc_otg_310/usbdev_rk3036.c @@ -141,28 +141,10 @@ static int usb20otg_get_status(int id) return ret; } -#ifdef CONFIG_RK_USB_UART -/** - * dwc_otg_uart_enabled - check if a usb-uart debugger is enabled in DT - * - * Returns true if the status property of node "usb_uart" is set to "okay" - * or "ok", if this property is absent it will use the default status "ok" - * 0 otherwise - */ -static bool dwc_otg_uart_enabled(void) -{ - struct device_node *np; - - np = of_find_node_by_name(NULL, "usb_uart"); - if(np && of_device_is_available(np)) - return true; - - return false; -} - static void dwc_otg_uart_mode(void *pdata, int enter_usb_uart_mode) { - if ((1 == enter_usb_uart_mode) && dwc_otg_uart_enabled()) { +#ifdef CONFIG_RK_USB_UART + if (1 == enter_usb_uart_mode) { /* bypass dm, enter uart mode */ writel(UOC_HIWORD_UPDATE(0x3, 0x3, 12), RK_GRF_VIRT + RK3036_GRF_UOC1_CON4); @@ -171,13 +153,9 @@ static void dwc_otg_uart_mode(void *pdata, int enter_usb_uart_mode) writel(UOC_HIWORD_UPDATE(0x0, 0x3, 12), RK_GRF_VIRT + RK3036_GRF_UOC1_CON4); } -} -#else -static void dwc_otg_uart_mode(void *pdata, int enter_usb_uart_mode) -{ - ; -} #endif +} + static void usb20otg_power_enable(int enable) { if (0 == enable) { -- 2.34.1