CHROMIUM: dark resume: Add dark resume functionality
In drivers/base/power/main.c, create the concept of dark resume. This includes
checking for a dark resume before we resume devices and allowing devices to
query this state. It also adds creating wake sources that indicate if a dark
resume happened. If a device is in this list of devices, we ask it if it woke
the system up. If so, we count the system resume as a dark resume.
BUG=chrome-os-partner:9812
TEST=suspend system, watch dark resumes happen
Change-Id: I0c416c156759728284901f03e98f0c87933c9c9a
Signed-off-by: Derek Basehore <dbasehore@chromium.org>
Reviewed-on: https://gerrit.chromium.org/gerrit/42921
Reviewed-by: Olof Johansson <olofj@chromium.org>
Reviewed-by: Sameer Nanda <snanda@chromium.org>