On Mon, Oct 22, 2012 at 11:18:58AM +0800, Peter Chen wrote:
> On Fri, Oct 19, 2012 at 07:20:01PM +0300, Felipe Balbi wrote:
> > Hi,
> > 
> > On Tue, Oct 16, 2012 at 09:36:46AM +0800, Peter Chen wrote:
> > > The patch includes both API change and caller change.
> > > The main changes like below:
> > > 
> > > - add notify_suspend/notify_resume callback
> > > 
> > > This let usb phy driver has the chance to change hw settings during
> > > the controller suspend/resume procedure.
> > > 
> > > Besides, old parameter "port" is useless for phy notify, as one usb
> > > phy is only for one usb port. New parameter "speed" stands for
> > > the device's speed which is on the port.
> > > 
> > > - implement notify_suspend/notify_resume callback for mxs phy driver
> > > These notify will be called during the bus suspend/resume procedure.
> > > 
> > > - Add phy notify at suspend/resume procedure for chipidea host driver
> > > 
> > > - refine phy notify operation during connection and disconnection
> > > 
> > > The history of this problem like below:
> > > At some i.mx SoCs, when controller works at host mode, the PHY
> > > register needs to be changed at device connect, disconnect, bus
> > > suspend and resume due to the SoC limitations.
> > > 
> > > The phy notification should be added according to below rules:
> > > 
> > > 1. Only set HW_USBPHY_CTRL.ENHOSTDISCONDETECT
> > > during high speed host mode.
> > > 2. Do not set HW_USBPHY_CTRL.ENHOSTDISCONDETECT
> > > during the reset and speed negotiation period.
> > > 3. Do not set HW_USBPHY_CTRL.ENHOSTDISCONDETECT
> > > during host suspend/resume sequence.
> > > 
> > > Please refer: i.mx23RM(page 413) for detail.
> > > http://www.freescale.com/files/dsp/doc/ref_manual/IMX23RM.pdf
> > > 
> > > Freescale i.MX SoC, i.mx23, i.mx28 and i.mx6(i.mx6SL does not
> > > need to follow the 3rd rule) need to follow above rules.
> > > 
> > > The correct notification setting method should be:
> > > 1. Set connect notify after the second bus reset.
> > > 2. Set disconnect notify after disconnection.
> > > 3. Set suspend nofity after bus goes to suspend (portsc.suspendM=1).
> > > 4. Set resume notify after resume (portsc.fpr=0).
> > > 
> > > Signed-off-by: Peter Chen <peter.c...@freescale.com>
> > > Tested-by: Mike Thompson <mpthomp...@gmail.com>
> > 
> > sorry but you're doing too much in a single patch. Please split the
> > patch before I review it any further.
> Ok, I will. But I will put *.h and *.c at one patch to avoid git bitsec
> error.

that's fine, it doesn't matter how many files you touch as long as the
patch is a single, logical, self-contained change. Look at how many
things you're doing in a single patch:

you add new function pointers to a structure, you implement those for
mxs phy driver, you make changes to connect/disconnect sequence of the
phy and so on... all those should be split to their own patch.

-- 
balbi

Attachment: signature.asc
Description: Digital signature

Reply via email to