mirror of
https://github.com/torvalds/linux.git
synced 2026-09-22 04:34:03 +02:00
hwmon: Stop using 32-bit MSR interfaces
The 32-bit MSR interface rdmsr() is planned to be removed. Use the related 64-bit variant instead. Signed-off-by: Juergen Gross <jgross@suse.com> Signed-off-by: Ingo Molnar <mingo@kernel.org> Acked-by: Guenter Roeck <linux@roeck-us.net> Link: https://patch.msgid.link/20260629060526.3638272-30-jgross@suse.com
This commit is contained in:
parent
3e8ca6691e
commit
cd5102479d
|
|
@ -237,16 +237,17 @@ static struct vrm_model vrm_models[] = {
|
|||
*/
|
||||
static u8 get_via_model_d_vrm(void)
|
||||
{
|
||||
unsigned int vid, brand, __maybe_unused dummy;
|
||||
u64 msr;
|
||||
unsigned int vid, brand;
|
||||
static const char *brands[4] = {
|
||||
"C7-M", "C7", "Eden", "C7-D"
|
||||
};
|
||||
|
||||
rdmsr(0x198, dummy, vid);
|
||||
vid &= 0xff;
|
||||
rdmsrq(0x198, msr);
|
||||
vid = (msr >> 32) & 0xff;
|
||||
|
||||
rdmsr(0x1154, brand, dummy);
|
||||
brand = ((brand >> 4) ^ (brand >> 2)) & 0x03;
|
||||
rdmsrq(0x1154, msr);
|
||||
brand = ((msr >> 4) ^ (msr >> 2)) & 0x03;
|
||||
|
||||
if (vid > 0x3f) {
|
||||
pr_info("Using %d-bit VID table for VIA %s CPU\n",
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user