Full list of actual GPIO states in suspend

Andy Green andy at openmoko.com
Sat Feb 23 10:28:19 CET 2008


-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Hi folks -

Back in early Janurary on a thread "GTA02 suspend experiment result
20080107" I suggested the following:

>  - Save GPIO register state just before we turn the power off and dump
> them, then audit them against the schematic

I have now implemented this and we can see our full GPIO situation
(which is held like that during suspend) at the moment we are about to
push the CPU into suspend state, after all the drivers have "settled
down for the night" and made their changes to GPIO for lowest current.

This is interesting information because one of the two worst monster
issues we have left is that we currently suffer from variable GSM
suspend current suspend by suspend.  Roughly ~80% of the time we find
5mA at Vb (nom 3.7V --> 18.5mW) drawn by the GSM module in deep sleep,
but ~20% of the time we find an idle suspend current draw of 18mA (at Vb
- --> 66mW) which is definitely unacceptable and confounds explanation
so far.

Allen did a violently cool experiment (his name in the Matrix is "The
Reworker") to crack down on this by measuring suspend behaviour on the
GSM side before and after physically removing the CPU from the PCB, and
the result was that without a CPU (the GSM module is controlled
externally over a LVTTL UART connection) we never see the bad suspend
current behaviour from the GSM side.

I thought of three ways (there can be more!) that can pan out

 - the protocol sequencing on the software with a real CPU is the cause,
when we do the simplified testing Allen did with AT commands the error
does not come

 - there is a race during suspend, with the real CPU software we
sometimes issue something to the GSM stuff or we leave for suspend
partway through a multi-step AT command sequence where the GSM firmware
is not ready to fully suspend

 - Some other CPU GPIO that connects to the device is sometimes left in
a conflicting state at suspend and current flows from the GSM side into
this bad GPIO

Anyway here is the raw list from one run to get us started, I will send
the patch used to generate it (it's dirty alright but it's fine for
debug-only) and then analysis of the obvious problems.

[   58.325000] GPB00: TOUT0       0
[   58.325000] GPB01: TOUT1       0
[   58.325000] GPB02: TOUT2       0
[   58.325000] GPB03: OUTPUT      0
[   58.325000] GPB04: OUTPUT      0
[   58.325000] GPB05: OUTPUT      0
[   58.325000] GPB06: OUTPUT      0
[   58.325000] GPB07: OUTPUT      0
[   58.325000] GPB08: OUTPUT      0
[   58.325000] GPB09: OUTPUT      0
[   58.325000] GPB10: OUTPUT      0
[   58.325000]
[   58.325000] GPC00: OUTPUT      0
[   58.325000] GPC01: OUTPUT      0
[   58.325000] GPC02: OUTPUT      0
[   58.325000] GPC03: OUTPUT      0
[   58.325000] GPC04: OUTPUT      0
[   58.325000] GPC05: input       1
[   58.325000] GPC06: OUTPUT      1
[   58.325000] GPC07: OUTPUT      0
[   58.325000] GPC08: OUTPUT      0
[   58.325000] GPC09: OUTPUT      0
[   58.325000] GPC10: OUTPUT      0
[   58.325000] GPC11: OUTPUT      0
[   58.325000] GPC12: OUTPUT      0
[   58.325000] GPC13: OUTPUT      0
[   58.325000] GPC14: OUTPUT      0
[   58.325000] GPC15: OUTPUT      0
[   58.325000]
[   58.325000] GPD00: OUTPUT      0
[   58.325000] GPD01: OUTPUT      0
[   58.325000] GPD02: OUTPUT      0
[   58.325000] GPD03: OUTPUT      0
[   58.325000] GPD04: OUTPUT      0
[   58.325000] GPD05: OUTPUT      0
[   58.325000] GPD06: OUTPUT      0
[   58.325000] GPD07: OUTPUT      0
[   58.325000] GPD08: OUTPUT      0
[   58.325000] GPD09: OUTPUT      0
[   58.325000] GPD10: OUTPUT      0
[   58.325000] GPD11: OUTPUT      0
[   58.325000] GPD12: OUTPUT      1
[   58.325000] GPD13: OUTPUT      1
[   58.325000] GPD14: OUTPUT      0
[   58.325000] GPD15: OUTPUT      0
[   58.325000]
[   58.325000] GPE00: I2SLRCK     1
[   58.325000] GPE01: I2SSCLK     0
[   58.325000] GPE02: CDCLK       1
[   58.325000] GPE03: I2SDI       1
[   58.325000] GPE04: I2SDO       0
[   58.325000] GPE05: SDCLK       0
[   58.325000] GPE06: SDCMD       1
[   58.325000] GPE07: SDDAT0      1
[   58.325000] GPE08: SDDAT1      1
[   58.325000] GPE09: SDDAT2      1
[   58.325000] GPE10: SDDAT3      1
[   58.325000] GPE11: SPIMISO0    1
[   58.325000] GPE12: SPIMOSI0    1
[   58.325000] GPE13: SPICLK0     1
[   58.325000] GPE14: IICSCL      1
[   58.325000] GPE15: IICSDA      1
[   58.325000]
[   58.325000] GPF00: EINT[0]     1
[   58.325000] GPF01: EINT[1]     0
[   58.325000] GPF02: EINT[2]     1
[   58.325000] GPF03: EINT[3]     1
[   58.325000] GPF04: EINT[4]     0
[   58.325000] GPF05: EINT[5]     0
[   58.325000] GPF06: EINT[6]     0
[   58.325000] GPF07: EINT[7]     0
[   58.325000]
[   58.325000] GPG00: OUTPUT      0
[   58.325000] GPG01: EINT[9]     1
[   58.325000] GPG02: nSS0        1
[   58.325000] GPG03: OUTPUT      0
[   58.325000] GPG04: EINT[12]    1
[   58.325000] GPG05: input       1
[   58.325000] GPG06: OUTPUT      1
[   58.325000] GPG07: OUTPUT      1
[   58.325000] GPG08: EINT[16]    1
[   58.325000] GPG09: EINT[17]    1
[   58.325000] GPG10: EINT[18]    1
[   58.325000] GPG11: EINT[19]    0
[   58.325000] GPG12: OUTPUT      0
[   58.325000] GPG13: input       1
[   58.325000] GPG14: input       1
[   58.325000] GPG15: input       0
[   58.325000]
[   58.325000] GPH00: nCTS0       0
[   58.325000] GPH01: nRTS0       1
[   58.325000] GPH02: TXD[0]      1
[   58.325000] GPH03: RXD[0]      1
[   58.325000] GPH04: TXD[1]      1
[   58.325000] GPH05: RXD[1]      1
[   58.325000] GPH06: TXD[2]      1
[   58.325000] GPH07: RXD[2]      1
[   58.325000] GPH08: UEXTCLK     1
[   58.325000] GPH09: CLKOUT0     0
[   58.325000] GPH10: OUTPUT      0
[   58.325000]
[   58.325000] GPJ00: input       1
[   58.325000] GPJ01: OUTPUT      0
[   58.325000] GPJ02: input       1
[   58.325000] GPJ03: OUTPUT      0
[   58.325000] GPJ04: OUTPUT      1
[   58.325000] GPJ05: OUTPUT      1
[   58.325000] GPJ06: OUTPUT      1
[   58.325000] GPJ07: input       1
[   58.325000] GPJ08: OUTPUT      1
[   58.325000] GPJ09: OUTPUT      0
[   58.325000] GPJ10: OUTPUT      0
[   58.325000] GPJ11: OUTPUT      0
[   58.325000] GPJ12: OUTPUT      1

- -Andy
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.7 (GNU/Linux)
Comment: Using GnuPG with Fedora - http://enigmail.mozdev.org

iD8DBQFHv+czOjLpvpq7dMoRAuHsAJ4nQ6IlPTu7J/Rimb3Yw7n6Lyk9CgCeJAN/
Wj4YqW1vFavM4KNSXzZg1uA=
=LYPL
-----END PGP SIGNATURE-----




More information about the openmoko-kernel mailing list