Re: [V8 PATCH 01/16] usb: phy: mv_usb2: add PHY driver for marvell usb2 controller

2013-03-06 Thread Chao Xie
On Thu, Mar 7, 2013 at 12:48 AM, Russell King - ARM Linux wrote: > On Wed, Mar 06, 2013 at 04:24:58PM +0800, Chao Xie wrote: >> The clock numbers and names are depent of SOCes, > > No they aren't. The clock names used to describe them in your documentation > may vary, but their _purpose_ for the

Re: [V8 PATCH 01/16] usb: phy: mv_usb2: add PHY driver for marvell usb2 controller

2013-03-06 Thread Russell King - ARM Linux
On Wed, Mar 06, 2013 at 04:24:58PM +0800, Chao Xie wrote: > The clock numbers and names are depent of SOCes, No they aren't. The clock names used to describe them in your documentation may vary, but their _purpose_ for the sake of the device will be fixed - and you should name them appropriately

Re: [V8 PATCH 01/16] usb: phy: mv_usb2: add PHY driver for marvell usb2 controller

2013-03-06 Thread Russell King - ARM Linux
On Tue, Mar 05, 2013 at 10:03:01AM +0800, Chao Xie wrote: > On Mon, Mar 4, 2013 at 10:21 PM, Felipe Balbi wrote: > > On Wed, Feb 20, 2013 at 11:07:11PM -0500, Chao Xie wrote: > >> + for (i = 0; i < mv_phy->clks_num; i++) { > >> + mv_phy->clks[i] = devm_clk_get(&pdev->dev, > >> +

Re: [V8 PATCH 01/16] usb: phy: mv_usb2: add PHY driver for marvell usb2 controller

2013-03-06 Thread Felipe Balbi
On Wed, Mar 06, 2013 at 05:02:28PM +0800, Chao Xie wrote: > On Wed, Mar 6, 2013 at 4:53 PM, Felipe Balbi wrote: > > On Wed, Mar 06, 2013 at 04:24:58PM +0800, Chao Xie wrote: > >> On Wed, Mar 6, 2013 at 4:10 PM, Felipe Balbi wrote: > >> > Hi, > >> > > >> > On Wed, Mar 06, 2013 at 10:11:41AM +0800,

Re: [V8 PATCH 01/16] usb: phy: mv_usb2: add PHY driver for marvell usb2 controller

2013-03-06 Thread Chao Xie
On Wed, Mar 6, 2013 at 4:53 PM, Felipe Balbi wrote: > On Wed, Mar 06, 2013 at 04:24:58PM +0800, Chao Xie wrote: >> On Wed, Mar 6, 2013 at 4:10 PM, Felipe Balbi wrote: >> > Hi, >> > >> > On Wed, Mar 06, 2013 at 10:11:41AM +0800, Chao Xie wrote: >> >> 3. For the revison register. It exists in some

Re: [V8 PATCH 01/16] usb: phy: mv_usb2: add PHY driver for marvell usb2 controller

2013-03-06 Thread Felipe Balbi
On Wed, Mar 06, 2013 at 04:24:58PM +0800, Chao Xie wrote: > On Wed, Mar 6, 2013 at 4:10 PM, Felipe Balbi wrote: > > Hi, > > > > On Wed, Mar 06, 2013 at 10:11:41AM +0800, Chao Xie wrote: > >> 3. For the revison register. It exists in some SOCes(pxa168), but for > >> some SOCes, the register dispear

Re: [V8 PATCH 01/16] usb: phy: mv_usb2: add PHY driver for marvell usb2 controller

2013-03-06 Thread Chao Xie
On Wed, Mar 6, 2013 at 4:10 PM, Felipe Balbi wrote: > Hi, > > On Wed, Mar 06, 2013 at 10:11:41AM +0800, Chao Xie wrote: >> 3. For the revison register. It exists in some SOCes(pxa168), but for >> some SOCes, the register dispears(pxa910, armada610). These SOCes are >> developed by different desgin

Re: [V8 PATCH 01/16] usb: phy: mv_usb2: add PHY driver for marvell usb2 controller

2013-03-06 Thread Felipe Balbi
Hi, On Wed, Mar 06, 2013 at 10:11:41AM +0800, Chao Xie wrote: > 3. For the revison register. It exists in some SOCes(pxa168), but for > some SOCes, the register dispears(pxa910, armada610). These SOCes are > developed by different desgin teams, and it need to be enhanced, but > for current product

Re: [V8 PATCH 01/16] usb: phy: mv_usb2: add PHY driver for marvell usb2 controller

2013-03-05 Thread Chao Xie
On Tue, Mar 5, 2013 at 7:04 PM, Felipe Balbi wrote: > Hi, > > On Tue, Mar 05, 2013 at 10:03:01AM +0800, Chao Xie wrote: >> >> +enum mv_usb2_phy_type { >> >> + PXA168_USB, >> >> + PXA910_USB, >> >> + MMP2_USB, >> >> +}; >> > >> > >> > ewww... you really don't need (and *shouldn't* use)

Re: [V8 PATCH 01/16] usb: phy: mv_usb2: add PHY driver for marvell usb2 controller

2013-03-05 Thread Felipe Balbi
On Tue, Mar 05, 2013 at 11:43:35AM -0500, Alan Stern wrote: > On Tue, 5 Mar 2013, Felipe Balbi wrote: > > > Anyway, details are as follows: > > > > readl() and writel() always add a memory barrier around each operation. > > Is that supposed to be true on all architectures or only on ARM? I beli

Re: [V8 PATCH 01/16] usb: phy: mv_usb2: add PHY driver for marvell usb2 controller

2013-03-05 Thread Alan Stern
On Tue, 5 Mar 2013, Felipe Balbi wrote: > Anyway, details are as follows: > > readl() and writel() always add a memory barrier around each operation. Is that supposed to be true on all architectures or only on ARM? Alan Stern -- To unsubscribe from this list: send the line "unsubscribe linux-u

Re: [V8 PATCH 01/16] usb: phy: mv_usb2: add PHY driver for marvell usb2 controller

2013-03-05 Thread Felipe Balbi
Hi, On Tue, Mar 05, 2013 at 10:03:01AM +0800, Chao Xie wrote: > >> +enum mv_usb2_phy_type { > >> + PXA168_USB, > >> + PXA910_USB, > >> + MMP2_USB, > >> +}; > > > > > > ewww... you really don't need (and *shouldn't* use) u2o_set() or > > u2o_clear(). They clearly prevent compiler from o

