Borrow the idea to abstract over ACPI Sx sleep types with enum sleep_type from Ben's s2idle patch, D17675, but use this everywhere it makes sense to.
Also factor out do_standby, do_sleep, and do_idle (new) routines.
I decided against going with the name "s2idle" as I'm afraid users might confuse this with the S2 standby state, when in reality the system stays in S0 but idles the CPU. So I think S0i is a better name.
I will end up breaking this patch up into:
- A patch which serves only to replace all the uses of ACPI S-states with enum sleep_type.
- A patch which actually implements suspend-to-idle on top of that.
- A patch which calls the SPMC hooks before/after idling, with D48387 and the suspend-to-idle patch as parents.