Duncan Laurie 52e5ab0730 eve: Use PCH ACOK signal to control Deep Sleep entry
Deep Sleep states (DS3, DS5) are a special mode of the Intel PCH chipset
that has very limited wake capabilities and breaks a number of common
user expected behahviors.

In particular, when in Deep S3 the USB ports are turned off and cannot
continue to charge, wake the system, or maintain their internal state
as they will lose 5V power.  This is particularly painful with gnubby
devices as they will need unlocked after every DS3 suspend/resume cycle.

The only external signal that the PCH uses to determine whether or not
to enter Deep Sx states is the ACPRESENT (aka ACOK) pin.

Currently this pin is simply buffered from the charger and will be
asserted whenever a charger is connected.  This change extends the EC
control over the pin to also assert ACPRESENT if either Type-C port is
currently supplying VBUS.

Now when a USB device is inserted the system will be enter S3 state,
but not go into Deep S3 state.  This allows the USB device to continue
to charge, maintain it's internal state, and wake the system.

BUG=b:64406191
BRANCH=eve
TEST=verify GPIO_PCH_ACOK pin from the EC in different scenarios and
test that system goes into S3 or DS3 state as expected:
1) no charger, no USB device: ACOK not asserted, DS3 enabled
2) charger but no USB device: ACOK asserted, DS3 disabled
3) no charger but USB device: ACOK asserted, DS3 disabled
4) charger and USB device:    ACOK asserted, DS3 disabled

Change-Id: I1cd132459194382e418970d29b1b195d8132cfad
Signed-off-by: Duncan Laurie <dlaurie@google.com>
Reviewed-on: https://chromium-review.googlesource.com/896164
Reviewed-by: Furquan Shaikh <furquan@chromium.org>
2018-02-12 18:59:32 -08:00
2017-08-07 19:29:13 -07:00
2018-02-12 18:59:29 -08:00
2017-07-08 20:38:53 -07:00
2017-10-10 22:13:43 -07:00
2018-01-12 03:27:10 -08:00
2017-11-17 20:18:38 -08:00
2018-02-07 21:27:39 -08:00
2012-05-11 09:11:52 -07:00
2018-01-26 13:25:49 -08:00
2014-04-02 19:58:53 +00:00
2017-11-16 21:07:40 -08:00

For an overview of the Embedded Controller firmware, refer to

http://www.chromium.org/chromium-os/2014-firmware-summit

For instructions on building from source, refer to

http://www.chromium.org/chromium-os/ec-development/getting-started-building-ec-images-quickly
Description
No description provided
Readme 1.4 GiB
Languages
C 64.7%
Lasso 20.7%
ASL 3.6%
JavaScript 3.2%
C# 2.9%
Other 4.6%