platform/chrome: Add support for host sleep event command v1
Status from this message: Applied, thanks.
Get series with b4
b4 am [email protected]Versions newest first · linked by author and title
- v3 Latest2 patches 10 repliesApplied
- v22 patches 1 replySuperseded
- v12 patches 5 repliesSuperseded
Changes in v3 from the cover letter
- Consolidated boolean logic for host_sleep_v1 (Guenter)
Patches in v3 Applied
| # | Subject and files | Size | Replies | Applied |
|---|---|---|---|---|
| 1/2 | mfd: cros_ec: Add host_sleep_event_v1 commandinclude/ | +57 | 5 replies | |
| 2/2 | platform/chrome: Add support for v1 of host sleep eventdrivers/ drivers/ include/ | +42 | 5 replies |
Reviews trailers per patch
All 2 patches have a Reviewed-by or Acked-by.
| Patch | Lee Jones | Guenter Roeck | Rajat Jain | Enric Balletbo i Serra |
|---|---|---|---|---|
| 1/2 | R-b | R-b | A-b | |
| 2/2 | Acked-for-MFD-by | R-b | R-b | A-b |
Trailers given in replies are filled; those carried in the patches from earlier versions are outlined with dashes. Scroll the table sideways for all 4 reviewers.
Cover letter [PATCH v3 0/2] platform/chrome: Add support for host sleep event command v1
The Chrome OS EC has an updated set of parameters for the host sleep event command. With the new parameters, the host can indicate a timeout along with suspend messages. Specifically S0ix suspend messages are supported now, though the host command format isn't specific to S0ix. When the EC sees an S0ix suspend host sleep event, it arms a timer for the specified number of milliseconds (or a sane per-board default baked into the EC). If the EC does not observe the platform's SLP_S0 line assert within the specified timeout, then the EC wakes the system.
On resume, the EC reports the number of transitions seen on the SLP_S0 line. The high bit is used to report whether or not a timeout occurred. The number of transitions can then be used to detect cases of excessive housekeeping activities, where the system wakes up out of S0ix temporarily (unbeknownst to Linux), and then (hopefully) goes back to sleep.
This mechanism helps in cases where the system attempted to suspend via S0ix, but due to driver bugs ended up suspending to a shallower idle state instead. In concert with additional changes that detect S0ix entry failures, this mechanism allows the system to quickly detect and report on incorrect suspend outcomes.
Enric,
Gwendal informed me that his patch was rejected, so I'm sending this as a standalone series rather than basing on top of his. The corresponding EC code for this has now landed at:
https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/1501512
Changes in v3:
- Consolidated boolean logic for host_sleep_v1 (Guenter)
Changes in v2:
- Made unions anonymous
- Replaced reserved union members with a comment
- Removed unnecessary version assignment (Guenter)
- Changed WARN to WARN_ONCE (Guenter)
- Fixed C code to use anonymous unions
- insize is only bigger for resume events.
Evan Green (2):
mfd: cros_ec: Add host_sleep_event_v1 command platform/chrome: Add support for v1 of host sleep event
drivers/mfd/cros_ec.c | 39 ++++++++++++++--- drivers/platform/chrome/cros_ec_proto.c | 6 +++ include/linux/mfd/cros_ec.h | 2 + include/linux/mfd/cros_ec_commands.h | 57 +++++++++++++++++++++++++ 4 files changed, 99 insertions(+), 5 deletions(-)
Signature · 1 line
2.20.1