From patchwork Mon Jul 8 20:59:35 2013 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Dan Murphy X-Patchwork-Id: 257604 X-Patchwork-Delegate: trini@ti.com Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from theia.denx.de (theia.denx.de [85.214.87.163]) by ozlabs.org (Postfix) with ESMTP id E23422C009D for ; Tue, 9 Jul 2013 07:00:09 +1000 (EST) Received: from localhost (localhost [127.0.0.1]) by theia.denx.de (Postfix) with ESMTP id 8BB474A79B; Mon, 8 Jul 2013 23:00:08 +0200 (CEST) X-Virus-Scanned: Debian amavisd-new at theia.denx.de Received: from theia.denx.de ([127.0.0.1]) by localhost (theia.denx.de [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id SF4o6UAEkAdK; Mon, 8 Jul 2013 23:00:08 +0200 (CEST) Received: from theia.denx.de (localhost [127.0.0.1]) by theia.denx.de (Postfix) with ESMTP id AEB2B4A7D3; Mon, 8 Jul 2013 23:00:05 +0200 (CEST) Received: from localhost (localhost [127.0.0.1]) by theia.denx.de (Postfix) with ESMTP id F139D4A79B for ; Mon, 8 Jul 2013 22:59:58 +0200 (CEST) X-Virus-Scanned: Debian amavisd-new at theia.denx.de Received: from theia.denx.de ([127.0.0.1]) by localhost (theia.denx.de [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id gATlXydgvw4z for ; Mon, 8 Jul 2013 22:59:51 +0200 (CEST) X-policyd-weight: NOT_IN_SBL_XBL_SPAMHAUS=-1.5 NOT_IN_SPAMCOP=-1.5 NOT_IN_BL_NJABL=-1.5 (only DNSBL check requested) Received: from devils.ext.ti.com (devils.ext.ti.com [198.47.26.153]) by theia.denx.de (Postfix) with ESMTPS id 123A74A7D3 for ; Mon, 8 Jul 2013 22:59:44 +0200 (CEST) Received: from dlelxv90.itg.ti.com ([172.17.2.17]) by devils.ext.ti.com (8.13.7/8.13.7) with ESMTP id r68Kxdhi020934; Mon, 8 Jul 2013 15:59:39 -0500 Received: from DLEE70.ent.ti.com (dlee70.ent.ti.com [157.170.170.113]) by dlelxv90.itg.ti.com (8.14.3/8.13.8) with ESMTP id r68KxdYS001573; Mon, 8 Jul 2013 15:59:39 -0500 Received: from dlelxv23.itg.ti.com (172.17.1.198) by DLEE70.ent.ti.com (157.170.170.113) with Microsoft SMTP Server id 14.2.342.3; Mon, 8 Jul 2013 15:59:39 -0500 Received: from legion.dal.design.ti.com (legion.dal.design.ti.com [128.247.22.53]) by dlelxv23.itg.ti.com (8.13.8/8.13.8) with ESMTP id r68KxdmF001071; Mon, 8 Jul 2013 15:59:39 -0500 Received: from localhost (h112-247.vpn.ti.com [172.24.112.247]) by legion.dal.design.ti.com (8.11.7p1+Sun/8.11.7) with ESMTP id r68Kxct22519; Mon, 8 Jul 2013 15:59:38 -0500 (CDT) From: Dan Murphy To: , , Date: Mon, 8 Jul 2013 15:59:35 -0500 Message-ID: <1373317175-28926-4-git-send-email-dmurphy@ti.com> X-Mailer: git-send-email 1.7.9.5 In-Reply-To: <1373317175-28926-1-git-send-email-dmurphy@ti.com> References: <1373317175-28926-1-git-send-email-dmurphy@ti.com> MIME-Version: 1.0 Cc: ruchika@ti.com, rogerq@ti.com Subject: [U-Boot] [PATCH 3/3] HACK: ehci-omap: do gpio toggle after port power is set X-BeenThere: u-boot@lists.denx.de X-Mailman-Version: 2.1.11 Precedence: list List-Id: U-Boot discussion List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: u-boot-bounces@lists.denx.de Errors-To: u-boot-bounces@lists.denx.de Need to check why gpio toggling in ehci-omap is not working and works only from ehci-hcd. Signed-off-by: Dan Murphy --- drivers/usb/host/ehci-hcd.c | 7 ++++++- drivers/usb/host/ehci-omap.c | 2 +- 2 files changed, 7 insertions(+), 2 deletions(-) diff --git a/drivers/usb/host/ehci-hcd.c b/drivers/usb/host/ehci-hcd.c index 706cf0c..17d0c9c 100644 --- a/drivers/usb/host/ehci-hcd.c +++ b/drivers/usb/host/ehci-hcd.c @@ -29,7 +29,7 @@ #include #include #include - +#include #include "ehci.h" #ifndef CONFIG_USB_MAX_CONTROLLER_COUNT @@ -776,6 +776,11 @@ ehci_submit_root(struct usb_device *dev, unsigned long pipe, void *buffer, if (HCS_PPC(ehci_readl(&ctrl->hccr->cr_hcsparams))) { reg |= EHCI_PS_PP; ehci_writel(status_reg, reg); +#ifdef CONFIG_USB_EHCI_OMAP + omap_ehci_phy_reset(1, 1000); + mdelay(10); + omap_ehci_phy_reset(0, 1000); +#endif } break; case USB_PORT_FEAT_RESET: diff --git a/drivers/usb/host/ehci-omap.c b/drivers/usb/host/ehci-omap.c index 17f2214..68add44 100644 --- a/drivers/usb/host/ehci-omap.c +++ b/drivers/usb/host/ehci-omap.c @@ -109,7 +109,7 @@ int board_usb_init(void) __attribute__((weak, alias("__board_usb_init"))); #if defined(CONFIG_OMAP_EHCI_PHY1_RESET_GPIO) || \ defined(CONFIG_OMAP_EHCI_PHY2_RESET_GPIO) /* controls PHY(s) reset signal(s) */ -static inline void omap_ehci_phy_reset(int on, int delay) +void omap_ehci_phy_reset(int on, int delay) { /* * Refer ISSUE1: