PM / sleep: Add state field to pm_states[] entries
authorRafael J. Wysocki <rafael.j.wysocki@intel.com>
Mon, 26 May 2014 11:40:47 +0000 (13:40 +0200)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Sun, 5 Oct 2014 21:52:24 +0000 (14:52 -0700)
commit31a52a9e9d71afc65afb9c54479052b1663a5532
tree59a1cbc5da30727f8b7c6b13bd06a9a4c23c84da
parent9321e2ecf40ab73eb3f74183d8f7a521d8b7eb52
PM / sleep: Add state field to pm_states[] entries

commit 27ddcc6596e50cb8f03d2e83248897667811d8f6 upstream.

To allow sleep states corresponding to the "mem", "standby" and
"freeze" lables to be different from the pm_states[] indexes of
those strings, introduce struct pm_sleep_state, consisting of
a string label and a state number, and turn pm_states[] into an
array of objects of that type.

This modification should not lead to any functional changes.

Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
Cc: Brian Norris <computersforpeace@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
kernel/power/main.c
kernel/power/power.h
kernel/power/suspend.c
kernel/power/suspend_test.c