From patchwork Mon Jul 29 15:06:38 2013 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Felipe Balbi X-Patchwork-Id: 2835037 Return-Path: X-Original-To: patchwork-linux-arm@patchwork.kernel.org Delivered-To: patchwork-parsemail@patchwork1.web.kernel.org Received: from mail.kernel.org (mail.kernel.org [198.145.19.201]) by patchwork1.web.kernel.org (Postfix) with ESMTP id 0A22A9F9CE for ; Mon, 29 Jul 2013 15:07:49 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id CB8EE202C7 for ; Mon, 29 Jul 2013 15:07:47 +0000 (UTC) Received: from casper.infradead.org (casper.infradead.org [85.118.1.10]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id 79219202C6 for ; Mon, 29 Jul 2013 15:07:46 +0000 (UTC) Received: from merlin.infradead.org ([2001:4978:20e::2]) by casper.infradead.org with esmtps (Exim 4.80.1 #2 (Red Hat Linux)) id 1V3p2o-0004ZS-Hh; Mon, 29 Jul 2013 15:07:30 +0000 Received: from localhost ([::1] helo=merlin.infradead.org) by merlin.infradead.org with esmtp (Exim 4.80.1 #2 (Red Hat Linux)) id 1V3p2b-0005JF-NA; Mon, 29 Jul 2013 15:07:17 +0000 Received: from comal.ext.ti.com ([198.47.26.152]) by merlin.infradead.org with esmtps (Exim 4.80.1 #2 (Red Hat Linux)) id 1V3p2V-0005Ht-KT for linux-arm-kernel@lists.infradead.org; Mon, 29 Jul 2013 15:07:12 +0000 Received: from dlelxv90.itg.ti.com ([172.17.2.17]) by comal.ext.ti.com (8.13.7/8.13.7) with ESMTP id r6TF6maA025824; Mon, 29 Jul 2013 10:06:48 -0500 Received: from DFLE72.ent.ti.com (dfle72.ent.ti.com [128.247.5.109]) by dlelxv90.itg.ti.com (8.14.3/8.13.8) with ESMTP id r6TF6mV2019632; Mon, 29 Jul 2013 10:06:48 -0500 Received: from dlelxv22.itg.ti.com (172.17.1.197) by DFLE72.ent.ti.com (128.247.5.109) with Microsoft SMTP Server id 14.2.342.3; Mon, 29 Jul 2013 10:06:47 -0500 Received: from localhost (h79-4.vpn.ti.com [172.24.79.4]) by dlelxv22.itg.ti.com (8.13.8/8.13.8) with ESMTP id r6TF6kHt025279; Mon, 29 Jul 2013 10:06:47 -0500 Date: Mon, 29 Jul 2013 18:06:38 +0300 From: Felipe Balbi To: Kishon Vijay Abraham I Subject: Re: [PATCH 2/2] arm: omap: remove *.auto* from device names given in usb_bind_phy Message-ID: <20130729150638.GD3063@radagast> References: <1374829418-27503-1-git-send-email-kishon@ti.com> <1374829418-27503-3-git-send-email-kishon@ti.com> MIME-Version: 1.0 In-Reply-To: <1374829418-27503-3-git-send-email-kishon@ti.com> User-Agent: Mutt/1.5.21 (2010-09-15) X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20130729_110711_770274_5C63859E X-CRM114-Status: GOOD ( 19.80 ) X-Spam-Score: -8.4 (--------) Cc: linux@arm.linux.org.uk, tony@atomide.com, gregkh@linuxfoundation.org, linux-usb@vger.kernel.org, linux-kernel@vger.kernel.org, balbi@ti.com, eballetbo@gmail.com, javier@dowhile0.org, linux-omap@vger.kernel.org, linux-arm-kernel@lists.infradead.org X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.15 Precedence: list Reply-To: balbi@ti.com List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+patchwork-linux-arm=patchwork.kernel.org@lists.infradead.org X-Spam-Status: No, score=-5.7 required=5.0 tests=BAYES_00, RCVD_IN_DNSWL_MED, RP_MATCHES_RCVD, UNPARSEABLE_RELAY autolearn=unavailable version=3.3.1 X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on mail.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP Hi, On Fri, Jul 26, 2013 at 02:33:38PM +0530, Kishon Vijay Abraham I wrote: > Previously MUSB wrapper (OMAP) device used PLATFORM_DEVID_AUTO while creating > MUSB core device. So in usb_bind_phy (binds the controller with the PHY), the > device name of the controller had *.auto* in it. Since with using > PLATFORM_DEVID_AUTO, there is no way to know the exact device name in advance, > the data given in usb_bind_phy became obsolete and usb_get_phy was failing. > So MUSB wrapper was modified not to use PLATFORM_DEVID_AUTO. Corresponding > change is done in board file here. > > Signed-off-by: Kishon Vijay Abraham I > --- > arch/arm/mach-omap2/board-2430sdp.c | 2 +- > arch/arm/mach-omap2/board-3430sdp.c | 2 +- > arch/arm/mach-omap2/board-cm-t35.c | 2 +- > arch/arm/mach-omap2/board-devkit8000.c | 2 +- > arch/arm/mach-omap2/board-igep0020.c | 2 +- > arch/arm/mach-omap2/board-ldp.c | 2 +- > arch/arm/mach-omap2/board-omap3beagle.c | 2 +- > arch/arm/mach-omap2/board-omap3evm.c | 2 +- > arch/arm/mach-omap2/board-omap3logic.c | 2 +- > arch/arm/mach-omap2/board-omap3pandora.c | 2 +- > arch/arm/mach-omap2/board-omap3stalker.c | 2 +- > arch/arm/mach-omap2/board-omap3touchbook.c | 2 +- > arch/arm/mach-omap2/board-overo.c | 2 +- > arch/arm/mach-omap2/board-rm680.c | 2 +- > arch/arm/mach-omap2/board-rx51.c | 2 +- > arch/arm/mach-omap2/board-zoom-peripherals.c | 2 +- > 16 files changed, 16 insertions(+), 16 deletions(-) > > diff --git a/arch/arm/mach-omap2/board-2430sdp.c b/arch/arm/mach-omap2/board-2430sdp.c > index 244d8a5..17bb076 100644 > --- a/arch/arm/mach-omap2/board-2430sdp.c > +++ b/arch/arm/mach-omap2/board-2430sdp.c > @@ -233,7 +233,7 @@ static void __init omap_2430sdp_init(void) > omap_hsmmc_init(mmc); > > omap_mux_init_signal("usb0hs_stp", OMAP_PULL_ENA | OMAP_PULL_UP); > - usb_bind_phy("musb-hdrc.0.auto", 0, "twl4030_usb"); > + usb_bind_phy("musb-hdrc.0", 0, "twl4030_usb"); how about moving usb_bind_phy() calls to omap2430.c ? The only problem is if some board comes with a PHY other than twl4030_usb, but in that case we can add a separate compatible flag and treat it properly. We only need to bind the phy in non-DT case anyway, so that's temporary. It might be better than to reintroduce the IDR in musb_core.c. diff --git a/drivers/usb/musb/omap2430.c b/drivers/usb/musb/omap2430.c index f44e8b5..b6abc1a 100644 --- a/drivers/usb/musb/omap2430.c +++ b/drivers/usb/musb/omap2430.c @@ -544,6 +544,9 @@ static int omap2430_probe(struct platform_device *pdev) pdata->board_data = data; pdata->config = config; + } else { + /* bind the PHY */ + usb_bind_phy(dev_name(&musb->dev), 0, "twl4030_usb"); } if (pdata->has_mailbox) {