[coreboot-gerrit] Change in ...coreboot[master]: intelblocks/cpu: Fix wrong comment for P_Req field in PERF_CTL MSR

Werner Zeh (Code Review) gerrit at coreboot.org
Thu Nov 22 15:15:49 CET 2018


Werner Zeh has uploaded this change for review. ( https://review.coreboot.org/c/coreboot/+/29798


Change subject: intelblocks/cpu: Fix wrong comment for P_Req field in PERF_CTL MSR
......................................................................

intelblocks/cpu: Fix wrong comment for P_Req field in PERF_CTL MSR

The mentioned bits 14:8 are wrong as the functions always write
bits 15:8. What happens is visible in the written code. There is no need
for an extra comment.

Change-Id: I59b4d24d01a0a8fa74912f9754e7bbb217ca269d
Signed-off-by: Werner Zeh <werner.zeh at siemens.com>
---
M src/soc/intel/common/block/cpu/cpulib.c
M src/soc/intel/common/block/include/intelblocks/cpulib.h
2 files changed, 10 insertions(+), 10 deletions(-)



  git pull ssh://review.coreboot.org:29418/coreboot refs/changes/98/29798/1

diff --git a/src/soc/intel/common/block/cpu/cpulib.c b/src/soc/intel/common/block/cpu/cpulib.c
index f2142d9..d18b50c 100644
--- a/src/soc/intel/common/block/cpu/cpulib.c
+++ b/src/soc/intel/common/block/cpu/cpulib.c
@@ -34,7 +34,7 @@
 #include <stdint.h>
 
 /*
- * Set PERF_CTL MSR (0x199) P_Req (14:8 bits) with
+ * Set PERF_CTL MSR (0x199) P_Req with
  * Turbo Ratio which is the Maximum Ratio.
  */
 void cpu_set_max_ratio(void)
@@ -86,7 +86,7 @@
  * 23:16 -	MAX_TURBO_3_CORES
  * 31:24 -	MAX_TURBO_4_CORES
  *
- * Set PERF_CTL MSR (0x199) P_Req (14:8 bits) with that value.
+ * Set PERF_CTL MSR (0x199) P_Req with that value.
  */
 void cpu_set_p_state_to_turbo_ratio(void)
 {
@@ -106,7 +106,7 @@
  * TDP level ratio to be used for specific processor (in units
  * of 100MHz).
  *
- * Set PERF_CTL MSR (0x199) P_Req (14:8 bits) with that value.
+ * Set PERF_CTL MSR (0x199) P_Req with that value.
  */
 void cpu_set_p_state_to_nominal_tdp_ratio(void)
 {
@@ -125,7 +125,7 @@
  * PLATFORM_INFO MSR (0xCE) Bits 15:8 tells
  * MAX_NON_TURBO_LIM_RATIO.
  *
- * Set PERF_CTL MSR (0x199) P_Req (14:8 bits) with that value.
+ * Set PERF_CTL MSR (0x199) P_Req with that value.
  */
 void cpu_set_p_state_to_max_non_turbo_ratio(void)
 {
@@ -142,7 +142,7 @@
 }
 
 /*
- * Set PERF_CTL MSR (0x199) P_Req (14:8 bits) with the value
+ * Set PERF_CTL MSR (0x199) P_Req with the value
  * for maximum efficiency. This value is reported in PLATFORM_INFO MSR (0xCE)
  * in Bits 47:40 and is extracted with cpu_get_min_ratio().
  */
diff --git a/src/soc/intel/common/block/include/intelblocks/cpulib.h b/src/soc/intel/common/block/include/intelblocks/cpulib.h
index 0d51146..5cea96e 100644
--- a/src/soc/intel/common/block/include/intelblocks/cpulib.h
+++ b/src/soc/intel/common/block/include/intelblocks/cpulib.h
@@ -20,7 +20,7 @@
 #include <stdint.h>
 
 /*
- * Set PERF_CTL MSR (0x199) P_Req (14:8 bits) with
+ * Set PERF_CTL MSR (0x199) P_Req with
  * Turbo Ratio which is the Maximum Ratio.
  */
 void cpu_set_max_ratio(void);
@@ -52,7 +52,7 @@
  * 23:16 -	MAX_TURBO_3_CORES
  * 31:24 -	MAX_TURBO_4_CORES
  *
- * Set PERF_CTL MSR (0x199) P_Req (14:8 bits) with that value.
+ * Set PERF_CTL MSR (0x199) P_Req with that value.
  */
 void cpu_set_p_state_to_turbo_ratio(void);
 
@@ -61,7 +61,7 @@
  * TDP level ratio to be used for specific processor (in units
  * of 100MHz).
  *
- * Set PERF_CTL MSR (0x199) P_Req (14:8 bits) with that value.
+ * Set PERF_CTL MSR (0x199) P_Req with that value.
  */
 void cpu_set_p_state_to_nominal_tdp_ratio(void);
 
@@ -69,12 +69,12 @@
  * PLATFORM_INFO MSR (0xCE) Bits 15:8 tells
  * MAX_NON_TURBO_LIM_RATIO.
  *
- * Set PERF_CTL MSR (0x199) P_Req (14:8 bits) with that value.
+ * Set PERF_CTL MSR (0x199) P_Req with that value.
  */
 void cpu_set_p_state_to_max_non_turbo_ratio(void);
 
 /*
- * Set PERF_CTL MSR (0x199) P_Req (14:8 bits) with the value
+ * Set PERF_CTL MSR (0x199) P_Req with the value
  * for maximum efficiency. This value is reported in PLATFORM_INFO MSR (0xCE)
  * in Bits 47:40 and is extracted with cpu_get_min_ratio().
  */

-- 
To view, visit https://review.coreboot.org/c/coreboot/+/29798
To unsubscribe, or for help writing mail filters, visit https://review.coreboot.org/settings

Gerrit-Project: coreboot
Gerrit-Branch: master
Gerrit-Change-Id: I59b4d24d01a0a8fa74912f9754e7bbb217ca269d
Gerrit-Change-Number: 29798
Gerrit-PatchSet: 1
Gerrit-Owner: Werner Zeh <werner.zeh at siemens.com>
Gerrit-MessageType: newchange
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.coreboot.org/pipermail/coreboot-gerrit/attachments/20181122/6398217c/attachment.html>


More information about the coreboot-gerrit mailing list