From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751337AbdASHiv (ORCPT ); Thu, 19 Jan 2017 02:38:51 -0500 Received: from mail.linuxfoundation.org ([140.211.169.12]:53574 "EHLO mail.linuxfoundation.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751118AbdASHit (ORCPT ); Thu, 19 Jan 2017 02:38:49 -0500 Date: Thu, 19 Jan 2017 08:39:01 +0100 From: Greg Kroah-Hartman To: Peter Chen Cc: Stephen Boyd , linux-usb@vger.kernel.org, Felipe Balbi , Arnd Bergmann , Neil Armstrong , linux-arm-msm@vger.kernel.org, linux-kernel@vger.kernel.org, Bjorn Andersson , devicetree@vger.kernel.org, Peter Chen , Andy Gross , linux-arm-kernel@lists.infradead.org Subject: Re: [PATCH v6 03/25] usb: ulpi: Support device discovery via DT Message-ID: <20170119073901.GF14493@kroah.com> References: <20161228225711.698-1-stephen.boyd@linaro.org> <20161228225711.698-4-stephen.boyd@linaro.org> <20170119063349.GB10621@b29397-desktop> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20170119063349.GB10621@b29397-desktop> User-Agent: Mutt/1.7.2 (2016-11-26) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Thu, Jan 19, 2017 at 02:33:49PM +0800, Peter Chen wrote: > On Wed, Dec 28, 2016 at 02:56:49PM -0800, Stephen Boyd wrote: > > The qcom HSIC ULPI phy doesn't have any bits set in the vendor or > > product ID registers. This makes it impossible to make a ULPI > > driver match against the ID registers. Add support to discover > > the ULPI phys via DT help alleviate this problem. In the DT case, > > we'll look for a ULPI bus node underneath the device registering > > the ULPI viewport (or the parent of that device to support > > chipidea's device layout) and then match up the phy node > > underneath that with the ULPI device that's created. > > > > The side benefit of this is that we can use standard properties > > in the phy node like clks, regulators, gpios, etc. because we > > don't have firmware like ACPI to turn these things on for us. And > > we can use the DT phy binding to point our phy consumer to the > > phy provider. > > > > The ULPI bus code supports native enumeration by reading the > > vendor ID and product ID registers at device creation time, but > > we can't be certain that those register reads will succeed if the > > phy is not powered up. To avoid any problems with reading the ID > > registers before the phy is powered we fallback to DT matching > > when the ID reads fail. > > > > If the ULPI spec had some generic power sequencing for these > > registers we could put that into the ULPI bus layer and power up > > the device before reading the ID registers. Unfortunately this > > doesn't exist and the power sequence is usually device specific. > > By having the device matched up with DT we can avoid this > > problem. > > > > Cc: Greg Kroah-Hartman > > Acked-by: Heikki Krogerus > > Cc: > > Acked-by: Rob Herring > > Signed-off-by: Stephen Boyd > > Greg, is it ok I pick up this patch, and send it with chipidea > changes together for 4.11-rc1 later? No objection from me. thanks, greg k-h