History

intel_rapl: introduce struct rapl_if_private

Introduce a new structure, rapl_if_private, to save the private data for different RAPL Interface.

Zhang Rui committed 7 years ago

Commit 7ebf8ef1 parent ff956822 files · +44 −30Browse files

Showing the changes to include/linux (1 of 2 files). Show all

Unified · Split

include/linux/intel_rapl.h+15−0
@@ -88,6 +88,20 @@ struct rapl_domain { · 87 unmodified lines
8888 struct rapl_package *rp;
8989 };
9090
91+/**
92+ * struct rapl_if_priv: private data for different RAPL interfaces
93+ * @control_type: Each RAPL interface must have its own powercap
94+ * control type.
95+ * @platform_rapl_domain: Optional. Some RAPL interface may have platform
96+ * level RAPL control.
97+ * @pcap_rapl_online: CPU hotplug state for each RAPL interface.
98+ */
99+struct rapl_if_priv {
100+ struct powercap_control_type *control_type;
101+ struct rapl_domain *platform_rapl_domain;
102+ enum cpuhp_state pcap_rapl_online;
103+};
104+
91105 /* maximum rapl package domain name: package-%d-die-%d */
92106 #define PACKAGE_DOMAIN_NAME_LENGTH 30
93107
@@ -108,6 +122,7 @@ struct rapl_package { · 14 unmodified lines
108122 /* Track active cpus */
109123 struct cpumask cpumask;
110124 char name[PACKAGE_DOMAIN_NAME_LENGTH];
125+ struct rapl_if_priv *priv;
111126 };
112127
113128 #endif /* __INTEL_RAPL_H__ */

Keyboard shortcuts

General

Show keyboard shortcuts
?
Focus the current search
/

Issues and pull requests

Open filters
f

Issues, pull requests and Inbox

Select next item
j↓
Select previous item
k↑
Open selected item
Enter
Dismiss filters or clear selection
Esc

Repository code

Go to file
t