
From: Jialin Zhang <zhangjialin11@huawei.com> hulk inclusion category: feature bugzilla: https://gitee.com/openeuler/kernel/issues/I4JBL0 CVE: NA ------------------------------- Reserve space for power management related structure. Signed-off-by: Jialin Zhang <zhangjialin11@huawei.com> Reviewed-by: Wei Li <liwei391@huawei.com> Signed-off-by: Zheng Zengkai <zhengzengkai@huawei.com> --- include/linux/pm.h | 14 ++++++++++++++ include/linux/pm_domain.h | 9 +++++++++ include/linux/pm_qos.h | 7 +++++++ include/linux/pm_wakeup.h | 4 ++++ 4 files changed, 34 insertions(+) diff --git a/include/linux/pm.h b/include/linux/pm.h index 52d9724db9dc..265175a5dc60 100644 --- a/include/linux/pm.h +++ b/include/linux/pm.h @@ -15,6 +15,7 @@ #include <linux/timer.h> #include <linux/hrtimer.h> #include <linux/completion.h> +#include <linux/kabi.h> /* * Callbacks for platform drivers to implement. @@ -542,6 +543,13 @@ struct pm_subsys_data { #ifdef CONFIG_PM_GENERIC_DOMAINS struct pm_domain_data *domain_data; #endif + + KABI_RESERVE(1) + KABI_RESERVE(2) + KABI_RESERVE(3) + KABI_RESERVE(4) + KABI_RESERVE(5) + KABI_RESERVE(6) }; /* @@ -621,6 +629,9 @@ struct dev_pm_info { struct pm_subsys_data *subsys_data; /* Owned by the subsystem. */ void (*set_latency_tolerance)(struct device *, s32); struct dev_pm_qos *qos; + + KABI_RESERVE(1) + KABI_RESERVE(2) }; extern int dev_pm_get_subsys_data(struct device *dev); @@ -647,6 +658,9 @@ struct dev_pm_domain { int (*activate)(struct device *dev); void (*sync)(struct device *dev); void (*dismiss)(struct device *dev); + + KABI_RESERVE(1) + KABI_RESERVE(2) }; /* diff --git a/include/linux/pm_domain.h b/include/linux/pm_domain.h index 1ad0ec481416..88675b787146 100644 --- a/include/linux/pm_domain.h +++ b/include/linux/pm_domain.h @@ -16,6 +16,7 @@ #include <linux/notifier.h> #include <linux/spinlock.h> #include <linux/cpumask.h> +#include <linux/kabi.h> /* * Flags to control the behaviour of a genpd. @@ -94,6 +95,9 @@ struct genpd_power_state { struct fwnode_handle *fwnode; ktime_t idle_time; void *data; + + KABI_RESERVE(1) + KABI_RESERVE(2) }; struct genpd_lock_ops; @@ -153,6 +157,11 @@ struct generic_pm_domain { }; }; + KABI_RESERVE(1) + KABI_RESERVE(2) + KABI_RESERVE(3) + KABI_RESERVE(4) + }; static inline struct generic_pm_domain *pd_to_genpd(struct dev_pm_domain *pd) diff --git a/include/linux/pm_qos.h b/include/linux/pm_qos.h index 4a69d4af3ff8..4745e27680df 100644 --- a/include/linux/pm_qos.h +++ b/include/linux/pm_qos.h @@ -15,6 +15,7 @@ #include <linux/plist.h> #include <linux/notifier.h> #include <linux/device.h> +#include <linux/kabi.h> enum pm_qos_flags_status { PM_QOS_FLAGS_UNDEFINED = -1, @@ -112,6 +113,9 @@ struct dev_pm_qos_request { struct freq_qos_request freq; } data; struct device *dev; + + KABI_RESERVE(1) + KABI_RESERVE(2) }; struct dev_pm_qos { @@ -122,6 +126,9 @@ struct dev_pm_qos { struct dev_pm_qos_request *resume_latency_req; struct dev_pm_qos_request *latency_tolerance_req; struct dev_pm_qos_request *flags_req; + + KABI_RESERVE(1) + KABI_RESERVE(2) }; /* Action requested to pm_qos_update_target */ diff --git a/include/linux/pm_wakeup.h b/include/linux/pm_wakeup.h index aa3da6611533..4f68cf989105 100644 --- a/include/linux/pm_wakeup.h +++ b/include/linux/pm_wakeup.h @@ -14,6 +14,7 @@ #endif #include <linux/types.h> +#include <linux/kabi.h> struct wake_irq; @@ -61,6 +62,9 @@ struct wakeup_source { struct device *dev; bool active:1; bool autosleep_enabled:1; + + KABI_RESERVE(1) + KABI_RESERVE(2) }; #define for_each_wakeup_source(ws) \ -- 2.20.1