[Gta04-owner] Modem crashing?

NeilBrown neilb at suse.de
Sat Feb 18 11:47:51 CET 2012

On Sat, 18 Feb 2012 10:17:06 +0100 "Dr. H. Nikolaus Schaller"
<hns at goldelico.com> wrote:

> Am 18.02.2012 um 07:08 schrieb NeilBrown:
> > On Sat, 18 Feb 2012 06:14:44 +0100 xdrudis <xdrudis at tinet.cat> wrote:
> > 
> >> On Fri, Feb 17, 2012 at 04:56:03PM +0100, Marcel Holtmann wrote:
> >>> Hi Butrus,
> >>> 
> >>>>> we already fixed this bug with CLCC polling inside oFono. That is not
> >>>>> the problem.
> >>>>> 
> >>>>> The one thing that nobody realizes here is that this workaround comes at
> >>>>> a high price. You have to do constant polling while being in an active
> >>>>> call.
> >>>> 
> >>>> Really _constant_? Would it be enough to wake once in 2 or 5 seconds
> >>>> (or so)? How much time would one "poll" take? If e.g. it would take
> >>>> say 100ms and you wake every 5 seconds (for example), the overall
> >>>> power consumption would be reduced drastically...
> >>> 
> >>> we poll every 500ms since that is the expected latency that we can
> >>> expect from a user. Anything less we result in bad user experience.
> >> 
> >> Ok. If I understood correctly we have a GSM chip that isn't able to
> >> wake up the system when it detects a remote hangup in a voice call. So
> >> when must keep the cpu and usb path awake too often to poll the GSM
> >> chip and that drains battery.
> > 
> > I don't think it is quite that simple.
> > We have a GSM chip for which we do not have complete documentation,
> > for which the firmware is a little old, and which does not behave exactly the
> > same as other GSM chips people are familiar with.
> > 
> > If I call my GTA04, answer the call, and then hang up, I do not get 
> > on the 'Application' port (which is where I get e.g. "RING" indications).
> > However I *do* get "NO CARRIER" on the Modem port.
> > A little surprising but possibly quite usable.  There may be other surprises
> > for those willing to explore.
> Indeed surprising! Hm. Can we tap the modem port or is it used (via
> the hso driver) for networking? Or is there a bug in the hso driver that
> shuts down USB as soon as it finds the NO CARRIER on the modem
> port? There must be some automatic since the network setup is
> going fully automatic.

I don't think it is used for networking - there is a completely separate
network interface (hso0) for networking.  I suspect we can just hold both
Application and Modem open and take messages from either.

But there is more to discover here I think.

> > 
> > When I dial out it seems a little different.  I try to hang up with ATH
> > but "AT+CPAS" indicates I am still on a call.  When the other end hangs up,
> > then I get NO CARRIER.
> I think I remember that there was a note that ATH is not reliable and we
> should use AT+CHUP

Ahh, that is useful, thanks.

> This brings me to an idea: is there a gradual suspend? For such
> polling of the modem during a voice call we don't need the CPU to run at
> 800 MHz. I would assume that 1 MHz could be sufficient...

OMAP3 has a thing called DVFS - Dynamic Voltage and Frequency Scaling.
It can reduce V and F when the load it light to save power.  I don't think it
goes as low as 1MHz though.

However the accepted wisdom seems to be that the gains there are small.  It
is best to get everything done quickly, and then go to sleep for a while.
Total power can be less (though there are lots of details and trade-offs).

When there is nothing to do (say between 200ms polls if they were needed) the
power usage should go down fairly close to suspend.  It cannot get quite that
low though.
If we want to get unsolicited messages from the Option, then the USB bus
needs to be active and so be polling the Option every few milliseconds (that
is the way USB works).  If you turn off the USB bus to save power (as I think
we do in suspend), then the only signals we get from the Option are the
interrupt line which fires on incoming-call and incoming-text (I assume).  It
doesn't seem to fire on 'NO CARRIER', so we need the USB powered to receive

The short answer is that:
 - we cannot safely suspend during a call or we will definitely miss call
 - we should certainly try to do as little work as possible, but that is
   always the case
 - we can get 'call finished' notifications at least in some cases
 - general runtime-power-management is probably the best we can do to save
   power while not suspended.


-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 828 bytes
Desc: not available
URL: <http://lists.goldelico.com/pipermail/gta04-owner/attachments/20120218/db2d90a8/attachment-0001.bin>

More information about the Gta04-owner mailing list