hc
2024-10-22 8ac6c7a54ed1b98d142dce24b11c6de6a1e239a5
kernel/Documentation/ABI/testing/sysfs-devices-system-cpu
....@@ -34,7 +34,7 @@
3434 present: cpus that have been identified as being present in
3535 the system.
3636
37
- See Documentation/cputopology.txt for more information.
37
+ See Documentation/admin-guide/cputopology.rst for more information.
3838
3939
4040 What: /sys/devices/system/cpu/probe
....@@ -103,13 +103,13 @@
103103 thread_siblings_list: human-readable list of cpu#'s hardware
104104 threads within the same core as cpu#
105105
106
- See Documentation/cputopology.txt for more information.
106
+ See Documentation/admin-guide/cputopology.rst for more information.
107107
108108
109
-What: /sys/devices/system/cpu/cpuidle/current_driver
110
- /sys/devices/system/cpu/cpuidle/current_governer_ro
111
- /sys/devices/system/cpu/cpuidle/available_governors
109
+What: /sys/devices/system/cpu/cpuidle/available_governors
110
+ /sys/devices/system/cpu/cpuidle/current_driver
112111 /sys/devices/system/cpu/cpuidle/current_governor
112
+ /sys/devices/system/cpu/cpuidle/current_governer_ro
113113 Date: September 2007
114114 Contact: Linux kernel mailing list <linux-kernel@vger.kernel.org>
115115 Description: Discover cpuidle policy and mechanism
....@@ -119,25 +119,20 @@
119119 consumption during idle.
120120
121121 Idle policy (governor) is differentiated from idle mechanism
122
- (driver)
123
-
124
- current_driver: (RO) displays current idle mechanism
125
-
126
- current_governor_ro: (RO) displays current idle policy
127
-
128
- With the cpuidle_sysfs_switch boot option enabled (meant for
129
- developer testing), the following three attributes are visible
130
- instead:
131
-
132
- current_driver: same as described above
122
+ (driver).
133123
134124 available_governors: (RO) displays a space separated list of
135
- available governors
125
+ available governors.
126
+
127
+ current_driver: (RO) displays current idle mechanism.
136128
137129 current_governor: (RW) displays current idle policy. Users can
138130 switch the governor at runtime by writing to this file.
139131
140
- See files in Documentation/cpuidle/ for more information.
132
+ current_governor_ro: (RO) displays current idle policy.
133
+
134
+ See Documentation/admin-guide/pm/cpuidle.rst and
135
+ Documentation/driver-api/pm/cpuidle.rst for more information.
141136
142137
143138 What: /sys/devices/system/cpu/cpuX/cpuidle/stateN/name
....@@ -145,6 +140,8 @@
145140 /sys/devices/system/cpu/cpuX/cpuidle/stateN/power
146141 /sys/devices/system/cpu/cpuX/cpuidle/stateN/time
147142 /sys/devices/system/cpu/cpuX/cpuidle/stateN/usage
143
+ /sys/devices/system/cpu/cpuX/cpuidle/stateN/above
144
+ /sys/devices/system/cpu/cpuX/cpuidle/stateN/below
148145 Date: September 2007
149146 KernelVersion: v2.6.24
150147 Contact: Linux power management list <linux-pm@vger.kernel.org>
....@@ -154,18 +151,28 @@
154151 The processor idle states which are available for use have the
155152 following attributes:
156153
157
- name: (RO) Name of the idle state (string).
154
+ ======== ==== =================================================
155
+ name: (RO) Name of the idle state (string).
158156
159157 latency: (RO) The latency to exit out of this idle state (in
160
- microseconds).
158
+ microseconds).
161159
162
- power: (RO) The power consumed while in this idle state (in
163
- milliwatts).
160
+ power: (RO) The power consumed while in this idle state (in
161
+ milliwatts).
164162
165
- time: (RO) The total time spent in this idle state (in microseconds).
163
+ time: (RO) The total time spent in this idle state
164
+ (in microseconds).
166165
167
- usage: (RO) Number of times this state was entered (a count).
166
+ usage: (RO) Number of times this state was entered (a count).
168167
168
+ above: (RO) Number of times this state was entered, but the
169
+ observed CPU idle duration was too short for it
170
+ (a count).
171
+
172
+ below: (RO) Number of times this state was entered, but the
173
+ observed CPU idle duration was too long for it
174
+ (a count).
175
+ ======== ==== =================================================
169176
170177 What: /sys/devices/system/cpu/cpuX/cpuidle/stateN/desc
171178 Date: February 2008
....@@ -188,6 +195,12 @@
188195 does not reflect it. Likewise, if one enables a deep state but a
189196 lighter state still is disabled, then this has no effect.
190197
198
+What: /sys/devices/system/cpu/cpuX/cpuidle/stateN/default_status
199
+Date: December 2019
200
+KernelVersion: v5.6
201
+Contact: Linux power management list <linux-pm@vger.kernel.org>
202
+Description:
203
+ (RO) The default status of this state, "enabled" or "disabled".
191204
192205 What: /sys/devices/system/cpu/cpuX/cpuidle/stateN/residency
193206 Date: March 2014
....@@ -282,6 +295,7 @@
282295 This switch controls the boost setting for the whole system.
283296 Boosting allows the CPU and the firmware to run at a frequency
284297 beyound it's nominal limit.
298
+
285299 More details can be found in
286300 Documentation/admin-guide/pm/cpufreq.rst
287301
....@@ -329,43 +343,57 @@
329343 Description: Parameters for the CPU cache attributes
330344
331345 allocation_policy:
332
- - WriteAllocate: allocate a memory location to a cache line
333
- on a cache miss because of a write
334
- - ReadAllocate: allocate a memory location to a cache line
346
+ - WriteAllocate:
347
+ allocate a memory location to a cache line
348
+ on a cache miss because of a write
349
+ - ReadAllocate:
350
+ allocate a memory location to a cache line
335351 on a cache miss because of a read
336
- - ReadWriteAllocate: both writeallocate and readallocate
352
+ - ReadWriteAllocate:
353
+ both writeallocate and readallocate
337354
338
- attributes: LEGACY used only on IA64 and is same as write_policy
355
+ attributes:
356
+ LEGACY used only on IA64 and is same as write_policy
339357
340
- coherency_line_size: the minimum amount of data in bytes that gets
358
+ coherency_line_size:
359
+ the minimum amount of data in bytes that gets
341360 transferred from memory to cache
342361
343
- level: the cache hierarchy in the multi-level cache configuration
362
+ level:
363
+ the cache hierarchy in the multi-level cache configuration
344364
345
- number_of_sets: total number of sets in the cache, a set is a
365
+ number_of_sets:
366
+ total number of sets in the cache, a set is a
346367 collection of cache lines with the same cache index
347368
348
- physical_line_partition: number of physical cache line per cache tag
369
+ physical_line_partition:
370
+ number of physical cache line per cache tag
349371
350
- shared_cpu_list: the list of logical cpus sharing the cache
372
+ shared_cpu_list:
373
+ the list of logical cpus sharing the cache
351374
352
- shared_cpu_map: logical cpu mask containing the list of cpus sharing
375
+ shared_cpu_map:
376
+ logical cpu mask containing the list of cpus sharing
353377 the cache
354378
355
- size: the total cache size in kB
379
+ size:
380
+ the total cache size in kB
356381
357382 type:
358383 - Instruction: cache that only holds instructions
359384 - Data: cache that only caches data
360385 - Unified: cache that holds both data and instructions
361386
362
- ways_of_associativity: degree of freedom in placing a particular block
363
- of memory in the cache
387
+ ways_of_associativity:
388
+ degree of freedom in placing a particular block
389
+ of memory in the cache
364390
365391 write_policy:
366
- - WriteThrough: data is written to both the cache line
392
+ - WriteThrough:
393
+ data is written to both the cache line
367394 and to the block in the lower-level memory
368
- - WriteBack: data is written only to the cache line and
395
+ - WriteBack:
396
+ data is written only to the cache line and
369397 the modified cache line is written to main
370398 memory only when it is replaced
371399
....@@ -406,30 +434,30 @@
406434 throttle attributes exported in the 'throttle_stats' directory:
407435
408436 - turbo_stat : This file gives the total number of times the max
409
- frequency is throttled to lower frequency in turbo (at and above
410
- nominal frequency) range of frequencies.
437
+ frequency is throttled to lower frequency in turbo (at and above
438
+ nominal frequency) range of frequencies.
411439
412440 - sub_turbo_stat : This file gives the total number of times the
413
- max frequency is throttled to lower frequency in sub-turbo(below
414
- nominal frequency) range of frequencies.
441
+ max frequency is throttled to lower frequency in sub-turbo(below
442
+ nominal frequency) range of frequencies.
415443
416444 - unthrottle : This file gives the total number of times the max
417
- frequency is unthrottled after being throttled.
445
+ frequency is unthrottled after being throttled.
418446
419447 - powercap : This file gives the total number of times the max
420
- frequency is throttled due to 'Power Capping'.
448
+ frequency is throttled due to 'Power Capping'.
421449
422450 - overtemp : This file gives the total number of times the max
423
- frequency is throttled due to 'CPU Over Temperature'.
451
+ frequency is throttled due to 'CPU Over Temperature'.
424452
425453 - supply_fault : This file gives the total number of times the
426
- max frequency is throttled due to 'Power Supply Failure'.
454
+ max frequency is throttled due to 'Power Supply Failure'.
427455
428456 - overcurrent : This file gives the total number of times the
429
- max frequency is throttled due to 'Overcurrent'.
457
+ max frequency is throttled due to 'Overcurrent'.
430458
431459 - occ_reset : This file gives the total number of times the max
432
- frequency is throttled due to 'OCC Reset'.
460
+ frequency is throttled due to 'OCC Reset'.
433461
434462 The sysfs attributes representing different throttle reasons like
435463 powercap, overtemp, supply_fault, overcurrent and occ_reset map to
....@@ -461,8 +489,18 @@
461489 Date: June 2016
462490 Contact: Linux ARM Kernel Mailing list <linux-arm-kernel@lists.infradead.org>
463491 Description: AArch64 CPU registers
492
+
464493 'identification' directory exposes the CPU ID registers for
465
- identifying model and revision of the CPU.
494
+ identifying model and revision of the CPU.
495
+
496
+What: /sys/devices/system/cpu/aarch32_el0
497
+Date: November 2020
498
+Contact: Linux ARM Kernel Mailing list <linux-arm-kernel@lists.infradead.org>
499
+Description: Identifies the subset of CPUs in the system that can execute
500
+ AArch32 (32-bit ARM) applications. If present, the same format as
501
+ /sys/devices/system/cpu/{offline,online,possible,present} is used.
502
+ If absent, then all or none of the CPUs can execute AArch32
503
+ applications and execve() will behave accordingly.
466504
467505 What: /sys/devices/system/cpu/cpu#/cpu_capacity
468506 Date: December 2016
....@@ -472,15 +510,18 @@
472510 cpu_capacity: capacity of cpu#.
473511
474512 What: /sys/devices/system/cpu/vulnerabilities
475
- /sys/devices/system/cpu/vulnerabilities/meltdown
476
- /sys/devices/system/cpu/vulnerabilities/spectre_v1
477
- /sys/devices/system/cpu/vulnerabilities/spectre_v2
478
- /sys/devices/system/cpu/vulnerabilities/spec_store_bypass
513
+ /sys/devices/system/cpu/vulnerabilities/gather_data_sampling
514
+ /sys/devices/system/cpu/vulnerabilities/itlb_multihit
479515 /sys/devices/system/cpu/vulnerabilities/l1tf
480516 /sys/devices/system/cpu/vulnerabilities/mds
517
+ /sys/devices/system/cpu/vulnerabilities/meltdown
518
+ /sys/devices/system/cpu/vulnerabilities/mmio_stale_data
519
+ /sys/devices/system/cpu/vulnerabilities/retbleed
520
+ /sys/devices/system/cpu/vulnerabilities/spec_store_bypass
521
+ /sys/devices/system/cpu/vulnerabilities/spectre_v1
522
+ /sys/devices/system/cpu/vulnerabilities/spectre_v2
481523 /sys/devices/system/cpu/vulnerabilities/srbds
482524 /sys/devices/system/cpu/vulnerabilities/tsx_async_abort
483
- /sys/devices/system/cpu/vulnerabilities/itlb_multihit
484525 Date: January 2018
485526 Contact: Linux kernel mailing list <linux-kernel@vger.kernel.org>
486527 Description: Information about CPU vulnerabilities
....@@ -489,9 +530,11 @@
489530 vulnerabilities. The output of those files reflects the
490531 state of the CPUs in the system. Possible output values:
491532
533
+ ================ ==============================================
492534 "Not affected" CPU is not affected by the vulnerability
493535 "Vulnerable" CPU is affected and no mitigation in effect
494536 "Mitigation: $M" CPU is affected and mitigation $M is in effect
537
+ ================ ==============================================
495538
496539 See also: Documentation/admin-guide/hw-vuln/index.rst
497540
....@@ -507,10 +550,122 @@
507550 control: Read/write interface to control SMT. Possible
508551 values:
509552
510
- "on" SMT is enabled
511
- "off" SMT is disabled
512
- "forceoff" SMT is force disabled. Cannot be changed.
513
- "notsupported" SMT is not supported by the CPU
553
+ ================ =========================================
554
+ "on" SMT is enabled
555
+ "off" SMT is disabled
556
+ "forceoff" SMT is force disabled. Cannot be changed.
557
+ "notsupported" SMT is not supported by the CPU
558
+ "notimplemented" SMT runtime toggling is not
559
+ implemented for the architecture
560
+ ================ =========================================
514561
515562 If control status is "forceoff" or "notsupported" writes
516563 are rejected.
564
+
565
+What: /sys/devices/system/cpu/cpu#/power/energy_perf_bias
566
+Date: March 2019
567
+Contact: linux-pm@vger.kernel.org
568
+Description: Intel Energy and Performance Bias Hint (EPB)
569
+
570
+ EPB for the given CPU in a sliding scale 0 - 15, where a value
571
+ of 0 corresponds to a hint preference for highest performance
572
+ and a value of 15 corresponds to the maximum energy savings.
573
+
574
+ In order to change the EPB value for the CPU, write either
575
+ a number in the 0 - 15 sliding scale above, or one of the
576
+ strings: "performance", "balance-performance", "normal",
577
+ "balance-power", "power" (that represent values reflected by
578
+ their meaning), to this attribute.
579
+
580
+ This attribute is present for all online CPUs supporting the
581
+ Intel EPB feature.
582
+
583
+What: /sys/devices/system/cpu/umwait_control
584
+ /sys/devices/system/cpu/umwait_control/enable_c02
585
+ /sys/devices/system/cpu/umwait_control/max_time
586
+Date: May 2019
587
+Contact: Linux kernel mailing list <linux-kernel@vger.kernel.org>
588
+Description: Umwait control
589
+
590
+ enable_c02: Read/write interface to control umwait C0.2 state
591
+ Read returns C0.2 state status:
592
+ 0: C0.2 is disabled
593
+ 1: C0.2 is enabled
594
+
595
+ Write 'y' or '1' or 'on' to enable C0.2 state.
596
+ Write 'n' or '0' or 'off' to disable C0.2 state.
597
+
598
+ The interface is case insensitive.
599
+
600
+ max_time: Read/write interface to control umwait maximum time
601
+ in TSC-quanta that the CPU can reside in either C0.1
602
+ or C0.2 state. The time is an unsigned 32-bit number.
603
+ Note that a value of zero means there is no limit.
604
+ Low order two bits must be zero.
605
+
606
+What: /sys/devices/system/cpu/svm
607
+Date: August 2019
608
+Contact: Linux kernel mailing list <linux-kernel@vger.kernel.org>
609
+ Linux for PowerPC mailing list <linuxppc-dev@ozlabs.org>
610
+Description: Secure Virtual Machine
611
+
612
+ If 1, it means the system is using the Protected Execution
613
+ Facility in POWER9 and newer processors. i.e., it is a Secure
614
+ Virtual Machine.
615
+
616
+What: /sys/devices/system/cpu/cpuX/purr
617
+Date: Apr 2005
618
+Contact: Linux for PowerPC mailing list <linuxppc-dev@ozlabs.org>
619
+Description: PURR ticks for this CPU since the system boot.
620
+
621
+ The Processor Utilization Resources Register (PURR) is
622
+ a 64-bit counter which provides an estimate of the
623
+ resources used by the CPU thread. The contents of this
624
+ register increases monotonically. This sysfs interface
625
+ exposes the number of PURR ticks for cpuX.
626
+
627
+What: /sys/devices/system/cpu/cpuX/spurr
628
+Date: Dec 2006
629
+Contact: Linux for PowerPC mailing list <linuxppc-dev@ozlabs.org>
630
+Description: SPURR ticks for this CPU since the system boot.
631
+
632
+ The Scaled Processor Utilization Resources Register
633
+ (SPURR) is a 64-bit counter that provides a frequency
634
+ invariant estimate of the resources used by the CPU
635
+ thread. The contents of this register increases
636
+ monotonically. This sysfs interface exposes the number
637
+ of SPURR ticks for cpuX.
638
+
639
+What: /sys/devices/system/cpu/cpuX/idle_purr
640
+Date: Apr 2020
641
+Contact: Linux for PowerPC mailing list <linuxppc-dev@ozlabs.org>
642
+Description: PURR ticks for cpuX when it was idle.
643
+
644
+ This sysfs interface exposes the number of PURR ticks
645
+ for cpuX when it was idle.
646
+
647
+What: /sys/devices/system/cpu/cpuX/idle_spurr
648
+Date: Apr 2020
649
+Contact: Linux for PowerPC mailing list <linuxppc-dev@ozlabs.org>
650
+Description: SPURR ticks for cpuX when it was idle.
651
+
652
+ This sysfs interface exposes the number of SPURR ticks
653
+ for cpuX when it was idle.
654
+
655
+What: /sys/devices/system/cpu/cpuX/mte_tcf_preferred
656
+Date: July 2021
657
+Contact: Linux ARM Kernel Mailing list <linux-arm-kernel@lists.infradead.org>
658
+Description: Preferred MTE tag checking mode
659
+
660
+ When a user program specifies more than one MTE tag checking
661
+ mode, this sysfs node is used to specify which mode should
662
+ be preferred when running on that CPU. Possible values:
663
+
664
+ ================ ==============================================
665
+ "sync" Prefer synchronous mode
666
+ "async" Prefer asynchronous mode
667
+ ================ ==============================================
668
+
669
+ Changes to this sysfs node may not take effect immediately.
670
+
671
+ See also: Documentation/arm64/memory-tagging-extension.rst