From: Mark Underwood <basicmark@yahoo.com>
To: Pavel Machek <pavel@ucw.cz>
Cc: Richard Purdie <rpurdie@rpsys.net>,
David Vrabel <dvrabel@cantab.net>,
lenz@cs.wisc.edu, kernel list <linux-kernel@vger.kernel.org>,
dkrivoschokov@dev.rtsoft.ru
Subject: Re: pxa27x_udc -- support for usb gadget for pxa27x?
Date: Sat, 26 Nov 2005 23:02:33 +0000 (GMT) [thread overview]
Message-ID: <20051126230233.28402.qmail@web36911.mail.mud.yahoo.com> (raw)
In-Reply-To: <20051126210840.GE17663@elf.ucw.cz>
--- Pavel Machek <pavel@ucw.cz> wrote:
> Hi!
>
> > > > Ultimately, it would be nice to have the Zaurus detect whether a usb
> > > > host or client was present (using gpio 41 maybe?) and then activate the
> > > > host (ohci) or client (pxa27x_udc) driver as appropriate.
> > >
> > > Unfortunately, that would make ohci unfunctional for me. I have normal
> > > usb device cable, connected to "USB gender changer" -- basically two
> > > female connectors -- so that I can plug USB network card into that.
> > >
> >
> > Just a thought. How about a sysfs entry which you can use to jam the device into either slave
> or
> > host mode?
>
> Yes, that would do the trick. Auto sense is probably good solution,
> too, it is just that it should have /sys override or something like
> that.
>
> Pavel
That is what I was thinking. Do you have an OTG device in your sysfs tree in which you could add
this?
I have been working on a platform which also has OTG and I have been thinking how to handle OTG in
a generic way.
A while back I started work on an OTG subsystem as there doesnt seem to be any standard way of
implementing OTG controller driver in the kernel. The only example I could find was the TI OMAP
which has all the OTG stuff in the driver for the external transceiver (plus it also seemed to
have 3 or 4 OTG state machines). The idea of the subsystem is to break the OTG driver into its
constituent parts:
USB Host driver : This is already is the kernel and shouldnt require any alteration.
USB Device driver: Again, the OTG subsystem should use the current framework.
USB Logic driver: This is the part of the OTG hardware that connects the slave or the host the
physical connector plus clock control etc.
USB Transceiver: This driver generates the special signals the OTG protocol uses as well as
detecting the signals that will cause a change of state in the state machine.
USB state machine: Some hardware has the state machine build into them, some dont, and some have
an incomplete implementation. This driver will implement in software what is lacking in the
hardware state machine.
This flexible subsystem should allow you to combine any USB master, USB device, USB OTG logic and
transceiver (be it internal as part of the OTG block or an external transceiver). This is only in
the early stages of development and I would need to talk to the USB guys first to see what I have
missed (I need to have another look at the otg_transceiver struct again). What would be great to
see in sysfs is something like:
/sys/devices/platform/otg1
|--host (symbolic link to device)
|--gadget (symbolic link to device)
|--otg_logic (symbolic link to device)
|--transceiver (symbolic link to device)
`--force_mode
Just an idea!
Mark
> Thanks, Sharp!
> -
> To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
> the body of a message to majordomo@vger.kernel.org
> More majordomo info at http://vger.kernel.org/majordomo-info.html
> Please read the FAQ at http://www.tux.org/lkml/
>
___________________________________________________________
How much free photo storage do you get? Store your holiday
snaps for FREE with Yahoo! Photos http://uk.photos.yahoo.com
prev parent reply other threads:[~2005-11-26 23:02 UTC|newest]
Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top
2005-11-03 22:14 Pavel Machek
2005-11-03 22:35 ` Richard Purdie
2005-11-06 19:47 ` Pavel Machek
2005-11-06 20:45 ` Pavel Machek
2005-11-07 10:25 ` David Vrabel
2005-11-07 10:43 ` Richard Purdie
2005-11-26 19:24 ` Pavel Machek
2005-11-26 19:36 ` make oldconfig issues since 2.15-rc1-mm1 Stef van der Made
2005-11-26 21:04 ` pxa27x_udc -- support for usb gadget for pxa27x? Mark Underwood
2005-11-26 21:08 ` Pavel Machek
2005-11-26 23:02 ` Mark Underwood [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20051126230233.28402.qmail@web36911.mail.mud.yahoo.com \
--to=basicmark@yahoo.com \
--cc=dkrivoschokov@dev.rtsoft.ru \
--cc=dvrabel@cantab.net \
--cc=lenz@cs.wisc.edu \
--cc=linux-kernel@vger.kernel.org \
--cc=pavel@ucw.cz \
--cc=rpurdie@rpsys.net \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®