diff options
Diffstat (limited to 'include/linux/pm_domain.h')
-rw-r--r-- | include/linux/pm_domain.h | 10 |
1 files changed, 7 insertions, 3 deletions
diff --git a/include/linux/pm_domain.h b/include/linux/pm_domain.h index 14fb0953fa47..c71457cb8a79 100644 --- a/include/linux/pm_domain.h +++ b/include/linux/pm_domain.h | |||
@@ -11,8 +11,11 @@ | |||
11 | 11 | ||
12 | #include <linux/device.h> | 12 | #include <linux/device.h> |
13 | 13 | ||
14 | #define GPD_IN_SUSPEND 1 | 14 | enum gpd_status { |
15 | #define GPD_POWER_OFF 2 | 15 | GPD_STATE_ACTIVE = 0, /* PM domain is active */ |
16 | GPD_STATE_BUSY, /* Something is happening to the PM domain */ | ||
17 | GPD_STATE_POWER_OFF, /* PM domain is off */ | ||
18 | }; | ||
16 | 19 | ||
17 | struct dev_power_governor { | 20 | struct dev_power_governor { |
18 | bool (*power_down_ok)(struct dev_pm_domain *domain); | 21 | bool (*power_down_ok)(struct dev_pm_domain *domain); |
@@ -29,7 +32,8 @@ struct generic_pm_domain { | |||
29 | struct work_struct power_off_work; | 32 | struct work_struct power_off_work; |
30 | unsigned int in_progress; /* Number of devices being suspended now */ | 33 | unsigned int in_progress; /* Number of devices being suspended now */ |
31 | unsigned int sd_count; /* Number of subdomains with power "on" */ | 34 | unsigned int sd_count; /* Number of subdomains with power "on" */ |
32 | bool power_is_off; /* Whether or not power has been removed */ | 35 | enum gpd_status status; /* Current state of the domain */ |
36 | wait_queue_head_t status_wait_queue; | ||
33 | unsigned int device_count; /* Number of devices */ | 37 | unsigned int device_count; /* Number of devices */ |
34 | unsigned int suspended_count; /* System suspend device counter */ | 38 | unsigned int suspended_count; /* System suspend device counter */ |
35 | unsigned int prepared_count; /* Suspend counter of prepared devices */ | 39 | unsigned int prepared_count; /* Suspend counter of prepared devices */ |