[PATCHv2 09/12] ARM: OMAP2+: usb_host_fs: add custom setup_preprogram for usb_host_fs (fsusb)

Felipe Balbi balbi at ti.com
Mon Jun 11 05:12:58 EDT 2012


On Mon, Jun 11, 2012 at 01:03:42AM -0700, Tony Lindgren wrote:
> * Felipe Balbi <balbi at ti.com> [120611 00:55]:
> > Hi,
> > 
> > On Mon, Jun 11, 2012 at 12:41:33AM -0700, Tony Lindgren wrote:
> > > > > This should be "static inline int fsusb_reset_host_controller" as it's
> > > > > in a header.
> > > > 
> > > > why is it even in a header ? Only hwmod_fsusb_preprogram() will use it
> > > > anyway.
> > > 
> > > Well ideally it would be something that any OHCI driver can use for
> > > it's reset, and whatever bus code can also call to reset and idle
> > > for the unused devices that don't have the driver compiled in. Got
> > > any better suggestions where to place it? I could be a generic
> > > ohci_reset function in some header?
> > 
> > maybe create <linux/usb/ohci.h> ? Then, while doing that, move register
> > definitions to this new header too... Something like:
> > 
> > $ mv drivers/usb/host/ohci.h include/linux/usb/
> > $ sed -i 's/\"ohci.h\"/<linux/usb/ohci.h>/g' $(git ls-files)
> > 
> > then add your ohci_reset() function...
> 
> Hmm but then again it's pointless to export the all the ohci registers
> as that will lead to misuse outside drivers/usb.. Sounds like just
> defining the reset register is safest option here.

could be as well, but looks like we need to create <linux/usb/ohci.h>
anyway...

-- 
balbi
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 836 bytes
Desc: Digital signature
URL: <http://lists.infradead.org/pipermail/linux-arm-kernel/attachments/20120611/520ef1f8/attachment.sig>


More information about the linux-arm-kernel mailing list