All of lore.kernel.org
 help / color / mirror / Atom feed
From: Roger Quadros <rogerq@ti.com>
To: NeilBrown <neilb@suse.de>
Cc: linux-omap@vger.kernel.org
Subject: Re: Help wanted with USB and OMAP3 off_mode
Date: Wed, 16 Jan 2013 12:00:48 +0200	[thread overview]
Message-ID: <50F67A50.5020203@ti.com> (raw)
In-Reply-To: <20130109092915.1c2077b5@notabene.brown>

On 01/09/2013 12:29 AM, NeilBrown wrote:
> 
> Hi,
>  I'm trying to get off_mode working reliably on my gta04 mobile phone.
> 
> My current stumbling block is USB.  The "Option" GSM module is attached via
> USB (there is a separate transceiver chip attached to port 1 which is placed
> in OMAP_EHCI_PORT_MODE_PHY).
> 
> After a suspend/resume cycle with off_mode enabled the GSM module disappears.
> i.e. 'lsusb' doesn't see it any more and the various ttyHSxx devices don't
> exist.
> Without off mode, the modem always appears after resume.
> 
> I discovered that the registers set by:
> 
>    drivers/mfd/omap-usb-host.c
> 
> are not maintained across as suspend/resume so I added the following patch
> (which I can make a formal submission of if it looks right to others), but
> that didn't help (or didn't help enough).
> 
> If I
> 
>   echo 1 > /sys/kernel/debug/pm_debug/usbhost_pwrdm/suspend
> 
> thus keeping just the USBHOST power domain out of off_mode, the GSM module
> doesn't disappear.  So it seems that some context in the usbhost domain is
> not being save and restored.
> 
> This is as far as I can get.  Can someone suggest where I should look to find
> out what is not being saved/restored properly, and how to go about saving and
> restoring?

You need to ensure that USBHOST/TLL context is saved as per the Save and
Restore sequence see section "USBHOST/USBTLL Save-and-Restore
Management" in the OMAP Technical Reference Manual.

The basic idea there is that software does the context saving into SAR
RAM before entering OFF mode and hardware automatically restores the
context after coming out of OFF mode.

But that alone is not enough for USB host to work. We need to make sure
we have covered all the erratas. There are a number of them which are
not covered yet in mainline.

USB remote wakeup is another challenge with OMAP USB host (while in OFF
mode). The usual workaround here is to use a GPIO as a wakeup line from
the modem.

regards,
-roger


  parent reply	other threads:[~2013-01-16 10:01 UTC|newest]

Thread overview: 21+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-01-08 22:29 Help wanted with USB and OMAP3 off_mode NeilBrown
2013-01-09 10:00 ` Igor Grinberg
2013-01-09 10:19   ` NeilBrown
2013-01-09 10:24     ` Michael Trimarchi
2013-01-09 11:34       ` NeilBrown
2013-01-09 11:42         ` Michael Trimarchi
2013-01-16  7:28           ` NeilBrown
2013-01-09 12:08         ` Michael Trimarchi
2013-01-09 12:54           ` Igor Grinberg
2013-01-16  7:26             ` NeilBrown
2013-01-16  9:28               ` Igor Grinberg
2013-01-16 10:19                 ` NeilBrown
2013-01-16 11:11                   ` Igor Grinberg
2013-01-17  0:22                     ` NeilBrown
2013-01-17  9:24                       ` NeilBrown
2013-01-16 10:00 ` Roger Quadros [this message]
2013-01-16 10:27   ` NeilBrown
2013-01-16 10:57     ` Roger Quadros
2013-01-17 11:01       ` NeilBrown
2013-01-17 11:29         ` Roger Quadros
2013-01-17 21:08           ` NeilBrown

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=50F67A50.5020203@ti.com \
    --to=rogerq@ti.com \
    --cc=linux-omap@vger.kernel.org \
    --cc=neilb@suse.de \
    /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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.