diff mbox series

[SRU,Cosmic,2/4] x86/speculation: Change misspelled STIPB to STIBP

Message ID 20190325135555.23768-3-juergh@canonical.com
State New
Headers show
Series Spectre v2 updates | expand

Commit Message

Juerg Haefliger March 25, 2019, 1:55 p.m. UTC
From: Waiman Long <longman@redhat.com>

STIBP stands for Single Thread Indirect Branch Predictors. The acronym,
however, can be easily mis-spelled as STIPB. It is perhaps due to the
presence of another related term - IBPB (Indirect Branch Predictor
Barrier).

Fix the mis-spelling in the code.

Signed-off-by: Waiman Long <longman@redhat.com>
Signed-off-by: Borislav Petkov <bp@suse.de>
Cc: "H. Peter Anvin" <hpa@zytor.com>
Cc: Andi Kleen <ak@linux.intel.com>
Cc: David Woodhouse <dwmw@amazon.co.uk>
Cc: Ingo Molnar <mingo@redhat.com>
Cc: Jiri Kosina <jkosina@suse.cz>
Cc: Josh Poimboeuf <jpoimboe@redhat.com>
Cc: KarimAllah Ahmed <karahmed@amazon.de>
Cc: Konrad Rzeszutek Wilk <konrad.wilk@oracle.com>
Cc: Peter Zijlstra <peterz@infradead.org>
Cc: Thomas Gleixner <tglx@linutronix.de>
Cc: Tim Chen <tim.c.chen@linux.intel.com>
Cc: x86-ml <x86@kernel.org>
Link: https://lkml.kernel.org/r/1544039368-9009-1-git-send-email-longman@redhat.com

CVE-2017-5715

(cherry picked from commit aa77bfb354c495fc4361199e63fc5765b9e1e783)
Signed-off-by: Juerg Haefliger <juergh@canonical.com>
---
 arch/x86/kernel/cpu/bugs.c | 6 +++---
 arch/x86/kernel/process.h  | 2 +-
 2 files changed, 4 insertions(+), 4 deletions(-)

Comments

Tyler Hicks March 25, 2019, 6:18 p.m. UTC | #1
On 2019-03-25 14:55:53, Juerg Haefliger wrote:
> From: Waiman Long <longman@redhat.com>
> 
> STIBP stands for Single Thread Indirect Branch Predictors. The acronym,
> however, can be easily mis-spelled as STIPB. It is perhaps due to the
> presence of another related term - IBPB (Indirect Branch Predictor
> Barrier).
> 
> Fix the mis-spelling in the code.
> 
> Signed-off-by: Waiman Long <longman@redhat.com>
> Signed-off-by: Borislav Petkov <bp@suse.de>
> Cc: "H. Peter Anvin" <hpa@zytor.com>
> Cc: Andi Kleen <ak@linux.intel.com>
> Cc: David Woodhouse <dwmw@amazon.co.uk>
> Cc: Ingo Molnar <mingo@redhat.com>
> Cc: Jiri Kosina <jkosina@suse.cz>
> Cc: Josh Poimboeuf <jpoimboe@redhat.com>
> Cc: KarimAllah Ahmed <karahmed@amazon.de>
> Cc: Konrad Rzeszutek Wilk <konrad.wilk@oracle.com>
> Cc: Peter Zijlstra <peterz@infradead.org>
> Cc: Thomas Gleixner <tglx@linutronix.de>
> Cc: Tim Chen <tim.c.chen@linux.intel.com>
> Cc: x86-ml <x86@kernel.org>
> Link: https://lkml.kernel.org/r/1544039368-9009-1-git-send-email-longman@redhat.com
> 
> CVE-2017-5715
> 
> (cherry picked from commit aa77bfb354c495fc4361199e63fc5765b9e1e783)
> Signed-off-by: Juerg Haefliger <juergh@canonical.com>

Acked-by: Tyler Hicks <tyhicks@canonical.com>

Tyler

