lkml.org 
[lkml]   [2021]   [Dec]   [9]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
Patch in this message
/
From
Subject[PATCH -next 1/2] x86: Use rdmsrl instead of rdmsr
Date
From: Li Yang <yang.lee@linux.alibaba.com>

In the current scenario, variable 'hi' set but not used,
rdmsrl() does not change the function, but it is more concise.

Eliminate the following clang warnings:
arch/x86/kernel/process.c:889:10: warning: variable 'hi' set but not
used [-Wunused-but-set-variable]

Reported-by: Abaci Robot <abaci@linux.alibaba.com>
Signed-off-by: Li Yang <yang.lee@linux.alibaba.com>
---
arch/x86/kernel/process.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/arch/x86/kernel/process.c b/arch/x86/kernel/process.c
index 5d481038fe0b..b415f30278d1 100644
--- a/arch/x86/kernel/process.c
+++ b/arch/x86/kernel/process.c
@@ -886,7 +886,7 @@ void amd_e400_c1e_apic_setup(void)

void __init arch_post_acpi_subsys_init(void)
{
- u32 lo, hi;
+ u32 lo;

if (!boot_cpu_has_bug(X86_BUG_AMD_E400))
return;
@@ -896,7 +896,7 @@ void __init arch_post_acpi_subsys_init(void)
* the machine is affected K8_INTP_C1E_ACTIVE_MASK bits are set in
* MSR_K8_INT_PENDING_MSG.
*/
- rdmsr(MSR_K8_INT_PENDING_MSG, lo, hi);
+ rdmsrl(MSR_K8_INT_PENDING_MSG, lo);
if (!(lo & K8_INTP_C1E_ACTIVE_MASK))
return;

--
2.34.0
\
 
 \ /
  Last update: 2021-12-10 04:23    [W:0.030 / U:2.280 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site