Re: [V8 PATCH 01/16] usb: phy: mv_usb2: add PHY driver for marvell usb2 controller

2013-03-04 Thread Chao Xie
On Mon, Mar 4, 2013 at 10:21 PM, Felipe Balbi wrote: > On Wed, Feb 20, 2013 at 11:07:11PM -0500, Chao Xie wrote: >> The PHY is seperated from usb controller. >> The usb controller used in marvell pxa168/pxa910/mmp2 are same, >> but PHY initialization may be different. >> the usb controller can sup

Re: [V8 PATCH 01/16] usb: phy: mv_usb2: add PHY driver for marvell usb2 controller

2013-03-04 Thread Felipe Balbi
On Wed, Feb 20, 2013 at 11:07:11PM -0500, Chao Xie wrote: > The PHY is seperated from usb controller. > The usb controller used in marvell pxa168/pxa910/mmp2 are same, > but PHY initialization may be different. > the usb controller can support udc/otg/ehci, and for each of > the mode, it need PHY t

[V8 PATCH 01/16] usb: phy: mv_usb2: add PHY driver for marvell usb2 controller

2013-02-20 Thread Chao Xie
The PHY is seperated from usb controller. The usb controller used in marvell pxa168/pxa910/mmp2 are same, but PHY initialization may be different. the usb controller can support udc/otg/ehci, and for each of the mode, it need PHY to initialized before use the controller. Direclty writing the phy dr