> ---
>  arch/x86/kernel/cpu/bugs.c | 6 +++---
>  arch/x86/kernel/process.h  | 2 +-
>  2 files changed, 4 insertions(+), 4 deletions(-)
> 
> diff --git a/arch/x86/kernel/cpu/bugs.c b/arch/x86/kernel/cpu/bugs.c
> index eec398805101..3fd12053e83b 100644
> --- a/arch/x86/kernel/cpu/bugs.c
> +++ b/arch/x86/kernel/cpu/bugs.c
> @@ -54,7 +54,7 @@ static u64 __ro_after_init x86_spec_ctrl_mask = SPEC_CTRL_IBRS;
>  u64 __ro_after_init x86_amd_ls_cfg_base;
>  u64 __ro_after_init x86_amd_ls_cfg_ssbd_mask;
>  
> -/* Control conditional STIPB in switch_to() */
> +/* Control conditional STIBP in switch_to() */
>  DEFINE_STATIC_KEY_FALSE(switch_to_cond_stibp);
>  /* Control conditional IBPB in switch_mm() */
>  DEFINE_STATIC_KEY_FALSE(switch_mm_cond_ibpb);
> @@ -379,12 +379,12 @@ spectre_v2_user_select_mitigation(enum spectre_v2_mitigation_cmd v2_cmd)
>  			"always-on" : "conditional");
>  	}
>  
> -	/* If enhanced IBRS is enabled no STIPB required */
> +	/* If enhanced IBRS is enabled no STIBP required */
>  	if (spectre_v2_enabled == SPECTRE_V2_IBRS_ENHANCED)
>  		return;
>  
>  	/*
> -	 * If SMT is not possible or STIBP is not available clear the STIPB
> +	 * If SMT is not possible or STIBP is not available clear the STIBP
>  	 * mode.
>  	 */
>  	if (!smt_possible || !boot_cpu_has(X86_FEATURE_STIBP))
> diff --git a/arch/x86/kernel/process.h b/arch/x86/kernel/process.h
> index 898e97cf6629..320ab978fb1f 100644
> --- a/arch/x86/kernel/process.h
> +++ b/arch/x86/kernel/process.h
> @@ -19,7 +19,7 @@ static inline void switch_to_extra(struct task_struct *prev,
>  	if (IS_ENABLED(CONFIG_SMP)) {
>  		/*
>  		 * Avoid __switch_to_xtra() invocation when conditional
> -		 * STIPB is disabled and the only different bit is
> +		 * STIBP is disabled and the only different bit is
>  		 * TIF_SPEC_IB. For CONFIG_SMP=n TIF_SPEC_IB is not
>  		 * in the TIF_WORK_CTXSW masks.
>  		 */
> -- 
> 2.19.1
> 
> 
> -- 
> kernel-team mailing list
> kernel-team@lists.ubuntu.com
> https://lists.ubuntu.com/mailman/listinfo/kernel-team
diff mbox series

Patch

diff --git a/arch/x86/kernel/cpu/bugs.c b/arch/x86/kernel/cpu/bugs.c
index eec398805101..3fd12053e83b 100644
--- a/arch/x86/kernel/cpu/bugs.c
+++ b/arch/x86/kernel/cpu/bugs.c
@@ -54,7 +54,7 @@  static u64 __ro_after_init x86_spec_ctrl_mask = SPEC_CTRL_IBRS;
 u64 __ro_after_init x86_amd_ls_cfg_base;
 u64 __ro_after_init x86_amd_ls_cfg_ssbd_mask;
 
-/* Control conditional STIPB in switch_to() */
+/* Control conditional STIBP in switch_to() */
 DEFINE_STATIC_KEY_FALSE(switch_to_cond_stibp);
 /* Control conditional IBPB in switch_mm() */
 DEFINE_STATIC_KEY_FALSE(switch_mm_cond_ibpb);
@@ -379,12 +379,12 @@  spectre_v2_user_select_mitigation(enum spectre_v2_mitigation_cmd v2_cmd)
 			"always-on" : "conditional");
 	}
 
-	/* If enhanced IBRS is enabled no STIPB required */
+	/* If enhanced IBRS is enabled no STIBP required */
 	if (spectre_v2_enabled == SPECTRE_V2_IBRS_ENHANCED)
 		return;
 
 	/*
-	 * If SMT is not possible or STIBP is not available clear the STIPB
+	 * If SMT is not possible or STIBP is not available clear the STIBP
 	 * mode.
 	 */
 	if (!smt_possible || !boot_cpu_has(X86_FEATURE_STIBP))
diff --git a/arch/x86/kernel/process.h b/arch/x86/kernel/process.h
index 898e97cf6629..320ab978fb1f 100644
--- a/arch/x86/kernel/process.h
+++ b/arch/x86/kernel/process.h
@@ -19,7 +19,7 @@  static inline void switch_to_extra(struct task_struct *prev,
 	if (IS_ENABLED(CONFIG_SMP)) {
 		/*
 		 * Avoid __switch_to_xtra() invocation when conditional
-		 * STIPB is disabled and the only different bit is
+		 * STIBP is disabled and the only different bit is
 		 * TIF_SPEC_IB. For CONFIG_SMP=n TIF_SPEC_IB is not
 		 * in the TIF_WORK_CTXSW masks.
 		 */