aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/include/linux/pm_domain.h
diff options
context:
space:
mode:
authorUlf Hansson <ulf.hansson@linaro.org>2022-05-11 16:56:56 +0200
committerRafael J. Wysocki <rafael.j.wysocki@intel.com>2022-05-19 20:16:05 +0200
commit66d29d802ef3bf55a49b07568b0048823d4a72a6 (patch)
treedbb98432a075ea0a5324858899af407915c884ca /include/linux/pm_domain.h
parentPM: domains: Skip another warning in irq_safe_dev_in_sleep_domain() (diff)
downloadwireguard-linux-66d29d802ef3bf55a49b07568b0048823d4a72a6.tar.xz
wireguard-linux-66d29d802ef3bf55a49b07568b0048823d4a72a6.zip
PM: domains: Allocate gpd_timing_data dynamically based on governor
If a genpd doesn't have an associated governor assigned, there's really no point to allocate the per device gpd_timing_data, as the data isn't being used by a governor anyway. To avoid wasting memory, let's therefore convert the corresponding td variable in the struct generic_pm_domain_data into a pointer and manage the allocation of its data dynamically. Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
Diffstat (limited to 'include/linux/pm_domain.h')
-rw-r--r--include/linux/pm_domain.h2
1 files changed, 1 insertions, 1 deletions
diff --git a/include/linux/pm_domain.h b/include/linux/pm_domain.h
index 043d48e4420a..126a4b9ab215 100644
--- a/include/linux/pm_domain.h
+++ b/include/linux/pm_domain.h
@@ -193,7 +193,7 @@ struct pm_domain_data {
struct generic_pm_domain_data {
struct pm_domain_data base;
- struct gpd_timing_data td;
+ struct gpd_timing_data *td;
struct notifier_block nb;
struct notifier_block *power_nb;
int cpu;