linux-arm-msm.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Peter Chen <peter.chen@freescale.com>
To: Tim Bird <tbird20d@gmail.com>
Cc: "linux-usb@vger.kernel.org" <linux-usb@vger.kernel.org>,
	"balbi@ti.com" <balbi@ti.com>,
	"av.tikhomirov@samsung.com" <av.tikhomirov@samsung.com>,
	"b47624@freescal.com" <b47624@freescal.com>,
	"linux-arm-msm@vger.kernel.org" <linux-arm-msm@vger.kernel.org>,
	"Ivan T. Ivanov" <iivanov@mm-sol.com>,
	b47624@freescale.com
Subject: Re: To otg-fsm or not to otg-fsm? That is the question.
Date: Fri, 15 Aug 2014 08:32:03 +0800	[thread overview]
Message-ID: <20140815003202.GB2710@peterchendt> (raw)
In-Reply-To: <CA+bK7J5hK9YaZ6LyEZXgRiZ8jCLfe_85__xDO=UfqR9ZvP58LQ@mail.gmail.com>

On Tue, Aug 12, 2014 at 09:13:47AM -0700, Tim Bird wrote:
> On Mon, Aug 11, 2014 at 5:28 PM, Peter Chen <Peter.Chen@freescale.com> wrote:
> > The OTG FSM at /usb/common/usb-otg-fsm.c is a software OTG FSM implementation
> > which follows On-The-Go and Embedded Host Supplement to the USB Revision 2.0 Specification
> > (Revision 2.0 version 1.1a) Chapter 7 State Diagrams.
> >
> > If the platform doesn't support hardware otg fsm, it should follow above fsm implementation since
> > it follows the newest OTG & EH spec. Besides, as far as I know, the qualcomm uses
> > chipidea core for its usb2, then it should be easy for qualcomm using this common
> > otg fsm implementation.
> 
> OK.  sounds good.
> 
> Yes, the qualcomm chips use a chipidea core for usb2.  The main
> difficulty, IMHO, will
> be mapping the qcom charger state machine onto the generic OTG state
> machine implementation
> in usb-otg-fsm.  I'm not sure if I'll be able to embed the needed
> functionality into the existing functions
> called by the generic state machine, or if I'll need to add some new
> entries to the function table
> to handle this extra logic.
> 
> I'll probably try to get the driver working without the charger stuff
> first, and then, once I have a
> better idea of how the state machines map, try adding the charger
> stuff.  If I feel like I need
> to modify the generic state machine, I'll ask on list.  I'm a newbie
> at USB stuff and I don't want
> to break anything.
> 
> Thanks.
> 

One remind, you may need to know which role-switch function you need,
if you only need role-switch based in ID pin, then no OTG FSM support
is needed, this is current most of "OTG" device supports, it is not fully
OTG compliance.

-- 
Best Regards,
Peter Chen

      reply	other threads:[~2014-08-15  0:32 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-08-11 20:36 To otg-fsm or not to otg-fsm? That is the question Tim Bird
     [not found] ` <CA+bK7J5=z6gK9S74S=icSPDT70ParW8vv1xYZaj_fNiE7YjFNA-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
2014-08-12  0:28   ` Peter Chen
     [not found]     ` <c33388d4706643cf83b53f1a70289d13-RQSpjbwlmjS6oBnG8T5U3ZwN6zqB+hSMnBOFsp37pqbUKgpGm//BTAC/G2K4zDHf@public.gmane.org>
2014-08-12 16:13       ` Tim Bird
2014-08-15  0:32         ` Peter Chen [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=20140815003202.GB2710@peterchendt \
    --to=peter.chen@freescale.com \
    --cc=av.tikhomirov@samsung.com \
    --cc=b47624@freescal.com \
    --cc=b47624@freescale.com \
    --cc=balbi@ti.com \
    --cc=iivanov@mm-sol.com \
    --cc=linux-arm-msm@vger.kernel.org \
    --cc=linux-usb@vger.kernel.org \
    --cc=tbird20d@gmail.com \
    /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;
as well as URLs for NNTP newsgroup(s).