-
Notifications
You must be signed in to change notification settings - Fork 8
/
README.txt
130 lines (104 loc) · 5.98 KB
/
README.txt
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
* intel_rapl_power.c - Sysfs entries for Running Average Power Limit interfaces
* Copyright (c) 2011 Razvan A. Lupusoru <[email protected]>
* For documentation on Platform Specific Power Management Support using RAPL
* please consult the Intel 64 and IA-32 Architectures Software Developer's
* Manual Volume 3 Section 14.7 (as of April 2011)
INFORMATION ABOUT RAPL
• MSR_PKG_POWER_LIMIT allows a software agent to define power limitation for the
package domain. Power limitation is defined in terms of average power usage
(Watts) over a time window specified in MSR_PKG_POWER_LIMIT. Two power limits
can be specified, corresponding to time windows of different sizes. Each power limit
provides independent clamping control that would permit the processor cores to go
below OS-requested state to meet the power limits. A lock mechanism allow the soft-
ware agent to enforce power limit settings. Once the lock bit is set, the power limit
settings are static and un-modifiable until next RESET.
• MSR_PKG_ENERGY_STATUS is a read-only MSR. It reports the actual energy use for
the package domain. This MSR is updated every ~1msec. It has a wraparound time
of around 60 secs when power consumption is high, and may be longer otherwise.
• MSR_PKG_POWER_INFO is a read-only MSR. It reports the package power range
information for RAPL usage. This MSR provides maximum/minimum values (derived
from electrical specification), thermal specification power of the package domain. It
also provides the largest possible time window for software to program the RAPL
interface.
• Power Units : Power related information (in Watts) is based on the multiplier, 1/ 2^PU;
where PU is an unsigned integer with default value of 0011b, indicating power unit is
in 1/8 Watts increment.
• Energy Status Units : Energy related information (in Joules) is based on the multiplier,
1/ 2^ESU; where ESU is an unsigned integer with default value of 10000b, indicating
energy status unit is in 15.3 micro-Joules increment.
• Time Units : Time related information (in Seconds) is based on the multiplier, 1/ 2^TU;
where TU is an unsigned integer with default value of 1010b, indicating time unit is in
976 micro-seconds increment.
SYSFS ENTRIES
The following sysfs entries are created in /sys/kernel/cpu_power_info
- total_energy_millijoules
Associated with MSR_PKG_ENERGY_STATUS MSR. Value is read-only.
Returns the actual energy use for the package domain in millijoules. The value is
updated ~1msec. It has a wraparound time of around 60 secs when power consumption
is high, and may be longer otherwise.
- current_power_milliwatts
Associated with MSR_PKG_ENERGY_STATUS MSR. Value is read-only.
Returns the current power usage in milliwatts. The value is updated ~1sec.
- thermal_spec_power_watts
Associated with MSR_PKG_POWER_INFO MSR. Value is read-only.
Returns the thermal specification power of the package domain in watts.
- minimum_power_watts
Associated with MSR_PKG_POWER_INFO MSR. Value is read-only.
Returns the minimum power derived from the electrical spec of the package
domain in watts.
- maximum_power_watts
Associated with MSR_PKG_POWER_INFO MSR. Value is read-only.
Returns the maximum power derived from the electrical spec of the package
domain in watts.
- maximum_time_window_milliseconds
Associated with MSR_PKG_POWER_INFO MSR. Value is read-only.
Returns the largest acceptable value (in milliseconds) to program the time
window of the MSR_PKG_POWER_LIMIT MSR.
- power_limit_lock
Associated with MSR_PKG_POWER_LIMIT MSR. Value is read/write.
If enabled, all write attempts to the MSR are ignored until
the next reset. 0 = disabled ; 1 = enabled
- power_limit_1
Associated with MSR_PKG_POWER_LIMIT MSR. Value is read/write.
Sets the average power usage limit of the package domain
corresponding to time window #1. The unit of this field is
specified by the “Power Units” from section above.
- power_limit_2
Associated with MSR_PKG_POWER_LIMIT MSR. Value is read/write.
Sets the average power usage limit of the package domain
corresponding to time window #2. The unit of this field is
specified by the “Power Units” from section above.
- enable_limit_1
Associated with MSR_PKG_POWER_LIMIT MSR. Value is read/write.
Can enable/disable power limit #1. 0 = disabled ; 1 = enabled
- enable_limit_2
Associated with MSR_PKG_POWER_LIMIT MSR. Value is read/write.
Can enable/disable power limit #2. 0 = disabled ; 1 = enabled
- clamping_limit_1
Associated with MSR_PKG_POWER_LIMIT MSR. Value is read/write.
Sets the time window which allows going below OS-requested P/T
state setting. The unit of this field is specified by the "Time
Units” from section above.
- clamping_limit_2
Associated with MSR_PKG_POWER_LIMIT MSR. Value is read/write.
Sets the time window which allows going below OS-requested P/T
state setting. The unit of this field is specified by the "Time
Units” from section above.
- time_window_power_limit_1
Associated with MSR_PKG_POWER_LIMIT MSR. Value is read/write.
Indicates the length of time window over which the power limit
#1. The numeric value is 7 bits long and is represented by the
product of 2^Y *F; where F is a single-digit decimal floating-
point value between 1.0 and 1.3 with the fraction digit
represented by the two higher order bits, Y is an unsigned
integer represented by the five lower order bits. The unit of
this field is specified by the “Time Units” from section above.
- time_window_power_limit_2
Associated with MSR_PKG_POWER_LIMIT MSR. Value is read/write.
Indicates the length of time window over which the power limit
#2. The numeric value is 7 bits long and is represented by the
product of 2^Y *F; where F is a single-digit decimal floating-
point value between 1.0 and 1.3 with the fraction digit
represented by the two higher order bits, Y is an unsigned
integer represented by the five lower order bits. The unit of
this field is specified by the “Time Units” from section above.