Thread (24 messages) 24 messages, 5 authors, 2015-02-27

[PATCH v4 4/4] phy: add phy-hi6220-usb

From: zhangfei.gao@linaro.org (zhangfei)
Date: 2015-02-20 10:27:36
Also in: linux-devicetree, lkml


On 02/20/2015 12:38 PM, Felipe Balbi wrote:
On Fri, Feb 20, 2015 at 11:07:21AM +0800, zhangfei wrote:
quoted
Hi, Balbi

On 02/18/2015 10:35 PM, Felipe Balbi wrote:
quoted
On Wed, Feb 18, 2015 at 01:44:21PM +0800, zhangfei wrote:
quoted
Hi, Kishon

On 02/18/2015 01:35 PM, Kishon Vijay Abraham I wrote:
quoted
Hi,

On Thursday 12 February 2015 01:07 PM, Zhangfei Gao wrote:
quoted
Add usb phy controller for hi6220 platform

Signed-off-by: Zhangfei Gao <zhangfei.gao@linaro.org>
---
  drivers/phy/Kconfig          |   9 ++
  drivers/phy/Makefile         |   1 +
  drivers/phy/phy-hi6220-usb.c | 306
+++++++++++++++++++++++++++++++++++++++++++
  3 files changed, 316 insertions(+)
  create mode 100644 drivers/phy/phy-hi6220-usb.c
why is this driver in drivers/phy when it doesn't use the generic PHY
framework at all?
Balbi recommended "new drivers only on drivers/phy/", including usb
phy.
but it should use the API too. It's not only about a directory, you need
to use the new API.
quoted
So Move drivers/usb/phy/phy-hi6220-usb.c to
drivers/phy/phy-hi6220-usb.c, required by Balbi.
you're reading what I stated the way you like.
Sorry for my bad understanding.

Still not clear about the otg_set_peripheral, which is required in
phy-hi6220-usb.c

1. drivers/usb/dwc2/gadget.c use
otg_set_peripheral(hsotg->uphy->otg, &hsotg->gadget);

2. include/linux/phy/phy.h
struct phy do not have member otg, while struct usb_phy has.

Could you give more hints?
your set_peripheral doesn't do anything, just holds a pointer. Might as
well not implement it. I'll review your driver more fully tomorrow.

There a few things which must be changed.
Thanks in advance.

We need this call back set_peripheral setting otg->gadget, which used in 
usb_gadget_connect/disconnect(otg->gadget).

The workable method test here is not provide phy-names = "usb2-phy";
Then dwc2 will still use hsotg->uphy instead of hsotg->phy.
Though devm_phy_create is used in phy-hi6220-usb.c, phy_ops is not used 
in fact.

Thanks
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help