Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751428AbcDOJ7m (ORCPT ); Fri, 15 Apr 2016 05:59:42 -0400 Received: from relmlor4.renesas.com ([210.160.252.174]:32503 "EHLO relmlie3.idc.renesas.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1751164AbcDOJ7h convert rfc822-to-8bit (ORCPT ); Fri, 15 Apr 2016 05:59:37 -0400 X-IronPort-AV: E=Sophos;i="5.22,559,1449500400"; d="scan'208";a="209034385" From: Yoshihiro Shimoda To: Roger Quadros , "stern@rowland.harvard.edu" , "balbi@kernel.org" , "gregkh@linuxfoundation.org" , "peter.chen@freescale.com" CC: "dan.j.williams@intel.com" , "jun.li@freescale.com" , "mathias.nyman@linux.intel.com" , "tony@atomide.com" , "Joao.Pinto@synopsys.com" , "abrestic@chromium.org" , "r.baldyga@samsung.com" , "linux-usb@vger.kernel.org" , "linux-kernel@vger.kernel.org" , "linux-omap@vger.kernel.org" Subject: RE: [PATCH v6 07/12] usb: otg: add OTG/dual-role core Thread-Topic: [PATCH v6 07/12] usb: otg: add OTG/dual-role core Thread-Index: AQHRj0Tb371d8JP1IUix4M6r6OgSS59+LbDwgAA5sgCAAYajwIAEtH8AgASOAyCAACp4gIAAAhUAgAAG6oCAAUYGkA== Date: Fri, 15 Apr 2016 09:59:31 +0000 Message-ID: References: <1459865117-7032-1-git-send-email-rogerq@ti.com> <1459865117-7032-8-git-send-email-rogerq@ti.com> <57064850.3060405@ti.com> <570B8268.6090700@ti.com> <570F7827.8050707@ti.com> <570F7FB3.2040807@ti.com> In-Reply-To: <570F7FB3.2040807@ti.com> Accept-Language: ja-JP, en-US Content-Language: ja-JP X-MS-Has-Attach: X-MS-TNEF-Correlator: authentication-results: ti.com; dkim=none (message not signed) header.d=none;ti.com; dmarc=none action=none header.from=renesas.com; x-originating-ip: [211.11.155.144] x-ms-office365-filtering-correlation-id: 487545cb-73a3-4059-250c-08d36514a3fc x-microsoft-exchange-diagnostics: 1;SG2PR06MB0917;5:o4kCrswz0lahF6IkxDgfUnvrGDeFSEV+NzNiKLEgpaFQHJEarY9ppNl46s2Aa9Y8QdcmxOSKt2UfgV2G41dJxvmWqyd/lSTtPUYjbzaBB0j0857pBGPqrNkxk5fV0ATsRtQAfck3Oin5/ZIFh08Xhw==;24:hXX6HErkn0OnQVHY62VBBa4w2x0fdsgskg6FlSwgHpBCDDqYPO0Prbls2RxoOkG+QzGKpZVu0Fdg+k++/nPykpjgt/xIYeVluV0coXDdCZs=;20:NP0+zqaSCGmtoNtypoLq+NuZ+rhl+wlISJb320ulSjE1AhCvM6EGW+Hw9uaFhKCYgmz7zIIYSGJBbE0iKorWRIpzWF1OhxoxGKnNH1bbF5OgD+qJf53wPYdSHmAnwPQhKj1f7esi+7pKBngXlSVDfosCYFHlugjxTcpFFK4hqhI= x-microsoft-antispam: UriScan:;BCL:0;PCL:0;RULEID:;SRVR:SG2PR06MB0917; x-microsoft-antispam-prvs: x-exchange-antispam-report-test: UriScan:; x-exchange-antispam-report-cfa-test: BCL:0;PCL:0;RULEID:(9101521026)(601004)(2401047)(8121501046)(5005006)(10201501046)(3002001)(6055026);SRVR:SG2PR06MB0917;BCL:0;PCL:0;RULEID:;SRVR:SG2PR06MB0917; x-forefront-prvs: 0913EA1D60 x-forefront-antispam-report: SFV:NSPM;SFS:(10019020)(979002)(6009001)(377454003)(57704003)(24454002)(189998001)(122556002)(1220700001)(1096002)(3846002)(102836003)(6116002)(586003)(11100500001)(81166005)(93886004)(5002640100001)(5004730100002)(76176999)(50986999)(54356999)(4326007)(3660700001)(345774005)(3280700002)(19580395003)(87936001)(2950100001)(2900100001)(5008740100001)(2906002)(74316001)(2501003)(106116001)(2171001)(66066001)(9686002)(33656002)(76576001)(97736004)(2201001)(86362001)(92566002)(5001770100001)(77096005)(5003600100002)(10400500002)(7059030)(969003)(989001)(999001)(1009001)(1019001);DIR:OUT;SFP:1102;SCL:1;SRVR:SG2PR06MB0917;H:SG2PR06MB0919.apcprd06.prod.outlook.com;FPR:;SPF:None;MLV:ovrnspm;PTR:InfoNoRecords;LANG:en; spamdiagnosticoutput: 1:23 spamdiagnosticmetadata: NSPM Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 8BIT MIME-Version: 1.0 X-OriginatorOrg: renesas.com X-MS-Exchange-CrossTenant-originalarrivaltime: 15 Apr 2016 09:59:31.3240 (UTC) X-MS-Exchange-CrossTenant-fromentityheader: Hosted X-MS-Exchange-CrossTenant-id: 53d82571-da19-47e4-9cb4-625a166a4a2a X-MS-Exchange-Transport-CrossTenantHeadersStamped: SG2PR06MB0917 Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 1113 Lines: 39 Hi, > From: Roger Quadros > Sent: Thursday, April 14, 2016 8:32 PM > > On 14/04/16 14:15, Yoshihiro Shimoda wrote: > > Hi, > > < snip > > >>> @@ -865,7 +867,8 @@ int usb_otg_register_hcd(struct usb_hcd *hcd, unsigned int irqnum, > >>> * we're ready only if we have shared HCD > >>> * or we don't need shared HCD. > >>> */ > >>> - if (otg->shared_hcd.hcd || !otg->primary_hcd.hcd->shared_hcd) { > >>> + if (otg->shared_hcd.hcd || (!otg->caps->needs_companion && > >>> + !otg->primary_hcd.hcd->shared_hcd)) { > >>> otg->host = hcd_to_bus(hcd); > >>> /* FIXME: set bus->otg_port if this is true OTG port with HNP */ > >>> > >> > >> These changes look good to me. Thanks. > > > > Thank you for the comment. > > If we change the "needs_companion" place to the otg_config, > > do we need to add a flag into the otg, instead of otg->caps? > > Yes we can add a flag in struct usb_otg. Thank you for the comment. I made a fixed patch. So, should I send this patch to ML after you sent v7 patches? Or, would you apply this patch before you send v7 patches? Best regards, Yoshihiro Shimoda ---